mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Lars Pedersen <lapeddk@gmail.com>
To: ptxdist@pengutronix.de
Cc: m.olbrich@pengutronix.de, Lars Pedersen <lapeddk@gmail.com>
Subject: [ptxdist] [PATCH v2] gettext: add envsubst option
Date: Mon, 26 Aug 2019 11:54:07 +0200	[thread overview]
Message-ID: <20190826095407.8995-1-lapeddk@gmail.com> (raw)
In-Reply-To: <20190807105032.33jorssrz2s676lh@pengutronix.de>

For environment variable templating

Signed-off-by: Lars Pedersen <lapeddk@gmail.com>
---
v2: Fix prompt spacing and remove default line
 rules/gettext.in   | 15 +++++++++++++--
 rules/gettext.make |  4 ++++
 2 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/rules/gettext.in b/rules/gettext.in
index 5b971f7d1..dc0573912 100644
--- a/rules/gettext.in
+++ b/rules/gettext.in
@@ -1,7 +1,7 @@
 ## SECTION=system_libraries
-config GETTEXT
+menuconfig GETTEXT
 	tristate
-	prompt "gettext (gnu)"
+	prompt "gettext (gnu)                 "
 	select LIBC_M
 	select LIBC_DL
 	select GCCLIBS_CXX
@@ -10,3 +10,14 @@ 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
+	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 <r.schwebel@pengutronix.de>")
 	@$(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

      reply	other threads:[~2019-08-26  9:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-24  9:04 [ptxdist] [PATCH] " Lars Pedersen
2019-08-07 10:50 ` Michael Olbrich
2019-08-26  9:54   ` Lars Pedersen [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190826095407.8995-1-lapeddk@gmail.com \
    --to=lapeddk@gmail.com \
    --cc=m.olbrich@pengutronix.de \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox