Rebuild for debugging

This commit is contained in:
sagitter 2017-10-01 16:55:11 +02:00
parent c3c3682ba7
commit 9617ef11e1

View File

@ -5,7 +5,7 @@
%bcond_without check %bcond_without check
## Debug builds ? ## Debug builds ?
%bcond_with debug %bcond_without debug
# #
# Define _pkgdocdir macro on epel # Define _pkgdocdir macro on epel
@ -110,7 +110,7 @@
Name: petsc Name: petsc
Summary: Portable Extensible Toolkit for Scientific Computation Summary: Portable Extensible Toolkit for Scientific Computation
Version: 3.7.7 Version: 3.7.7
Release: 3%{?dist} Release: 4%{?dist}
License: BSD License: BSD
URL: https://www.mcs.anl.gov/petsc URL: https://www.mcs.anl.gov/petsc
Source0: http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/petsc-%{version}.tar.gz Source0: http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/petsc-%{version}.tar.gz
@ -379,8 +379,14 @@ cp -a %{name}-%{version} buildmpich_dir
%build %build
pushd %{name}-%{version} pushd %{name}-%{version}
%configure CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \ %configure \
%if %{with debug}
CFLAGS="-O0 -g -Wl,-z,now" CXXFLAGS="-O0 -g -Wl,-z,now" FFLAGS="-O0 -g -Wl,-z,now -I%{libdir}/gfortran/modules" COPTFLAGS="-O0 -g -Wl,-z,now" \
CXXOPTFLAGS="-O0 -g -Wl,-z,now" FOPTFLAGS="-O0 -g -Wl,-z,now -fPIC -I%{libdir}/gfortran/modules" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
%else
CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \ COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \
%endif
--with-default-arch=0 --with-make=1 \ --with-default-arch=0 --with-make=1 \
--with-single-library=1 \ --with-single-library=1 \
--with-precision=double \ --with-precision=double \
@ -453,8 +459,14 @@ popd
%if %{with arch64} %if %{with arch64}
pushd build64 pushd build64
%configure CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \ %configure \
%if %{with debug}
CFLAGS="-O0 -g -Wl,-z,now" CXXFLAGS="-O0 -g -Wl,-z,now" FFLAGS="-O0 -g -Wl,-z,now -I%{libdir}/gfortran/modules" COPTFLAGS="-O0 -g -Wl,-z,now" \
CXXOPTFLAGS="-O0 -g -Wl,-z,now" FOPTFLAGS="-O0 -g -Wl,-z,now -fPIC -I%{libdir}/gfortran/modules" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
%else
CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \ COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \
%endif
--with-default-arch=0 --with-make=1 \ --with-default-arch=0 --with-make=1 \
--with-single-library=1 \ --with-single-library=1 \
--with-precision=double \ --with-precision=double \
@ -509,8 +521,14 @@ popd
%if %{with openmpi} %if %{with openmpi}
pushd buildopenmpi_dir pushd buildopenmpi_dir
%{_openmpi_load} %{_openmpi_load}
%configure CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \ %configure \
%if %{with debug}
CFLAGS="-O0 -g -Wl,-z,now" CXXFLAGS="-O0 -g -Wl,-z,now" FFLAGS="-O0 -g -Wl,-z,now -I%{libdir}/gfortran/modules" COPTFLAGS="-O0 -g -Wl,-z,now" \
CXXOPTFLAGS="-O0 -g -Wl,-z,now" FOPTFLAGS="-O0 -g -Wl,-z,now -fPIC -I%{libdir}/gfortran/modules" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
%else
CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \ COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \
%endif
--with-default-arch=0 --with-make=1 \ --with-default-arch=0 --with-make=1 \
--with-single-library=1 \ --with-single-library=1 \
--with-precision=double \ --with-precision=double \
@ -615,8 +633,14 @@ popd
%if %{with mpich} %if %{with mpich}
pushd buildmpich_dir pushd buildmpich_dir
%{_mpich_load} %{_mpich_load}
%configure CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \ %configure \
%if %{with debug}
CFLAGS="-O0 -g -Wl,-z,now" CXXFLAGS="-O0 -g -Wl,-z,now" FFLAGS="-O0 -g -Wl,-z,now -I%{libdir}/gfortran/modules" COPTFLAGS="-O0 -g -Wl,-z,now" \
CXXOPTFLAGS="-O0 -g -Wl,-z,now" FOPTFLAGS="-O0 -g -Wl,-z,now -fPIC -I%{libdir}/gfortran/modules" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
%else
CFLAGS="$CFLAGS -O3 -Wl,-z,now" CXXFLAGS="$CXXFLAGS -O3" FFLAGS="$FFLAGS -O3 -Wl,-z,now" LDFLAGS="$LDFLAGS -Wl,-z,now -fPIC" \
COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \ COPTFLAGS="$COPTFLAGS" CXXOPTFLAGS="$CXXOPTFLAGS" FOPTFLAGS="$FOPTFLAGS -Wl,-z,now -fPIC" \
%endif
--with-default-arch=0 --with-make=1 \ --with-default-arch=0 --with-make=1 \
--with-single-library=1 \ --with-single-library=1 \
--with-precision=double \ --with-precision=double \
@ -988,6 +1012,9 @@ make -C buildmpich_dir test
%endif %endif
%changelog %changelog
* Sun Oct 01 2017 Antonio Trande <sagitter@fedoraproject.org> - 3.7.7-4
- Rebuild for debugging
* Sun Oct 01 2017 Antonio Trande <sagitter@fedoraproject.org> - 3.7.7-3 * Sun Oct 01 2017 Antonio Trande <sagitter@fedoraproject.org> - 3.7.7-3
- Exclude MPI builds on s390x - Exclude MPI builds on s390x