alexk / rpms / rpm

Forked from rpms/rpm 2 years ago
Clone
648606
From 89df36524bace71decee4ab4f979d4ffb449c9a7 Mon Sep 17 00:00:00 2001
648606
From: Panu Matilainen <pmatilai@redhat.com>
648606
Date: Wed, 22 Jan 2014 10:56:00 +0200
648606
Subject: [PATCH] Add %make_build macro for hiding parallel-build magic from
648606
 specs (ticket #115)
648606
648606
- This allows simplifying the make invokations from specs. In particular
648606
  the parallel build options no longer need to be messed with from specs,
648606
  and %__make can be overridden to force a different make implementation
648606
  to be used throughout the spec.
648606
- While a lot of software builds correctly in parallel, there are always
648606
  exceptions... together with _smp_ncpus_max macro this can now be
648606
  expressed with a separate "%global _smp_ncpus_max 1" (or any other
648606
  arbitrary value beyond which parallel build is buggy) line which
648606
  is easy to grep for and experiment with.
648606
---
648606
 macros.in | 4 ++++
648606
 1 file changed, 4 insertions(+)
648606
648606
diff --git a/macros.in b/macros.in
648606
index 5a075a3..9c7a111 100644
648606
--- a/macros.in
648606
+++ b/macros.in
648606
@@ -861,6 +861,10 @@ package or when debugging this package.\
648606
 	--infodir=%{_infodir}
648606
 
648606
 #------------------------------------------------------------------------------
648606
+# The "make" analogue, hiding the _smp_mflags magic from specs
648606
+%make_build %{__make} %{?_smp_mflags}
648606
+
648606
+#------------------------------------------------------------------------------
648606
 # The make install analogue of %configure for modern autotools:
648606
 %make_install %{__make} install DESTDIR=%{?buildroot}
648606
 
648606
-- 
648606
2.1.0
648606