Comments below...
On Wed, Nov 14, 2012 at 10:43:17AM -0500, Samantha N. Bueno wrote:
transifex-client shouldn't be listed as a BuildReq; only check for it and install as needed if the target requiring it is called by make
Makefile.am | 9 +++++++++ anaconda.spec.in | 1 - 2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/Makefile.am b/Makefile.am index 4f76895..cee2b4a 100644 --- a/Makefile.am +++ b/Makefile.am @@ -45,6 +45,7 @@ sed_verbose_0 = @echo " SED "$@;
TX_PULL_ARGS = -a --disable-overwrite TX_PUSH_ARGS = -s +tx_installed=`rpm -qa transifex-client`
$(PACKAGE_NAME).spec: $(PACKAGE_NAME).spec.in $(sed_verbose)sed -e 's/#VERSION#/$(PACKAGE_VERSION)/' < $< > $@ @@ -56,6 +57,10 @@ tag: po-pull: rm -f po/en@boldquot.gmo po/en@boldquot.po rm -f po/en@quot.gmo po/en@quot.po
- if [ -z "$tx_installed" ]; then \
yum install transifex-client
- fi tx pull $(TX_PULL_ARGS)
scratch: po-pull @@ -81,6 +86,10 @@ bumpver: po-pull fi ; \ scripts/makebumpver $${opts} || exit 1 ; \ $(MAKE) -C po $(PACKAGE_NAME).pot-update ; \
- if [ -z "$tx_installed" ]; then \
yum install transifex-client
- fi tx push $(TX_PUSH_ARGS)
Two things, which are make(1) things:
1) The lines under a make target have to be indented with at least one real tab character.
2) Each line is a subshell, unless you join the line to the next one with "; "
3) I lied, three things. Can't easily have blank lines in make targets.
The other suggestion I have is to just say you should yum install transifex-client rather than doing that, because that won't (or probably won't in most cases) work unless the user is root.
If you go with the tx_installed variable you have, there are some other make(1) requirements. And since this is technically automake, it may be too difficult to capture the output from rpm in a variable. I'd just run the query silently in the target and check the return code, then either echo and exit failure or move to the tx usage.
install-buildrequires: diff --git a/anaconda.spec.in b/anaconda.spec.in index 61dd7ef..7b20a2a 100644 --- a/anaconda.spec.in +++ b/anaconda.spec.in @@ -80,7 +80,6 @@ BuildRequires: python-nose BuildRequires: rpm-devel BuildRequires: rpm-python >= %{rpmpythonver} BuildRequires: slang-devel >= %{slangver} -BuildRequires: transifex-client BuildRequires: xmlto BuildRequires: yum >= %{yumver} BuildRequires: zlib-devel -- 1.7.11.7 _______________________________________________ anaconda-patches mailing list anaconda-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/anaconda-patches