use out-of-tree build

OBS-URL: https://build.opensuse.org/package/show/Archiving/lzlib?expand=0&rev=19
This commit is contained in:
Jan Engelhardt 2018-12-14 11:58:09 +00:00 committed by Git OBS Bridge
parent 2c9f5c09cc
commit 11f0718ad6

View File

@ -70,29 +70,26 @@ applications that want to make use of libcerror.
# not autoconf!
# don't use the configure macro here, as it will cause the configure script to
# skip parameters as soon as it encounters one that it doesn't understand
./configure \
--prefix="%_prefix" \
--bindir="%_bindir" \
--datadir="%_datadir" \
--includedir="%_includedir" \
--infodir="%_infodir" \
--libdir="%_libdir" \
--mandir="%_mandir" \
--sysconfdir="%_sysconfdir" \
--enable-shared \
CXX="g++" \
CPPFLAGS="%optflags" \
CXXFLAGS="%optflags"
mkdir build
pushd build/
../configure --prefix="%_prefix" --bindir="%_bindir" --datadir="%_datadir" \
--includedir="%_includedir" --infodir="%_infodir" --libdir="%_libdir" \
--mandir="%_mandir" --sysconfdir="%_sysconfdir" --enable-shared \
CC="%__cc" CFLAGS="%optflags" CXX="%__cxx" CXXFLAGS="%optflags"
make %{?_smp_mflags}
popd
%install
%make_install LDCONFIG=echo
pushd build/
%make_install LDCONFIG=true
popd
# configure had no --disable-static
rm -f "%buildroot/%_libdir"/*.a
%check
pushd build/
make %{?_smp_mflags} check
popd
%post -n %lname -p /sbin/ldconfig
%postun -n %lname -p /sbin/ldconfig
@ -110,6 +107,6 @@ make %{?_smp_mflags} check
%files devel
%_includedir/lzlib.h
%_libdir/liblz.so
%_infodir/lzlib.info%ext_info
%_infodir/lzlib.info*
%changelog