279b62307c
* Fix directory traversal with dpkg-deb --raw-extract, by guaranteeing that the DEBIAN pathname does not exist. Closes: #879982 Reported by Jakub Wilk <jwilk@jwilk.net>. * Rename DPKG_GAIN_ROOT_CMD to DEB_GAIN_ROOT_CMD in the R³ support, as the variable is expected to be set by any builder, not just dpkg. And introduce ephemereal backwards compatibility even though there are no known users. * Do not set DEB_GAIN_ROOT_CMD in dpkg-buildpackage when the R³ value is <implementations-keywords>, following the specification. * Specify that DEB_GAIN_ROOT_CMD in R³ should preserve the environment. Proposed by Josh Triplett <josh@joshtriplett.org>. * Specify new DEB_RULES_REQUIRES_ROOT variable for R³ support. * Declare R³ specification as "recommendation, stable" with version 1.0. * Architecture support: - Add support for riscv64 CPU. Closes: #822914 Thanks to Manuel A. Fernandez Montecelo <mafm@debian.org> * Perl modules: - Dpkg::Vendor::Debian: Use proper %use_feature key. This was causing perl errors on paths not accapted for fixdebugpath. Reported by Mattia Rizzolo <mattia@debian.org>, on IRC. Closes: #881051 - Check that $state->{seen} exists instead of $state being just defined. Fixes regression in dpkg-gensymbols symbols output. Thanks to Dmitry Shachnev <mitya57@debian.org>. Closes: #880166 - Mark hurd-i386 as having gcc builtin PIE in Dpkg::Vendor::Debian. Requested by Samuel Thibault <sthibault@debian.org>. - split the u-a to separate spec file to reduce a build cycle - update to debhelper-7.3.12 - update to debhelper-7.2.16 * dh_scrollkeeper: Now a deprecated no-op. OBS-URL: https://build.opensuse.org/package/show/system:packagemanager/dpkg?expand=0&rev=65
97 lines
3.3 KiB
RPMSpec
97 lines
3.3 KiB
RPMSpec
#
|
|
# spec file for package update-alternatives
|
|
#
|
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
Name: update-alternatives
|
|
Version: 1.19.0.5
|
|
Release: 0
|
|
Summary: Maintain symbolic links determining default commands
|
|
License: GPL-2.0-or-later
|
|
Group: System/Management
|
|
Url: http://ftp.de.debian.org/debian/pool/main/d/dpkg/
|
|
Source0: http://ftp.de.debian.org/debian/pool/main/d/dpkg/dpkg_%{version}.tar.xz
|
|
Source3: sensible-editor
|
|
Patch0: update-alternatives-suse.patch
|
|
BuildRequires: autoconf
|
|
BuildRequires: automake
|
|
BuildRequires: libtool
|
|
BuildRequires: ncurses-devel
|
|
BuildRequires: pkgconfig
|
|
Requires(post): coreutils
|
|
Requires(post): update-alternatives
|
|
Provides: alternatives = %{version}
|
|
|
|
%description
|
|
update-alternatives creates, removes, maintains and displays
|
|
information about the symbolic links comprising the alternatives
|
|
system. It is possible for several programs fulfilling the same or
|
|
similar functions to be installed on a single system at the same time.
|
|
For example, many systems have several text editors installed at once.
|
|
This gives choice to the users of a system, allowing each to use a
|
|
different editor, if desired, but makes it difficult for a program to
|
|
make a good choice of editor to invoke if the user has not specified a
|
|
particular preference.
|
|
|
|
%prep
|
|
%setup -q -n dpkg-%{version}
|
|
%patch0 -p1
|
|
|
|
%build
|
|
autoreconf -fvi
|
|
%configure \
|
|
--disable-silent-rules \
|
|
--with-admindir=%{_localstatedir}/lib
|
|
|
|
make -C lib/compat %{?_smp_mflags}
|
|
make -C utils/ %{?_smp_mflags}
|
|
make -C man/ %{?_smp_mflags}
|
|
|
|
%install
|
|
install -d -m 0755 %{buildroot}/%{_sbindir}/
|
|
install -d -m 0755 %{buildroot}/%{_mandir}/man1/
|
|
install -d -m 0755 %{buildroot}/%{_sysconfdir}/alternatives
|
|
install -d -m 0755 %{buildroot}%{_localstatedir}/lib/alternatives
|
|
install -d -m 0755 %{buildroot}/%{_localstatedir}/log
|
|
|
|
install -pm 0755 utils/%{name} %{buildroot}/%{_sbindir}
|
|
ln -s %{name} %{buildroot}/%{_sbindir}/alternatives
|
|
install -pm 0644 man/%{name}.1 %{buildroot}/%{_mandir}/man1/
|
|
|
|
%post
|
|
# Migrate to new location
|
|
if [ -d var/lib/rpm/alternatives ]; then
|
|
echo "migrating update alternatives database to new location"
|
|
# We proceed even if no alternatives directory exists, such situation
|
|
# occurs in buildroot environment (we can't buildrequire package
|
|
# itself).
|
|
mv -f var/lib/rpm/alternatives/* %{_localstatedir}/lib/alternatives/ || :
|
|
rmdir var/lib/rpm/alternatives ||:
|
|
fi
|
|
|
|
touch %{_localstatedir}/log/alternatives.log
|
|
|
|
%files
|
|
%doc COPYING
|
|
%dir %{_sysconfdir}/alternatives
|
|
%dir %{_localstatedir}/lib/alternatives
|
|
%{_sbindir}/alternatives
|
|
%{_sbindir}/update-alternatives
|
|
%{_mandir}/man1/update-alternatives.1%{ext_man}
|
|
%ghost %{_localstatedir}/log/alternatives.log
|
|
|
|
%changelog
|