- Cleanup a bit with-spec-cleaner help
OBS-URL: https://build.opensuse.org/package/show/system:packagemanager/dpkg?expand=0&rev=21
This commit is contained in:
parent
8344784a15
commit
75cfd16202
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Apr 1 12:59:58 UTC 2015 - tchvatal@suse.com
|
||||
|
||||
- Cleanup a bit with-spec-cleaner help
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Apr 1 12:54:48 UTC 2015 - tchvatal@suse.com
|
||||
|
||||
|
59
dpkg.spec
59
dpkg.spec
@ -17,7 +17,6 @@
|
||||
|
||||
|
||||
%define admindir %{_localstatedir}/lib/rpm/
|
||||
|
||||
Name: dpkg
|
||||
Version: 1.17.24
|
||||
Release: 0
|
||||
@ -32,9 +31,10 @@ Patch1: update-alternatives-suse.patch
|
||||
# PATCH-FIX-UPSTREAM remove --utf8 since we only build En manpages.
|
||||
Patch6: dpkg-sparc.diff
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: libbz2-devel
|
||||
BuildRequires: libselinux-devel
|
||||
%define use_selinux 1
|
||||
BuildRequires: ncurses-devel
|
||||
BuildRequires: update-alternatives
|
||||
BuildRequires: xz
|
||||
BuildRequires: zlib-devel
|
||||
BuildRequires: perl(Date::Parse)
|
||||
@ -42,22 +42,17 @@ BuildRequires: perl(IO::String)
|
||||
Requires: cpio
|
||||
Requires: make
|
||||
Requires: patch
|
||||
Requires: perl = %{perl_version}
|
||||
Requires: update-alternatives
|
||||
Requires: perl(Date::Parse)
|
||||
Requires(pre): /bin/touch
|
||||
Recommends: perl(File::FcntlLock)
|
||||
Provides: deb = %{version}
|
||||
Obsoletes: deb < %{version}
|
||||
Provides: dpkg-dev = %{version}
|
||||
Provides: dpkg-doc = %{version}
|
||||
Provides: dselect = %{version}
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
Requires(pre): /bin/touch
|
||||
|
||||
%if 0%{?suse_version}
|
||||
BuildRequires: libbz2-devel
|
||||
BuildRequires: update-alternatives
|
||||
Requires: perl = %{perl_version}
|
||||
Requires: update-alternatives
|
||||
Requires: perl(Date::Parse)
|
||||
Recommends: perl(File::FcntlLock)
|
||||
%endif
|
||||
|
||||
%description
|
||||
This package contains tools for working with Debian packages. It makes
|
||||
@ -70,44 +65,27 @@ dpkg-doc, dpkg-dev.
|
||||
%package devel
|
||||
Summary: Development files for dpkg
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: %{name} = %{version}
|
||||
Provides: deb-devel = %{version}
|
||||
Obsoletes: deb-devel < %{version}
|
||||
Requires: %{name} = %{version}
|
||||
|
||||
%description devel
|
||||
Libraries and header files for dpkg.
|
||||
|
||||
%package lang
|
||||
Summary: Languages for package %{name}
|
||||
Group: System/Localization
|
||||
Requires: %{name} = %{version}
|
||||
Provides: %{name}-lang-all = %{version}
|
||||
Provides: deb-lang = %{version}
|
||||
Obsoletes: deb-lang < %{version}
|
||||
%if %{defined suse_version}
|
||||
Supplements: packageand(bundle-lang-other:%{name})
|
||||
BuildArch: noarch
|
||||
%endif
|
||||
|
||||
%description lang
|
||||
Provides translations to the package %{name}
|
||||
%lang_package
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
|
||||
%patch1 -p1
|
||||
%patch6 -p1
|
||||
|
||||
%build
|
||||
export CFLAGS="%{optflags}"
|
||||
%if 0%{?use_selinux}
|
||||
export SELINUX_LIBS="-lselinux"
|
||||
%endif
|
||||
%{configure}\
|
||||
%if 0%{?use_selinux}
|
||||
--with-selinux \
|
||||
%endif
|
||||
--localstatedir=%{_localstatedir}/lib \
|
||||
%configure \
|
||||
--disable-silent-rules \
|
||||
--with-selinux \
|
||||
--localstatedir=%{_localstatedir}/lib \
|
||||
--with-admindir=%{_localstatedir}/lib/dpkg
|
||||
|
||||
# configure somehow does not detect architecture correctly in OBS (bnc#469337), so
|
||||
@ -132,7 +110,7 @@ sed -i 's/^#define ARCHITECTURE ""/#define ARCHITECTURE "%{debarch}"/' config.h
|
||||
make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
%{__make} install DESTDIR=%{?buildroot}
|
||||
make install DESTDIR=%{?buildroot}
|
||||
|
||||
# remove update-alternatives stuff (included in separate package)
|
||||
rm -rf %{buildroot}%{_sysconfdir}/alternatives
|
||||
@ -143,16 +121,16 @@ rm -rf %{buildroot}%{_mandir}/man8/update-alternatives.8
|
||||
rm -rf %{buildroot}%{_mandir}/*/man8/update-alternatives.8
|
||||
|
||||
# locales
|
||||
%{find_lang} %{name}
|
||||
%{find_lang} dselect
|
||||
%{find_lang} dpkg-dev
|
||||
%find_lang %{name}
|
||||
%find_lang dselect
|
||||
%find_lang dpkg-dev
|
||||
cat dselect.lang dpkg-dev.lang >> %{name}.lang
|
||||
|
||||
# extras
|
||||
install -m 755 %{SOURCE3} %{buildroot}%{_bindir}
|
||||
|
||||
%check
|
||||
%{__make} check
|
||||
make %{?_smp_mflags} check
|
||||
|
||||
%post
|
||||
cd %{_localstatedir}/lib/dpkg
|
||||
@ -162,6 +140,7 @@ done
|
||||
exit 0
|
||||
|
||||
%files lang -f %{name}.lang
|
||||
%defattr(-,root,root)
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
|
Loading…
Reference in New Issue
Block a user