chantra / rpms / rpm

Forked from rpms/rpm 2 years ago
Clone
672c60
From d97d7b71de158660eb96b4f11d40b6626b85521a Mon Sep 17 00:00:00 2001
672c60
From: Florian Festi <ffesti@redhat.com>
672c60
Date: Tue, 16 Apr 2019 09:50:57 +0200
672c60
Subject: [PATCH] Pass RPM_BUILD_NCPUS to build scripts
672c60
672c60
Use %_smp_build_ncpus instead of the initial value
672c60
---
672c60
 macros.in | 3 ++-
672c60
 1 file changed, 2 insertions(+), 1 deletion(-)
672c60
672c60
diff --git a/macros.in b/macros.in
672c60
index fc587997d..a15e46f26 100644
672c60
--- a/macros.in
672c60
+++ b/macros.in
672c60
@@ -807,7 +807,8 @@ package or when debugging this package.\
672c60
   RPM_OPT_FLAGS=\"%{optflags}\"\
672c60
   RPM_ARCH=\"%{_arch}\"\
672c60
   RPM_OS=\"%{_os}\"\
672c60
-  export RPM_SOURCE_DIR RPM_BUILD_DIR RPM_OPT_FLAGS RPM_ARCH RPM_OS\
672c60
+  RPM_BUILD_NCPUS=\"%{_smp_build_ncpus}\"\
672c60
+  export RPM_SOURCE_DIR RPM_BUILD_DIR RPM_OPT_FLAGS RPM_ARCH RPM_OS RPM_BUILD_NCPUS\
672c60
   RPM_DOC_DIR=\"%{_docdir}\"\
672c60
   export RPM_DOC_DIR\
672c60
   RPM_PACKAGE_NAME=\"%{NAME}\"\
672c60
-- 
672c60
2.21.0
672c60