Add gfortran acceleration 73/187673/1 accepted/tizen_5.0_base tizen_5.0_base accepted/tizen/5.0/base/20181101.091208 accepted/tizen/base/20180908.052102 submit/tizen_5.0_base/20181101.000001 submit/tizen_base/20180906.130734
authorSlava Barinov <v.barinov@samsung.com>
Mon, 27 Aug 2018 09:29:59 +0000 (12:29 +0300)
committerSlava Barinov <v.barinov@samsung.com>
Mon, 27 Aug 2018 10:55:10 +0000 (13:55 +0300)
Since Tizen now has packages which require Fortran compiler, we need to restore
acceleration of Fortran compiler.

Change-Id: Ia605a42737c8db997ed361712d9bf5d02d5fd50b
Signed-off-by: Slava Barinov <v.barinov@samsung.com>
packaging/qemu-accel-aarch64.spec
packaging/qemu-accel-armv7hl.spec
packaging/qemu-accel-armv7l.spec
packaging/qemu-accel.spec.in

index a9db760..6c2ebbb 100644 (file)
@@ -40,6 +40,7 @@ Release:        0
 AutoReqProv:    off
 BuildRequires:  gcc-%{cross}
 BuildRequires:  binutils-%{cross}
+BuildRequires:  gcc-fortran
 #BuildRequires:  expect
 BuildRequires:  fdupes
 BuildRequires:  gettext-runtime
@@ -157,8 +158,8 @@ for executable in $LD \
    %{_bindir}/xsltproc \
    %{_bindir}/{ccmake,cmake,cpack,ctest} \
    %{_bindir}/%{target_arch}-{addr2line,ar,as,c++filt,dwp,elfedit,gprof,ld,ld.bfd,ld.gold,nm,objcopy,objdump,ranlib,readelf,size,strings,strip} \
-   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov} \
-   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*} \
+   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov,gfortran} \
+   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*,f951} \
    %{_bindir}/file \
    %{_bindir}/icecc \
    %{_bindir}/icerun \
