SHA256
3
0
forked from pool/zlib

Accepting request 97969 from Base:System

- use configure options for library paths. Also fixes
  the pkg-config file to not have /usr/local bnc#738169 (forwarded request 97895 from msmeissn)

OBS-URL: https://build.opensuse.org/request/show/97969
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/zlib?expand=0&rev=44
This commit is contained in:
Stephan Kulow 2011-12-27 17:39:53 +00:00 committed by Git OBS Bridge
parent 77f3581b3e
commit 86e6a8d17a
2 changed files with 12 additions and 8 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Dec 22 14:31:42 CET 2011 - meissner@suse.de
- use configure options for library paths. Also fixes
the pkg-config file to not have /usr/local bnc#738169
------------------------------------------------------------------- -------------------------------------------------------------------
Wed Dec 7 15:29:27 UTC 2011 - coolo@suse.com Wed Dec 7 15:29:27 UTC 2011 - coolo@suse.com

View File

@ -15,6 +15,7 @@
# Please submit bugfixes or comments via http://bugs.opensuse.org/ # Please submit bugfixes or comments via http://bugs.opensuse.org/
# #
Name: zlib Name: zlib
Provides: libz Provides: libz
Obsoletes: libz Obsoletes: libz
@ -89,14 +90,14 @@ export LDFLAGS="-Wl,-z,relro,-z,now"
%if %{do_profiling} %if %{do_profiling}
profiledir=$(mktemp -d) profiledir=$(mktemp -d)
trap "rm -rf $profiledir" EXIT trap "rm -rf $profiledir" EXIT
CC="%__cc" ./configure --shared CC="%__cc" ./configure --shared --prefix=%_prefix --libdir=/%_lib
%{__make} CFLAGS="$RPM_OPT_FLAGS %{cflags_profile_generate}=$profiledir" %{?_smp_mflags} %{__make} CFLAGS="$RPM_OPT_FLAGS %{cflags_profile_generate}=$profiledir" %{?_smp_mflags}
time make check time make check
make clean make clean
%{__make} CFLAGS="$RPM_OPT_FLAGS %{cflags_profile_feedback}=$profiledir" %{?_smp_mflags} %{__make} CFLAGS="$RPM_OPT_FLAGS %{cflags_profile_feedback}=$profiledir" %{?_smp_mflags}
%else %else
export CFLAGS="%optflags" export CFLAGS="%optflags"
CC="%__cc" ./configure --shared CC="%__cc" ./configure --shared --prefix=%_prefix --libdir=/%_lib
%{__make} %{?_smp_mflags} %{__make} %{?_smp_mflags}
%endif %endif
@ -104,12 +105,9 @@ CC="%__cc" ./configure --shared
time make check time make check
%install %install
mkdir -p %{buildroot}{/%{_lib},%{_libdir}} #mkdir -p %{buildroot}%{_mandir}/man3
mkdir -p %{buildroot}%{_mandir}/man3 mkdir -p %{buildroot}%{_libdir}
mkdir -p %{buildroot}%{_includedir} make install DESTDIR=%{buildroot}
make install \
prefix=%{buildroot}%{_prefix} \
libdir=%{buildroot}/%{_lib}
%{__ln_s} -v /%{_lib}/$(readlink %{buildroot}/%{_lib}/libz.so) %{buildroot}%{_libdir}/libz.so %{__ln_s} -v /%{_lib}/$(readlink %{buildroot}/%{_lib}/libz.so) %{buildroot}%{_libdir}/libz.so
%{__rm} -v %{buildroot}/%{_lib}/libz.so %{__rm} -v %{buildroot}/%{_lib}/libz.so
# static lib # static lib