[YafaRay] Build with PIC (fix FTBFS on ARM)

Peter Robinson pbrobinson at fedoraproject.org
Sun Jul 8 16:58:47 UTC 2012


commit 541d5f4b82739b8030698910eaf1cd567454f275
Author: Peter Robinson <pbrobinson at gmail.com>
Date:   Sun Jul 8 17:58:42 2012 +0100

    Build with PIC (fix FTBFS on ARM)

 YafaRay.spec |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/YafaRay.spec b/YafaRay.spec
index 0bb4d52..1b0d92e 100644
--- a/YafaRay.spec
+++ b/YafaRay.spec
@@ -20,7 +20,7 @@ Source1:        python-%{date}.tar.gz
 Source2:        README.Fedora
 Source3:        yafaray-snapshot.sh
 %else
-Release:        5%{?dist}
+Release:        6%{?dist}
 Source0:        http://static.yafaray.org/sources/%{name}.%{version}.zip
 Source1:        http://static.yafaray.org/sources/%{name}-blender.%{version}.zip
 Source2:        README.Fedora
@@ -71,22 +71,25 @@ is launched by an entry automatically added to the Blender Render menu.
 %setup -q -n %{yname}
 %setup -q -D -T -a 1 -n %{yname}
 %endif
+
 sed -i -e"s,/lib',/%{_lib}',g" config/linux2-config.py
 sed -i -e"s,/lib/,/%{_lib}/,g" config/linux2-config.py
+
 %if %{with qt}
 sed -i -e"s,WITH_YF_QT='false',WITH_YF_QT='true',g" config/linux2-config.py
 %endif
+
 cat << EOF >> config/linux2-config.py
 YF_QTDIR = '%{_libdir}/qt4'
 # unversioned SO is correct by itself when the said shared object is
 # meant to be dlopen at runtime, instead of being linked at build time.
 #YF_SHLINKFLAGS = "-Wl,-soname,libyafaraycore.so.1"
 EOF
-sed -i -e"s|REL_CCFLAGS = '-O3 -ffast-math'|REL_CCFLAGS = '-ffast-math %{optflags}'|g" config/linux2-config.py
+sed -i -e"s|REL_CCFLAGS = '-O3 -ffast-math'|REL_CCFLAGS = '-ffast-math -fPIC %{optflags}'|g" config/linux2-config.py
 # fixes %%{buildroot} in libyafaraycore.so
 sed -i -e"s,\$YF_LIBOUT,%{_libdir},g" tools/writeconfig.py
 sed -i -e"s,\$YF_PLUGINPATH,%{_libdir}/%{yname},g" tools/writeconfig.py
-%{__install} -pm644 %{SOURCE2} ./
+install -pm644 %{SOURCE2} ./
 
 %build
 scons build
@@ -138,6 +141,9 @@ popd
 
 
 %changelog
+* Sun Jul  8 2012 Peter Robinson <pbrobinson at fedoraproject.org> - 0.1.1-6
+- Build with PIC (fix FTBFS on ARM)
+
 * Fri Apr 27 2012 Peter Robinson <pbrobinson at fedoraproject.org> - 0.1.1-5
 - Fix endif statement
 


More information about the scm-commits mailing list