From eee654b9652fb9387018f9653431a11401a354fd Mon Sep 17 00:00:00 2001
From: openeuler-basic <shenyangyang4@huawei.com>
Date: Thu, 9 Jan 2020 19:16:58 +0800
Subject: [PATCH] Unbundle config site and add RPM LD FLAGS macro

---
 macros.in | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/macros.in b/macros.in
index a2411d7..8cb8a5a 100644
--- a/macros.in
+++ b/macros.in
@@ -727,10 +727,11 @@ package or when debugging this package.\
   RPM_SOURCE_DIR=\"%{_sourcedir}\"\
   RPM_BUILD_DIR=\"%{_builddir}\"\
   RPM_OPT_FLAGS=\"%{optflags}\"\
+  RPM_LD_FLAGS=\"%{?build_ldflags}\"\
   RPM_ARCH=\"%{_arch}\"\
   RPM_OS=\"%{_os}\"\
   RPM_BUILD_NCPUS=\"%{_smp_build_ncpus}\"\
-  export RPM_SOURCE_DIR RPM_BUILD_DIR RPM_OPT_FLAGS RPM_ARCH RPM_OS RPM_BUILD_NCPUS\
+  export RPM_SOURCE_DIR RPM_BUILD_DIR RPM_OPT_FLAGS RPM_ARCH RPM_OS RPM_BUILD_NCPUS RPM_OPT_FLAGS\
   RPM_DOC_DIR=\"%{_docdir}\"\
   export RPM_DOC_DIR\
   RPM_PACKAGE_NAME=\"%{NAME}\"\
@@ -746,7 +747,9 @@ package or when debugging this package.\
   %{?_javaclasspath:CLASSPATH=\"%{_javaclasspath}\"\
   export CLASSPATH}\
   PKG_CONFIG_PATH=\"${PKG_CONFIG_PATH}:%{_libdir}/pkgconfig:%{_datadir}/pkgconfig\"\
-  export PKG_CONFIG_PATH
+  export PKG_CONFIG_PATH\
+  CONFIG_SITE=${CONFIG_SITE:-NONE}\
+  export CONFIG_SITE
 
 %___build_pre	\
   %{___build_pre_env} \
-- 
2.27.0

