Sync from SUSE:SLFO:Main devscripts revision 5a064ceded61f9c82e2031d4f267516a

This commit is contained in:
Adrian Schröter 2024-05-03 12:02:49 +02:00
commit fda1c9aacd
7 changed files with 1251 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

View File

@ -0,0 +1,13 @@
--- a/scripts/debcommit.pl
+++ b/scripts/debcommit.pl
@@ -663,7 +663,9 @@ sub commit {
} else {
die "debcommit: unknown program $prog";
}
- die "debcommit: commit failed\n" if (!$action_rc);
+ # mercurial 1.6 returns failure if nothing is to be committed
+ # but we still want to continue with tagging
+ die "debcommit: commit failed\n" if (!$action_rc) && (!$release);
}
sub tag {

View File

@ -0,0 +1,51 @@
Index: devscripts-v2.22.2/Makefile
===================================================================
--- devscripts-v2.22.2.orig/Makefile
+++ devscripts-v2.22.2/Makefile
@@ -4,7 +4,7 @@ include Makefile.common
DESTDIR =
-all: version doc make_scripts conf.default translated_manpages
+all: version doc conf.default
version:
rm -f version
Index: devscripts-v2.22.2/Makefile.common
===================================================================
--- devscripts-v2.22.2.orig/Makefile.common
+++ devscripts-v2.22.2/Makefile.common
@@ -14,3 +14,5 @@ PERLMOD_DIR = $(shell perl -MConfig -e '
DATA_DIR = $(PREFIX)/share/devscripts
TEMPLATES_DIR = $(DATA_DIR)/templates
SYSCONFDIR = /etc
+
+XSL_STYLESHEET = /usr/share/sgml/docbook/stylesheet/xsl/nwalsh/manpages/docbook.xsl
Index: devscripts-v2.22.2/po4a/Makefile
===================================================================
--- devscripts-v2.22.2.orig/po4a/Makefile
+++ devscripts-v2.22.2/po4a/Makefile
@@ -33,8 +33,7 @@ clean: ../doc/devscripts.1
-podchecker $<
pod2man --utf8 --center=" " --release="$(DESC_$(dir $@))" $< > $@
%.1:: %.dbk translate
- xsltproc --nonet \
- /usr/share/sgml/docbook/stylesheet/xsl/nwalsh/manpages/docbook.xsl $<
+ xsltproc --nonet -o $@ $(XSL_STYLESHEET) $<
# /usr/share/sgml/docbook/stylesheet/xsl/nwalsh/manpages/other.xsl
# (which is imported by the above stylesheet) insists in writing the output
# to where it wants to. we can only move the file ourselves.
Index: devscripts-v2.22.2/scripts/Makefile
===================================================================
--- devscripts-v2.22.2.orig/scripts/Makefile
+++ devscripts-v2.22.2/scripts/Makefile
@@ -87,8 +87,7 @@ endif
podchecker $<
pod2man --utf8 --center=" " --release="Debian Utilities" $< > $@
%.1: %.dbk
- xsltproc --nonet -o $@ \
- /usr/share/sgml/docbook/stylesheet/xsl/nwalsh/manpages/docbook.xsl $<
+ xsltproc --nonet -o $@ $(XSL_STYLESHEET) $<
# Syntax checker
test_sh: $(SH_CHECKS)

View File

@ -0,0 +1,11 @@
--- a/scripts/Makefile
+++ b/scripts/Makefile
@@ -121,7 +120,7 @@ clean:
test: test_pl test_sh test_py
install: all
- python3 setup.py install --root="$(DESTDIR)" --no-compile --install-layout=deb
+ python3 setup.py install --root="$(DESTDIR)" --prefix="$(PREFIX)" --no-compile
cp $(SCRIPTS) $(DESTDIR)$(BINDIR)
ln -sf edit-patch $(DESTDIR)$(BINDIR)/add-patch
install -d $(DESTDIR)$(COMPL_DIR)

BIN
devscripts-v2.22.2.tar.bz2 (Stored with Git LFS) Normal file

Binary file not shown.

1005
devscripts.changes Normal file

File diff suppressed because it is too large Load Diff

145
devscripts.spec Normal file
View File

@ -0,0 +1,145 @@
#
# spec file for package devscripts
#
# Copyright (c) 2022 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#
%define _xsl_stylesheet %{_datadir}/xml/docbook/stylesheet/nwalsh/current/manpages/docbook.xsl
Name: devscripts
Version: 2.22.2
Release: 0
Summary: Scripts to make the life of a Debian Package maintainer easier
License: (Artistic-1.0 OR GPL-1.0-or-later) AND Artistic-2.0 AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND GPL-3.0-only AND SUSE-Public-Domain AND ISC
Group: Development/Tools/Building
URL: https://salsa.debian.org/debian/devscripts
Source: https://salsa.debian.org/debian/devscripts/-/archive/v%{version}/devscripts-v%{version}.tar.bz2
# PATCH-FIX-OPENSUSE devscripts-fix-build.patch -- Fix docbook template directories path.
Patch0: devscripts-fix-build.patch
# PATCH-FIX-OPENSUSE devscripts-fix-python-install-layout.patch -- Remove Debian's --install-layout=deb from setup.py.
Patch1: devscripts-fix-python-install-layout.patch
# PATCH-FEATURE-OPENSUSE devscripts-debcommit-hg16.patch -- Mercurial cannot commit empty, fix it.
Patch2: devscripts-debcommit-hg16.patch
BuildRequires: bash-completion-devel
BuildRequires: docbook-xsl-stylesheets
BuildRequires: dpkg-devel >= 1.18.19
BuildRequires: help2man
BuildRequires: libxslt
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: sgmltool
BuildRequires: texlive-latex
BuildRequires: zlib-devel
Requires: checkbashisms >= %{version}
Requires: dpkg
Requires: html2text
Requires: perl-File-HomeDir
Requires: perl-IPC-Run
Requires: perl-Moo
# provides same %_bindir/hardening-check binary
Conflicts: hardening-check
Provides: deb:%{_bindir}/debchange
%{?perl_requires}
%description
Collection of scripts for working on Debian packages.
Examples:
- bts: A command-line tool for manipulating the Debian Bug
Tracking System.
- dcontrol: Remotely query package and source control files for
all Debian distributions.
- debchange/dch: Automagically add entries to debian/changelog
files.
- debsign, debrsign: Sign a .changes/.dsc pair without needing any
of the rest of the package to be present; can sign the pair
remotely or fetch the pair from a remote machine for signing.
- diff2patches: Extract patches from a .diff.gz file placing them
under debian/ or, if present, debian/patches.
- licensecheck: Attempt to determine the license of source files.
- uscan: Scan upstream sites for new releases of packages.
%package -n checkbashisms
Summary: Tool for checking /bin/sh scripts for possible bashisms
License: GPL-2.0-or-later
Group: Development/Tools/Building
Provides: deb:%{_bindir}/checkbashisms
Provides: devscripts:%{_bindir}/checkbashisms
BuildArch: noarch
%{?perl_requires}
%description -n checkbashisms
checkbashisms performs basic checks on /bin/sh shell scripts for
the possible presence of bashisms. It takes the names of the shell
scripts on the command line, and outputs warnings if possible
bashisms are detected.
%prep
%setup -q -n devscripts-v%{version}
%patch0 -p1
%patch1 -p1
%patch2 -p1
%build
make %{?_smp_mflags} V=1 \
XSL_STYLESHEET="%{_xsl_stylesheet}"
%install
%make_install \
XSL_STYLESHEET="%{_xsl_stylesheet}"
# remove completion that was provided in older bash completion
%if 0%{?suse_version} <= 1500
rm %{buildroot}%{_datadir}/bash-completion/completions/bts
%endif
mkdir -p %{buildroot}%{_mandir}/man1/
install -Dpm 0644 scripts/*.1 -t %{buildroot}%{_mandir}/man1/
while read target link; do
if [ -d $(dirname "%{buildroot}$link") ]; then
ln -sf "$target" "%{buildroot}$link"
fi
done < debian/links
# Fix documentation.
mkdir -p %{buildroot}%{_docdir}/
if [ "%{_datadir}/doc" != "%{_docdir}" ]; then
mv %{buildroot}%{_datadir}/doc/devscripts %{buildroot}%{_docdir}/
fi
install -Dpm 0644 debian/changelog %{buildroot}%{_docdir}/devscripts/changelog
%files
%license debian/copyright COPYING
%doc %{_docdir}/devscripts/
%{_bindir}/*
%exclude %{_bindir}/checkbashisms
%{_datadir}/devscripts/
%{python3_sitelib}/devscripts/
%{python3_sitelib}/devscripts-*
%{perl_vendorlib}/Devscripts/
%{_datadir}/bash-completion/completions/*
%exclude %{_datadir}/bash-completion/completions/checkbashisms
%{_mandir}/man?/*.?%{?ext_man}
%exclude %{_mandir}/man1/checkbashisms.1%{?ext_man}
%files -n checkbashisms
%license debian/copyright COPYING
%{_bindir}/checkbashisms
%{_datadir}/bash-completion/completions/checkbashisms
%{_mandir}/man1/checkbashisms.1%{?ext_man}
%changelog