From 9384cb338e0aee678e064e5a8e4a7e32d3aa7d7c Mon Sep 17 00:00:00 2001 From: Mat Booth Date: Feb 01 2018 09:12:00 +0000 Subject: Export LDFLAGS as well as CFLAGS --- diff --git a/eclipse-cdt.spec b/eclipse-cdt.spec index 590651e..f302a67 100644 --- a/eclipse-cdt.spec +++ b/eclipse-cdt.spec @@ -36,7 +36,7 @@ Epoch: 1 Summary: Eclipse C/C++ Development Tools (CDT) plugin Name: eclipse-cdt Version: 9.4.1 -Release: 0.3%{?dist} +Release: 0.4%{?dist} License: EPL and CPL URL: http://www.eclipse.org/cdt @@ -243,7 +243,7 @@ sed -i -e 's|linux/x86_64/|linux/%{eclipse_arch}/|' \ sed -i -e 's|linux/x86/|linux/%{eclipse_arch}/|' \ native/org.eclipse.cdt.native.serial/jni/Makefile %endif -sed -i -e 's|-m.. -fPIC -D_REENTRANT|$(CFLAGS)|' \ +sed -i -e 's|-m.. |$(CFLAGS) $(LDFLAGS) |' \ native/org.eclipse.cdt.native.serial/jni/Makefile # Ensure correct platform fragments appear in config.ini @@ -377,15 +377,16 @@ sed -i -e 's/org.freemarker/org.freemarker.freemarker/' \ %build export JAVA_HOME=%{_jvmdir}/java +export CFLAGS="${CFLAGS:-%__global_cflags}" +export LDFLAGS="${LDFLAGS:-%__global_ldflags}" + # Build native serial library pushd native/org.eclipse.cdt.native.serial/jni -make CFLAGS="-fPIC %{optflags}" ../os/linux/%{eclipse_arch}/libserial.so +make ../os/linux/%{eclipse_arch}/libserial.so popd # Exclude EquinoxResolver to avoid NPE occuring on arm and increase memory for s390 export MAVEN_OPTS="-Xmx1024m -XX:CompileCommand=exclude,org/eclipse/tycho/core/osgitools/EquinoxResolver,newState" - -export CFLAGS="%{optflags}" %mvn_build -j -f -- -Dtycho.local.keepTarget -Dnative=linux.%{eclipse_arch} %install @@ -556,6 +557,9 @@ fi %endif %changelog +* Thu Feb 01 2018 Mat Booth - 1:9.4.1-0.4 +- Export LDFLAGS as well as CFLAGS + * Wed Jan 31 2018 Mat Booth - 1:9.4.1-0.3 - Fix error causing secondary arches to fail, fix bootstrap modes