From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail-lf1-x12d.google.com ([2a00:1450:4864:20::12d]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1hqDCP-0005Zy-LW for ptxdist@pengutronix.de; Wed, 24 Jul 2019 11:04:38 +0200 Received: by mail-lf1-x12d.google.com with SMTP id b17so31432156lff.7 for ; Wed, 24 Jul 2019 02:04:37 -0700 (PDT) From: Lars Pedersen Date: Wed, 24 Jul 2019 11:04:28 +0200 Message-Id: <20190724090428.4344-1-lapeddk@gmail.com> MIME-Version: 1.0 Subject: [ptxdist] [PATCH] gettext: add envsubst option List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ptxdist-bounces@pengutronix.de Sender: "ptxdist" To: ptxdist@pengutronix.de Cc: Lars Pedersen For environment variable templating Signed-off-by: Lars Pedersen --- rules/gettext.in | 14 +++++++++++++- rules/gettext.make | 4 ++++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/rules/gettext.in b/rules/gettext.in index 5b971f7d1..1b322ae35 100644 --- a/rules/gettext.in +++ b/rules/gettext.in @@ -1,5 +1,5 @@ ## SECTION=system_libraries -config GETTEXT +menuconfig GETTEXT tristate prompt "gettext (gnu)" select LIBC_M @@ -10,3 +10,15 @@ config GETTEXT The gettext program translates a natural language message into the user's language, by looking up the translation in a message catalog. + + +if GETTEXT + +config GETTEXT_ENVSUBST + bool + default n + prompt "envsubst" + help + Substitutes environment variables in shell format strings + +endif diff --git a/rules/gettext.make b/rules/gettext.make index 0bda25c96..dd1d22ffb 100644 --- a/rules/gettext.make +++ b/rules/gettext.make @@ -71,6 +71,10 @@ $(STATEDIR)/gettext.targetinstall: @$(call install_fixup, gettext,AUTHOR,"Robert Schwebel ") @$(call install_fixup, gettext,DESCRIPTION,missing) +ifdef PTXCONF_GETTEXT_ENVSUBST + @$(call install_copy, gettext, 0, 0, 0755, -, /usr/bin/envsubst) +endif + @$(call install_copy, gettext, 0, 0, 0755, -, /usr/bin/xgettext) @$(call install_copy, gettext, 0, 0, 0755, -, /usr/bin/gettext) -- 2.21.0 _______________________________________________ ptxdist mailing list ptxdist@pengutronix.de