From 9894a94cf7195f052016a20e4df9fb252252978809e0af5ff095eabecc72d8c1 Mon Sep 17 00:00:00 2001 From: Andreas Stieger Date: Sun, 25 Jun 2017 17:03:45 +0000 Subject: [PATCH] Accepting request 506129 from home:AndreasStieger:branches:Archiving - fix CentOS/RHEL builds after clean-up OBS-URL: https://build.opensuse.org/request/show/506129 OBS-URL: https://build.opensuse.org/package/show/Base:System/xz?expand=0&rev=90 --- xz.changes | 5 +++++ xz.spec | 17 ++++++++++++++--- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/xz.changes b/xz.changes index 6c4506a..170457e 100644 --- a/xz.changes +++ b/xz.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sun Jun 25 11:37:03 UTC 2017 - astieger@suse.com + +- fix CentOS/RHEL builds after clean-up + ------------------------------------------------------------------- Wed Jun 21 14:11:44 UTC 2017 - mpluskal@suse.com diff --git a/xz.spec b/xz.spec index 551ff69..b07232b 100644 --- a/xz.spec +++ b/xz.spec @@ -18,7 +18,6 @@ # avoid bootstrapping problem %define _binary_payload w9.bzdio - Name: xz Version: 5.2.3 Release: 0 @@ -34,9 +33,12 @@ Source3: xz.keyring Source4: xznew Source5: xznew.1 BuildRequires: pkgconfig -Recommends: %{name}-lang Provides: lzma = %{version} Obsoletes: lzma < %{version} +BuildRoot: %{_tmppath}/%{name}-%{version}-build +%if 0%{?lang_package:1} +Recommends: %{name}-lang +%endif %description The xz command is a very powerful program for compressing files. @@ -90,7 +92,7 @@ export LDFLAGS="-Wl,-z,relro,-z,now -pie" %configure \ --with-pic \ --docdir=%{_docdir}/%{name} -%if %{do_profiling} +%if 0%{?do_profiling} make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_generate}" make check %{?_smp_mflags} make clean @@ -103,7 +105,11 @@ export LDFLAGS="-Wl,-z,relro,-z,now -pie" make %{?_smp_mflags} check %install +%if 0%{?make_install:1} %make_install +%else +make DESTDIR=%{buildroot} install %{?_smp_mflags} # +%endif find %{buildroot} -type f -name "*.la" -delete -print %find_lang %{name} install -Dpm 0755 %{SOURCE4} %{buildroot}%{_bindir}/xznew @@ -112,8 +118,10 @@ install -Dpm 0644 %{SOURCE5} %{buildroot}%{_mandir}/man1/xznew.1 %post -n liblzma5 -p /sbin/ldconfig %postun -n liblzma5 -p /sbin/ldconfig +%if 0%{?lang_package:1} %files lang -f %{name}.lang %defattr(-, root, root) +%endif %files %defattr(-, root, root) @@ -166,6 +174,9 @@ install -Dpm 0644 %{SOURCE5} %{buildroot}%{_mandir}/man1/xznew.1 %{_mandir}/man1/xzless.1%{ext_man} %{_mandir}/man1/xzmore.1%{ext_man} %{_mandir}/man1/xznew.1%{ext_man} +%if 0%{!?lang_package:1} +%{_datadir}/locale/*/LC_MESSAGES/xz.mo +%endif %files -n liblzma5 %defattr(-, root, root)