diff --git a/xz.changes b/xz.changes index 835b1ea..0ba81e5 100644 --- a/xz.changes +++ b/xz.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Dec 7 18:47:04 UTC 2010 - cristian.rodriguez@opensuse.org + +- Use compiler profile information, makes xz marginally faster + (around 1-2 secs) + ------------------------------------------------------------------- Sat Oct 30 20:17:49 UTC 2010 - jengelh@medozas.de diff --git a/xz.spec b/xz.spec index eee7577..8526b9e 100644 --- a/xz.spec +++ b/xz.spec @@ -20,7 +20,7 @@ Name: xz Summary: A Program for Compressing Files Version: 5.0.0 -Release: 1 +Release: 2 Group: Productivity/Archiving/Compression License: LGPLv2.1+ Url: http://tukaani.org/lzma/ @@ -80,11 +80,23 @@ compiling programs using the LZMA library. %build AUTOPOINT=true autoreconf -fiv +%if %{do_profiling} +profiledir=$(mktemp -d) +trap "rm -rf $profiledir" EXIT +export CFLAGS="%optflags %{cflags_profile_generate}=$profiledir" +%endif %configure --libdir=/%{_lib} --disable-static --with-pic --docdir=%_docdir/%name make %{?_smp_mflags} +%if %{do_profiling} +time make check +make clean +export CFLAGS="%optflags %{cflags_profile_feedback}=$profiledir" +%configure --libdir=/%{_lib} --disable-static --with-pic --docdir=%_docdir/%name +make %{?_smp_mflags} +%endif %check -LD_LIBRARY_PATH=$PWD/src/liblzma/.libs make check +time make check %install make install DESTDIR=$RPM_BUILD_ROOT