Accepting request 1164582 from home:dancermak:branches:Base:System

Revert Epoch, introduce multibuild and switch to using tar_scm for fetching the sources

OBS-URL: https://build.opensuse.org/request/show/1164582
OBS-URL: https://build.opensuse.org/package/show/Base:System/xz?expand=0&rev=157
This commit is contained in:
Danilo Spinella 2024-04-04 12:23:38 +00:00 committed by Git OBS Bridge
parent 3f14a8b2e3
commit 6e6c8a9fd4
9 changed files with 107 additions and 71 deletions

3
_multibuild Normal file
View File

@ -0,0 +1,3 @@
<multibuild>
<package>lang</package>
</multibuild>

16
_service Normal file
View File

@ -0,0 +1,16 @@
<services>
<service name="tar_scm" mode="manual">
<param name="url">https://git.tukaani.org/xz.git</param>
<param name="scm">git</param>
<param name="revision">v5.4.6</param>
<param name="versionformat">@PARENT_TAG@</param>
<param name="changesgenerate">enable</param>
<param name="versionrewrite-pattern">v(.*)</param>
</service>
<service mode="manual" name="set_version">
</service>
<service name="recompress" mode="manual">
<param name="file">*.tar</param>
<param name="compression">zstd</param>
</service>
</services>

4
_servicedata Normal file
View File

@ -0,0 +1,4 @@
<servicedata>
<service name="tar_scm">
<param name="url">https://git.tukaani.org/xz.git</param>
<param name="changesrevision">6e8732c5a317a349986a4078718f1d95b67072c5</param></service></servicedata>

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:aeba3e03bf8140ddedf62a0a367158340520f6b384f75ca6045ccc6c0d43fd5c
size 2889306

Binary file not shown.

3
xz-5.4.6.tar.zst Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:efbbd1d2917dd3b1b8e7c691ad287f96792b87c6888efc28482c06dc6e5044e5
size 907627

View File

