32
edits
(→qrupdate: qrupdate-1.1.2.tar.gz => qrupdate-1.1.2_Makeconf.patch) |
|||
(13 intermediate revisions by 2 users not shown) | |||
Line 87: | Line 87: | ||
# do not use threads | # do not use threads | ||
# (because I use pararrayfun from the parallel package) | # (because I use pararrayfun from the parallel package) | ||
make USE_THREAD=0 CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native | make USE_THREAD=0 CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native" CXXFLAGS="-O2 -march=native" FFLAGS="-O2 -march=native" LDFLAGS="-L/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64 -Wl,-rpath,/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64" | ||
One should get | One should get | ||
Line 116: | Line 116: | ||
sudo ln -s libopenblas_haswell-r0.2.19.so libopenblas.so.0 | sudo ln -s libopenblas_haswell-r0.2.19.so libopenblas.so.0 | ||
sudo ln -s libopenblas.so.0 libopenblas.so | sudo ln -s libopenblas.so.0 libopenblas.so | ||
== qrupdate == | |||
download the latest version (1.1.2 as of this writing) to $downloads | |||
https://sourceforge.net/projects/qrupdate/files/latest/download?source=typ_redirect | |||
Start from a clean state | |||
exit | |||
bash | |||
export PATH=/usr/local/gcc-6.2.0_binutils-2.27_isl/bin:$PATH | |||
which gfortran | |||
# should be /usr/local/gcc-6.2.0_binutils-2.27_isl/bin/gfortran | |||
cd $buildroot | |||
tar --no-same-owner -xvf $downloads/qrupdate-1.1.2.tar.gz | |||
cd qrupdate-1.1.2/ | |||
Save the following to $downloads/qrupdate-1.1.2_Makeconf.patch | |||
{{Code|qrupdate-1.1.2_Makeconf.patch|<pre> | |||
--- Makeconf.orig 2016-09-20 16:33:23.061756020 +0200 | |||
+++ Makeconf 2016-09-20 16:39:47.385547117 +0200 | |||
@@ -1,26 +1,26 @@ | |||
# set this to your compiler's executable name (e.g. gfortran, g77) | |||
FC=gfortran | |||
# requested flags | |||
-FFLAGS=-fimplicit-none -O3 -funroll-loops | |||
+FFLAGS=-fimplicit-none -march=native -O3 -funroll-loops -lgfortran | |||
# set if you need shared library | |||
FPICFLAGS=-fPIC | |||
# BLAS library (only required for tests) | |||
-BLAS=-lblas | |||
+BLAS=-lopenblas | |||
# LAPACK library (only required for tests) | |||
-LAPACK=-llapack | |||
+LAPACK= | |||
# Library version | |||
VERSION=1.1 | |||
MAJOR=1 | |||
# The default library dir | |||
-LIBDIR=lib | |||
+LIBDIR=lib64 | |||
# Destination installation offset | |||
DESTDIR= | |||
# set default prefix to /usr/local | |||
ifeq ($(strip $(PREFIX)),) | |||
- PREFIX=/usr/local | |||
+ PREFIX=/usr/local/gcc-6.2.0_binutils-2.27_isl | |||
endif | |||
</pre> | |||
}} | |||
patch -p0 < $downloads/qrupdate-1.1.2_Makeconf.patch | |||
make solib | |||
as root ({{codeline|su}}, not {{codeline|sudo}}, because we want PATH to contain {{Path|/usr/local/gcc-6.2.0_binutils-2.27_isl/bin}}) | |||
make install-shlib | |||
{{codeline|exit}} root session, then {{codeline|exit}} current bash, to return to a clean state | |||
== arpack-ng == | == arpack-ng == | ||
Line 136: | Line 201: | ||
cd arpack-ng-3.4.0 | cd arpack-ng-3.4.0 | ||
./bootstrap | ./bootstrap | ||
./configure CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native | ./configure CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native" CXXFLAGS="-O2 -march=native" FFLAGS="-O2 -march=native" LDFLAGS="-L/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64 -Wl,-rpath,/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64" --prefix=/usr/local/gcc-6.2.0_binutils-2.27_isl | ||
make -j 6 | make -j 6 | ||
Line 218: | Line 283: | ||
== FFTW == | |||
http://www.fftw.org/ | |||
cd $downloads | |||
wget http://www.fftw.org/fftw-3.3.5.tar.gz | |||
Start from a clean state | |||
exit | |||
bash | |||
export PATH=/usr/local/gcc-6.2.0_binutils-2.27_isl/bin:$PATH | |||
which gfortran | |||
# should be /usr/local/gcc-6.2.0_binutils-2.27_isl/bin/gfortran | |||
cd $buildroot | |||
tar --no-same-owner -xvf $downloads/fftw-3.3.5.tar.gz | |||
cd fftw-3.3.5/ | |||
=== Single precision === | |||
./configure --enable-shared --enable-sse2 --enable-avx --enable-openmp --enable-threads --enable-float CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native" CXXFLAGS="-O2 -march=native" FFLAGS="-O2 -march=native" LDFLAGS="-L/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64 -Wl,-rpath,/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64" PKG_CONFIG_PATH=/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64/pkgconfig --prefix=/usr/local/gcc-6.2.0_binutils-2.27_isl | |||
make -j6 | |||
make check | |||
as root ({{codeline|su}}, not {{codeline|sudo}}, because we want PATH to contain {{Path|/usr/local/gcc-6.2.0_binutils-2.27_isl/bin}}) | |||
make install | |||
exit | |||
=== Double precision === | |||
./configure --enable-shared --enable-sse2 --enable-avx --enable-openmp --enable-threads CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native" CXXFLAGS="-O2 -march=native" FFLAGS="-O2 -march=native" LDFLAGS="-L/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64 -Wl,-rpath,/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64" PKG_CONFIG_PATH=/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64/pkgconfig --prefix=/usr/local/gcc-6.2.0_binutils-2.27_isl | |||
make -j6 | |||
make check | |||
as root ({{codeline|su}}, not {{codeline|sudo}}, because we want PATH to contain {{Path|/usr/local/gcc-6.2.0_binutils-2.27_isl/bin}}) | |||
make install | |||
exit | |||
== GraphicsMagick == | == GraphicsMagick == | ||
Line 239: | Line 344: | ||
Disable ''webp'' and ''jbig'' that fail tests with gcc-6.2.0 | Disable ''webp'' and ''jbig'' that fail tests with gcc-6.2.0 | ||
./configure --without-webp --without-jbig --enable-static=no --enable-shared=yes --with-quantum-depth=16 CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native | ./configure --without-webp --without-jbig --enable-static=no --enable-shared=yes --with-quantum-depth=16 CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native" CXXFLAGS="-O2 -march=native" FFLAGS="-O2 -march=native" LDFLAGS="-L/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64 -Wl,-rpath,/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64" PKG_CONFIG_PATH=/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64/pkgconfig --prefix=/usr/local/gcc-6.2.0_binutils-2.27_isl | ||
The summary should be fine. As comparison and source of relevant informations: [[GraphicsMagick]] | The summary should be fine. As comparison and source of relevant informations: [[GraphicsMagick]] | ||
Line 264: | Line 369: | ||
{{codeline|exit}} root session, then {{codeline|exit}} current bash, to return to a clean state | {{codeline|exit}} root session, then {{codeline|exit}} current bash, to return to a clean state | ||
== Octave itself == | |||
The following - facultative - command avoids warnings like {{codeline|libtool: warning: '/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64/libgomp.la' seems to be moved}} | |||
sudo find /usr/local/gcc-6.2.0_binutils-2.27_isl -name "*.la" -exec sed -i 's:/lib64/../lib64:/lib64:g' {} \; -print | |||
which will replace all unnecessary {{codeline|/lib64/../lib64}} by {{codeline|/lib64}}. | |||
cd $downloads | |||
wget ftp://ftp.gnu.org/gnu/octave/octave-4.2.0.tar.lz | |||
Start from a clean state | |||
exit | |||
bash | |||
export PATH=/usr/local/gcc-6.2.0_binutils-2.27_isl/bin:$PATH | |||
which gfortran | |||
# should be /usr/local/gcc-6.2.0_binutils-2.27_isl/bin/gfortran | |||
cd $buildroot | |||
tar --no-same-owner -xvf $downloads/octave-4.2.0.tar.lz | |||
cd octave-4.2.0 | |||
mkdir build-; cd $_ | |||
../configure --with-blas="/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64/libopenblas.so" CPPFLAGS="-I/usr/local/gcc-6.2.0_binutils-2.27_isl/include" CFLAGS="-O2 -march=native" CXXFLAGS="-O2 -march=native" FFLAGS="-O2 -march=native" LDFLAGS="-L/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64 -Wl,-rpath,/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64" PKG_CONFIG_PATH=/usr/local/gcc-6.2.0_binutils-2.27_isl/lib64/pkgconfig JAVA_HOME=/usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/ --prefix=/usr/local/gcc-6.2.0_binutils-2.27_isl | |||
make -j 6 | |||
make check | |||
# or, for nvidia users, | |||
xvfb-run -s "-screen 0 640x480x24" make check LD_PRELOAD=/usr/lib64/libGL.so | |||
as root ({{codeline|su}}, not {{codeline|sudo}}, because we want PATH to contain {{Path|/usr/local/gcc-6.2.0_binutils-2.27_isl/bin}}) | |||
make install | |||
{{codeline|exit}} root session, then {{codeline|exit}} current bash, to return to a clean state | |||
Done. | |||
[[Category:Building]] |
edits