diff options
author | Igor Gnatenko <i.gnatenko.brain@gmail.com> | 2016-09-06 16:29:50 +0200 |
---|---|---|
committer | Igor Gnatenko <i.gnatenko.brain@gmail.com> | 2016-09-06 16:58:03 +0200 |
commit | 1f553f9cdccf6e59685da5309677530b33ede38a (patch) | |
tree | 7a6e7e021fb1121e7906618f1784044b93081c9b | |
parent | f255c6bdb27ad1512c043a64195410d46996395a (diff) | |
download | rpm-1f553f9cdccf6e59685da5309677530b33ede38a.tar.gz |
macros: check if GNU Make supports -O
Otherwise on old platforms which have GNU Make < 4.0 it will fail with:
/usr/bin/make: invalid option -- 'O'
We could check version of GNU Make, but we want to rely on feature, and
not on the version. Features can be backported.
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Acked-by: Alexey Gladkov <agladkov@redhat.com>
-rw-r--r-- | macros.in | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -939,8 +939,13 @@ package or when debugging this package.\ --infodir=%{_infodir} #------------------------------------------------------------------------------ +# Tested features of make +# Output syncronization for parallel make: +%_make_output_sync %(! %{__make} --version -O >/dev/null 2>&1 || echo -O) + +#------------------------------------------------------------------------------ # The "make" analogue, hiding the _smp_mflags magic from specs -%make_build %{__make} -O %{?_smp_mflags} +%make_build %{__make} %{_make_output_sync} %{?_smp_mflags} #------------------------------------------------------------------------------ # The make install analogue of %configure for modern autotools: |