@@ -368,7 +369,7 @@ cp %{_libdir}/python${python_version}/encodings/*.py %{buildroot}%{our_path}%{_l
 find %{buildroot} -name 'python*' | sed -e 's|%{buildroot}%{our_path}||' | tee -a python.list
 
 # rename gcc binaries
-for bin in c++ g++ gcc
+for bin in c++ g++ gcc gfortran
 do
   [ x"$sanitizer_enabled" == x"1" ] && bin+="-real"
   mv %{buildroot}%{our_path}%{_bindir}/%{target_arch}-$bin %{buildroot}/%{our_path}%{_bindir}/$bin
@@ -400,7 +401,7 @@ do
   ln -sf %{our_path}%{_bindir}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list
 done
-for binary in cc1 cc1plus collect2 lto1 lto-wrapper
+for binary in cc1 cc1plus collect2 lto1 lto-wrapper f951
 do
   ln -sf %{our_path}/usr/lib/gcc/%{target_arch}/${gcc_version}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list
index 5d95ca9..3b4626d 100644 (file)
@@ -40,6 +40,7 @@ Release:        0
 AutoReqProv:    off
 BuildRequires:  gcc-%{cross}
 BuildRequires:  binutils-%{cross}
+BuildRequires:  gcc-fortran
 #BuildRequires:  expect
 BuildRequires:  fdupes
 BuildRequires:  gettext-runtime
@@ -157,8 +158,8 @@ for executable in $LD \
    %{_bindir}/xsltproc \
    %{_bindir}/{ccmake,cmake,cpack,ctest} \
    %{_bindir}/%{target_arch}-{addr2line,ar,as,c++filt,dwp,elfedit,gprof,ld,ld.bfd,ld.gold,nm,objcopy,objdump,ranlib,readelf,size,strings,strip} \
-   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov} \
-   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*} \
+   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov,gfortran} \
+   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*,f951} \
    %{_bindir}/file \
    %{_bindir}/icecc \
    %{_bindir}/icerun \
@@ -368,7 +369,7 @@ cp %{_libdir}/python${python_version}/encodings/*.py %{buildroot}%{our_path}%{_l
 find %{buildroot} -name 'python*' | sed -e 's|%{buildroot}%{our_path}||' | tee -a python.list
 
 # rename gcc binaries
-for bin in c++ g++ gcc
+for bin in c++ g++ gcc gfortran
 do
   [ x"$sanitizer_enabled" == x"1" ] && bin+="-real"
   mv %{buildroot}%{our_path}%{_bindir}/%{target_arch}-$bin %{buildroot}/%{our_path}%{_bindir}/$bin
@@ -400,7 +401,7 @@ do
   ln -sf %{our_path}%{_bindir}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list
 done
-for binary in cc1 cc1plus collect2 lto1 lto-wrapper
+for binary in cc1 cc1plus collect2 lto1 lto-wrapper f951
 do
   ln -sf %{our_path}/usr/lib/gcc/%{target_arch}/${gcc_version}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list
@@ -426,16 +427,16 @@ cat %{_sourcedir}/baselibs_prologue %{_sourcedir}/baselibs_body > %{_sourcedir}/
 # Find gcc install directory
 gcc_install_dir=$(%{target_arch}-gcc -print-search-dirs | sed -ne '/install: /s/install: //p')
 # update baselibs.conf, overwrite LTO plugin
-sed -i -e "s,#PLUGIN_POSTIN#,ln -sf %{our_path}${gcc_install_dir}/liblto_plugin.so %{libdir}/gcc/%{target_arch}/${gcc_version}/liblto_plugin.so," %{_sourcedir}/baselibs.conf
+sed -i -e "s,#PLUGIN_POSTIN#,if [ -d %{libdir}/gcc/%{target_arch}/${gcc_version} ]; then\"\n  post \"  ln -sf %{our_path}${gcc_install_dir}/liblto_plugin.so %{libdir}/gcc/%{target_arch}/${gcc_version}/liblto_plugin.so\"\n  post \"fi," %{_sourcedir}/baselibs.conf
 sed -i -e "s,#PLUGIN_POSTUN#,ln -sf liblto_plugin.so.0 ${gcc_install_dir}/liblto_plugin.so," %{_sourcedir}/baselibs.conf
 
 # Use /usr/lib for cross clang libdir on armv7l architecture
 %{?armv7l:
-awk '/post "/ && !x {print $0; print "  post \"echo export\\ CLANG_NO_LIBDIR_SUFFIX=1 >> /etc/profile\""; x=1;next} 1' %{_sourcedir}/baselibs.conf > baselibs_updated && mv baselibs_updated %{_sourcedir}/baselibs.conf
+awk '/post "/ && !x {print "  post \"echo export\\ CLANG_NO_LIBDIR_SUFFIX=1 >> /etc/profile\""; print $0; x=1;next} 1' %{_sourcedir}/baselibs.conf > baselibs_updated && mv baselibs_updated %{_sourcedir}/baselibs.conf
 }
 
 %{?multilib:
-awk '/post "/ && !x {print $0; print "  post \"echo '%{our_path}/lib' >> /etc/ld.so.conf\"\n"; x=1;next} 1' %{_sourcedir}/baselibs.conf > baselibs_updated && mv baselibs_updated %{_sourcedir}/baselibs.conf
+awk '/post "/ && !x {print "  post \"echo '%{our_path}/lib' >> /etc/ld.so.conf\"\n"; print $0; x=1;next} 1' %{_sourcedir}/baselibs.conf > baselibs_updated && mv baselibs_updated %{_sourcedir}/baselibs.conf
 }
 
 # Remove the ld-$VERSION.so to prevent name clashing with native ld.so
index 216e0ff..a399ec8 100644 (file)
@@ -40,6 +40,7 @@ Release:        0
 AutoReqProv:    off
 BuildRequires:  gcc-%{cross}
 BuildRequires:  binutils-%{cross}
+BuildRequires:  gcc-fortran
 #BuildRequires:  expect
 BuildRequires:  fdupes
 BuildRequires:  gettext-runtime
@@ -157,8 +158,8 @@ for executable in $LD \
    %{_bindir}/xsltproc \
    %{_bindir}/{ccmake,cmake,cpack,ctest} \
    %{_bindir}/%{target_arch}-{addr2line,ar,as,c++filt,dwp,elfedit,gprof,ld,ld.bfd,ld.gold,nm,objcopy,objdump,ranlib,readelf,size,strings,strip} \
-   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov} \
-   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*} \
+   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov,gfortran} \
+   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*,f951} \
    %{_bindir}/file \
    %{_bindir}/icecc \
    %{_bindir}/icerun \
@@ -368,7 +369,7 @@ cp %{_libdir}/python${python_version}/encodings/*.py %{buildroot}%{our_path}%{_l
 find %{buildroot} -name 'python*' | sed -e 's|%{buildroot}%{our_path}||' | tee -a python.list
 
 # rename gcc binaries
-for bin in c++ g++ gcc
+for bin in c++ g++ gcc gfortran
 do
   [ x"$sanitizer_enabled" == x"1" ] && bin+="-real"
   mv %{buildroot}%{our_path}%{_bindir}/%{target_arch}-$bin %{buildroot}/%{our_path}%{_bindir}/$bin
@@ -400,7 +401,7 @@ do
   ln -sf %{our_path}%{_bindir}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list
 done
-for binary in cc1 cc1plus collect2 lto1 lto-wrapper
+for binary in cc1 cc1plus collect2 lto1 lto-wrapper f951
 do
   ln -sf %{our_path}/usr/lib/gcc/%{target_arch}/${gcc_version}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list
index 2096e72..c3f9f98 100644 (file)
@@ -37,6 +37,7 @@ Release:        0
 AutoReqProv:    off
 BuildRequires:  gcc-%{cross}
 BuildRequires:  binutils-%{cross}
+BuildRequires:  gcc-fortran
 #BuildRequires:  expect
 BuildRequires:  fdupes
 BuildRequires:  gettext-runtime
@@ -154,8 +155,8 @@ for executable in $LD \
    %{_bindir}/xsltproc \
    %{_bindir}/{ccmake,cmake,cpack,ctest} \
    %{_bindir}/%{target_arch}-{addr2line,ar,as,c++filt,dwp,elfedit,gprof,ld,ld.bfd,ld.gold,nm,objcopy,objdump,ranlib,readelf,size,strings,strip} \
-   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov} \
-   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*} \
+   %{_bindir}/%{target_arch}-{c++,g++,cpp,gcc,gcc-${gcc_version},gcc-ar,gcc-nm,gcc-ranlib,gcov,gfortran} \
+   %{libdir}/gcc/%{target_arch}/${gcc_version}/{cc1,cc1plus,collect2,lto1,lto-wrapper,liblto_plugin.so*,f951} \
    %{_bindir}/file \
    %{_bindir}/icecc \
    %{_bindir}/icerun \
@@ -365,7 +366,7 @@ cp %{_libdir}/python${python_version}/encodings/*.py %{buildroot}%{our_path}%{_l
 find %{buildroot} -name 'python*' | sed -e 's|%{buildroot}%{our_path}||' | tee -a python.list
 
 # rename gcc binaries
-for bin in c++ g++ gcc
+for bin in c++ g++ gcc gfortran
 do
   [ x"$sanitizer_enabled" == x"1" ] && bin+="-real"
   mv %{buildroot}%{our_path}%{_bindir}/%{target_arch}-$bin %{buildroot}/%{our_path}%{_bindir}/$bin
@@ -397,7 +398,7 @@ do
   ln -sf %{our_path}%{_bindir}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list
 done
-for binary in cc1 cc1plus collect2 lto1 lto-wrapper
+for binary in cc1 cc1plus collect2 lto1 lto-wrapper f951
 do
   ln -sf %{our_path}/usr/lib/gcc/%{target_arch}/${gcc_version}/${binary} %{buildroot}%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}
   echo "%{our_path}/home/abuild/rpmbuild/BUILD/gcc-${gcc_version}/obj/gcc/${binary}" >> %{_sourcedir}/all-accel.list