@ -1,7 +1,10 @@
-------------------------------------------------------------------
Thu Apr 4 07:16:46 UTC 2024 - Dan Čermák <dcermak@suse.com>
- Bump epoch to 1 and restore a sane version number
- Switch to using tar_scm for fetching the sources as the upstream
tarballs on github are gone
- introduce _multibuild to allow building the translations outside
of Ring0 and everything else in Ring0
-------------------------------------------------------------------
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 @@
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%global flavor @BUILD_FLAVOR@%{nil}
%if "%{flavor}" == "lang"
%bcond_without lang
%else
%bcond_with lang
%endif
# avoid bootstrapping problem
%if 0%{?suse_version} == 1500
@ -23,23 +30,38 @@
%bcond_with static
%endif
%define _binary_payload w9.bzdio
%global real_ver 5.4.6
Name: xz
Version: 5.4.6
Epoch: 1
Version: 5.6.1.revertto5.4
Release: 0
Summary: A Program for Compressing Files with the LempelZivMarkov algorithm
License: 0BSD AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-2.1-or-later
Group: Productivity/Archiving/Compression
URL: https://tukaani.org/xz/
Source0: https://github.com/tukaani-project/xz/releases/download/v%{version}/xz-%{version}.tar.gz
Source1: https://github.com/tukaani-project/xz/releases/download/v%{version}/xz-%{version}.tar.gz.sig
Source0: %{name}-%{real_ver}.tar.zst
Source2: baselibs.conf
Source3: https://tukaani.org/misc/jia_tan_pubkey.txt#/%{name}.keyring
Source4: xznew
Source5: xznew.1
BuildRequires: pkgconfig
Provides: lzma = %{version}
Obsoletes: lzma < %{version}
BuildRequires: zstd
# for autoreconf
BuildRequires: autoconf
BuildRequires: automake
# required by autoconf for autopoint
BuildRequires: gettext-tools
# needed by autopoint
BuildRequires: findutils
BuildRequires: libtool
%if %{with lang}
# required to update manpage translations
BuildRequires: po4a
BuildArch: noarch
%endif
Provides: lzma = %{real_ver}
Obsoletes: lzma < %{real_ver}
%{?suse_build_hwcaps_libs}
%description
@ -55,13 +77,16 @@ The xz command is a program for compressing files.
decompressing speed.
* Very similar command line interface to what gzip and bzip2 have.
%if %{with lang}
%lang_package
%else
%package -n liblzma5
Summary: LempelZivMarkov chain algorithm compression library
License: 0BSD
Group: System/Libraries
Provides: liblzma5 = %{version}
Provides: liblzma5 = %{real_ver}
%description -n liblzma5
Library for encoding/decoding LZMA files.
@ -70,11 +95,11 @@ Library for encoding/decoding LZMA files.
Summary: Development package for the LZMA library
License: 0BSD
Group: Development/Libraries/C and C++
Requires: liblzma5 = %{version}
Provides: lzma-devel = %{version}
Obsoletes: lzma-devel < %{version}
Provides: lzma-alpha-devel = %{version}
Obsoletes: lzma-alpha-devel < %{version}
Requires: liblzma5 = %{real_ver}
Provides: lzma-devel = %{real_ver}
Obsoletes: lzma-devel < %{real_ver}
Provides: lzma-alpha-devel = %{real_ver}
Obsoletes: lzma-alpha-devel < %{real_ver}
%description devel
This package contains the header files and libraries needed for
@ -85,25 +110,32 @@ compiling programs using the LZMA library.
Summary: Static version of LZMA library
License: SUSE-Public-Domain
Group: Development/Libraries/C and C++
Requires: lzma-devel = %{version}
Requires: lzma-devel = %{real_ver}
%description static-devel
Static library for the LZMA library
%endif
# without lang
%endif
%prep
%autosetup
%autosetup -n %{name}-%{real_ver}
%build
%global _lto_cflags %{_lto_cflags} -ffat-lto-objects
export CFLAGS="%{optflags} -D_REENTRANT -pipe -fPIE"
export LDFLAGS="-Wl,-z,relro,-z,now -pie"
autoreconf -fi
# Either we build it without pic enabled, or we build one at a time
%if %{with static}
%configure \
--with-pic \
--docdir=%{_docdir}/%{name} \
--disable-shared CONFIG_SHELL=/bin/sh
%make_build
cp ./src/liblzma/.libs/liblzma.a liblzma.a
%endif
@ -120,6 +152,11 @@ cp ./src/liblzma/.libs/liblzma.a liblzma.a
%make_build
%endif
%if %{with lang}
# update manpage translations
./po4a/update-po
%endif
%check
%make_build check
@ -134,10 +171,22 @@ install -Dpm 0644 liblzma.a %{buildroot}%{_libdir}/
%endif
rm -vf %{buildroot}%{_docdir}/%{name}/{COPYING,COPYING.GPLv2}
%if %{without lang}
%post -n liblzma5 -p /sbin/ldconfig
%postun -n liblzma5 -p /sbin/ldconfig
%endif
%if %{with lang}
%files lang -f %{name}.lang
# exclude everything of the other packages
%exclude %_docdir
%exclude %_bindir
%exclude %_mandir/man1
%exclude %{_includedir}
%exclude %_libdir
%exclude /usr/src/debug/
%exclude /usr/lib/debug/
%dir %{_mandir}/fr
%dir %{_mandir}/de
%dir %{_mandir}/ko
@ -145,7 +194,9 @@ rm -vf %{buildroot}%{_docdir}/%{name}/{COPYING,COPYING.GPLv2}
%dir %{_mandir}/ro
%dir %{_mandir}/uk
%endif
%endif
%if %{without lang}
%files
%license COPYING COPYING.GPLv2
%{_docdir}/%{name}
@ -198,6 +249,14 @@ rm -vf %{buildroot}%{_docdir}/%{name}/{COPYING,COPYING.GPLv2}
%{_mandir}/man1/xzmore.1%{?ext_man}
%{_mandir}/man1/xznew.1%{?ext_man}
# covered by -lang subpackage
%exclude %{_mandir}/fr
%exclude %{_mandir}/de
%exclude %{_mandir}/ko
%exclude %{_mandir}/ro
%exclude %{_mandir}/uk
%exclude /usr/share/locale
%files -n liblzma5
%{_libdir}/liblzma.so.5*
@ -214,4 +273,7 @@ rm -vf %{buildroot}%{_docdir}/%{name}/{COPYING,COPYING.GPLv2}
%{_libdir}/liblzma.a
%endif
# without lang end
%endif
%changelog