2016-06-09 07:49:24 +00:00
|
|
|
# While we are in package playing with packaging principles, why about having
|
|
|
|
# this solved in redhat-rpm-config too? (Also for RHELs which are alive, or
|
|
|
|
# EPELs otherwise).
|
|
|
|
%{!?_licensedir:%global license %doc}
|
|
|
|
|
|
|
|
# https://fedoraproject.org/wiki/Packaging:Guidelines#Packaging_of_Additional_RPM_Macros
|
|
|
|
%global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)
|
|
|
|
|
|
|
|
%global rrcdir %_libexecdir
|
|
|
|
|
|
|
|
Summary: Multilib packaging helpers
|
|
|
|
Name: multilib-rpm-config
|
|
|
|
Version: 1
|
2016-06-22 06:22:06 +00:00
|
|
|
Release: 5%{?dist}
|
2016-06-09 07:49:24 +00:00
|
|
|
License: GPLv2+
|
|
|
|
URL: https://fedoraproject.org/wiki/PackagingDrafts/MultilibTricks
|
|
|
|
|
|
|
|
Source0: multilib-fix
|
|
|
|
Source1: macros.ml
|
|
|
|
Source2: README
|
|
|
|
Source3: COPYING
|
2016-06-22 09:07:22 +00:00
|
|
|
Source4: multilib-library
|
|
|
|
Source5: multilib-info
|
2016-06-09 07:49:24 +00:00
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
# Most probably we want to move everything here?
|
|
|
|
Requires: redhat-rpm-config
|
|
|
|
|
|
|
|
%description
|
|
|
|
Set of tools (shell scripts, RPM macro files) to help with multilib packaging
|
|
|
|
issues.
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -c -T
|
|
|
|
install -m 644 %{SOURCE2} %{SOURCE3} .
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
%global ml_fix %rrcdir/multilib-fix
|
2016-06-22 09:07:22 +00:00
|
|
|
%global ml_info %rrcdir/multilib-info
|
|
|
|
|
|
|
|
lib_sed_pattern='/@LIB@/ {
|
|
|
|
r %{SOURCE4}
|
|
|
|
d
|
|
|
|
}'
|
|
|
|
|
2016-06-09 07:49:24 +00:00
|
|
|
sed -e 's|@ML_FIX@|%ml_fix|g' \
|
2016-06-22 09:07:22 +00:00
|
|
|
-e 's|@ML_INFO@|%ml_info|g' \
|
2016-06-09 07:49:24 +00:00
|
|
|
%{SOURCE1} > macros.multilib
|
2016-06-22 09:07:22 +00:00
|
|
|
sed -e "$lib_sed_pattern" \
|
|
|
|
%{SOURCE0} > multilib-fix
|
|
|
|
sed -e "$lib_sed_pattern" \
|
|
|
|
%{SOURCE5} > multilib-info
|
2016-06-09 07:49:24 +00:00
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
mkdir -p %{buildroot}%{rrcdir}
|
|
|
|
mkdir -p %{buildroot}%{macrosdir}
|
|
|
|
install -m 644 -p macros.multilib %{buildroot}/%{macrosdir}
|
2016-06-22 09:07:22 +00:00
|
|
|
install -m 755 -p multilib-fix %{buildroot}/%{ml_fix}
|
|
|
|
install -m 755 -p multilib-info %{buildroot}/%{ml_info}
|
2016-06-09 07:49:24 +00:00
|
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
%license COPYING
|
|
|
|
%doc README
|
|
|
|
%{rrcdir}/*
|
|
|
|
%{macrosdir}/*
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
2016-06-22 06:22:06 +00:00
|
|
|
* Wed Jun 22 2016 Pavel Raiskup <praiskup@redhat.com> - 1-5
|
|
|
|
- document why there is no need for '#else' in the replacement header
|
|
|
|
|
2016-06-13 21:38:43 +00:00
|
|
|
* Mon Jun 13 2016 Pavel Raiskup <praiskup@redhat.com> - 1-4
|
2016-06-13 21:45:10 +00:00
|
|
|
- use '-' as a field separator by default
|
2016-06-13 21:38:43 +00:00
|
|
|
|
2016-06-09 07:49:24 +00:00
|
|
|
* Thu Jun 09 2016 Pavel Raiskup <praiskup@redhat.com> - 1-3
|
|
|
|
- package separately from redhat-rpm-config
|
|
|
|
|
|
|
|
* Fri Nov 27 2015 Pavel Raiskup <praiskup@redhat.com> - 1-2
|
|
|
|
- fix licensing in Sources
|
|
|
|
- allow undefined %%namespace
|
|
|
|
|
|
|
|
* Wed Nov 18 2015 Pavel Raiskup <praiskup@redhat.com> - 1-1
|
|
|
|
- initial packaging
|