- update to version 283:

- Fix crash when objdump is missing when checking .EFI files.
- update to version 282:
 - Ignore errors when listing .ar archives. (Closes: #1085257)
 - Update copyright years.
- update to version 281:
 - Don't try and test with systemd-ukify within Debian stable.
 - Add support for UKI files.
- update to version 280:
 - Drop Depends on deprecated python3-pkg-resources. (Closes: #1083362)
- update to version 279:
 - Drop removal of calculated basename from readelf output.
   (Closes: reproducible-builds/diffoscope#394)
- update to version 278:
 - Temporarily remove procyon-decompiler from Build-Depends as it was removed
   from testing (#1057532). (Closes: #1082636)
 - Add a helpful contextual message to the output if comparing Debian .orig
   tarballs within .dsc files without the ability to "fuzzy-match" away the
   leading directory. (Closes: reproducible-builds/diffoscope#386)
 - Correctly invert "X% similar" value and do not emit "100% similar".
   (Closes: reproducible-builds/diffoscope#391)
 - Update copyright years.
- update to version 277:
 - Don't crash when attempting to hashing symlinks with targets that point to
   a directory.
- update to version 276:
 - Also catch RuntimeError when importing PyPDF so that PyPDF or, crucially,
   its transitive dependencies do not cause diffoscope to traceback at runtime
   and build time. (Closes: #1078944, reproducible-builds/diffoscope#389)
 - Factor out a method for stripping ANSI escapes.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/diffoscope?expand=0&rev=98
This commit is contained in:
Sebastian Wagner 2024-12-02 21:12:36 +00:00 committed by Git OBS Bridge
commit 962d0c8913
9 changed files with 2785 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

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
.osc

3
diffoscope-272.tar.bz2 Normal file
View File

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

View File

@ -0,0 +1,16 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCAAdFiEEwv5L0nHBObhsUz5GHpU+J9QxHlgFAmaIADgACgkQHpU+J9Qx
HljVSA//Ul9b0grmlcq4lrrCh7LEH7vvKunRd86po031QcWxZDUkzTM8XqHcOG2Y
48AJC+KdTGzzB7xPUDlRO7m7XBBG5AisOL3E9pfF3uzoaMD99INfyPdfJ7Fjo4K6
Q/W7n2kiCzUls9FiwrwXgFlrbsYADPnJnSesjg/d52TA3+pzK1ACaDVvYDbUVSTd
lHO6tzqyyaqqSgepDpP+zzfPgmtf+EwrRDfLxA+IXjggeq7TgpFCPwvoeMo5a3Ee
oXmAHQC+YynDHcY83yuXQ0u2FWs64UP3Gigasa/4gClxx4h2lI4jVBWgKWagu9xT
dOehAl2RRLZT4rgicGiOKjvmnpqu9JMjLrBltPz10MzlgXZFvLZDPI+hB9FD0aBi
e+iGdmqxN75Wvo2utK41wKYKM5B7lZwtQGDBfcnScJezRKXbSz6P2ZIRI9rW1RS3
UqZUrYjrs7RoPHbSy4RGRPINExpFhckDuEFyR10Q0BojGgAdZEqap9v7HwN4hjav
xMhP5OuhsuRfNKbBSvEe+e+PicgvH6Ywkb/ucOBBbGaBAwZ2V76+/5zf8+17eRSP
w5cClu2M8tlLt3MXl/++Qs7y6f2L5NME++7FijE6qr0mF7If+c1HyZPYUzLY4UJO
aiqR5H0365rz6f9fLW2WLrui8cpS+Db/OMPQ6CTw9cjWdjqLdS4=
=EHMm
-----END PGP SIGNATURE-----

3
diffoscope-283.tar.bz2 Normal file
View File

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

View File

@ -0,0 +1,16 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCAAdFiEEwv5L0nHBObhsUz5GHpU+J9QxHlgFAmcubzsACgkQHpU+J9Qx
HlgQ3w/9GVzXf/qz7TQ/r+JiMRJe1N/+JoAdXQcwF/735aBJFKbUcTkfD6o7/9yF
qNCLx2SHwXaXgz7EoPQ2OSc8tk4UGHnV4wliFNyy3saEMK+tcfPWX0S2KmOssKWB
FZPAOI0zopJxhXIWc/Vobhu2hm6ggMfJ5ljk7KyENDAT89NOIFGveFuGweHs0KCI
Neox3BtoNrseb96q043QecPdQ4XbzHUFNfbSOVhBEYuIFYW0LT1+6i3xWNFUEKWv
knheaVlAKUkj3fz09vZErgXNx4TwHx6LeFmt4npKMkfj2RGwcuOP07LfQ9h7eVLq
7gy0a9qkNl42ukomrlnR92LL0RSt/OdTR3E2FWgRt0BLkslgPDdBBCX1GO3ZK1JF
Lvk9uA35fy6DiEiwmGs5RqwPMfOBJoHxI7h6F4WPcvHrnByiJ/2dUayZcSRed6Gd
UxaJYhdpIQcOvZij+nUyQ19unuNIjLnOGuG0vJosdMlqH1Hs+H3HzCjyOEItPfGD
Kv4SdLq27LtAhB7gTVBr0kp9t7jct3z91GMDLPfmk/hAYEMjaDgi6tKB8liU4BVk
fiytL++svSoO8YihdqvskvUwDP61cs6oW2/UQgjvbdBLk8fPexot5MfM+/mGLswo
nXmgN76atkHq5tgprxra7z4Uc/eF2ni6oX67b9vV+DYfaJvP5z8=
=6UkP
-----END PGP SIGNATURE-----

2498
diffoscope.changes Normal file

File diff suppressed because it is too large Load Diff

76
diffoscope.keyring Normal file
View File

@ -0,0 +1,76 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
mQINBEpaPPMBEADG/4uW0xA0Fcx07pJgJMtka4DvehIcunxEj2QI4YTopdPyAkTj
9cNBljUtiZ1IvgtimQeJQt1XXyt5RR9q9nxn9D3Ce11JFe+TyO9YwVB4rIFk0ix8
QfyFM3VfCV003puS1rsh84Eytpl48Haht4EY4Xm03+ZlJAbfqk+VY8FmQGcV4+g6
9M3qdFSMGP9AzlM6bFel6vqEHvGKBxWt7JD2uIwF2CQAIaHS+3RU0AoJdAQF0OJy
2rW4B88tuGvnaxx/0lzT40xBvaO5nR9KzNf8n+YV6s59k6loiN1/fHaQTpCqNG6X
TNV6HbZg+O1VL00z8sNTMPy6fS56WncblAivUoxPlhV4CaleT52UO5Z2whU+9WGN
DWn88l3O+q8eD/C9JvHlAwWBv88CDz73eu/xoHw0Lu3Pio3sMuzetBu/P/KPEQvz
owYJkUr+oQbZ0NUvW8Vo/8hXXEK9fXW+o0NEUap5+qesfouNT7JpBjrM+LCuOmFU
MBOI7wDidogoyO5fjclG78NVwZYfH9MwhClZ7JF6c02YVtmW+wFV9aQ8RFLe923q
OEBZVSd4jmNby8/AMqekFAGFqtne/nJyEIIuVOhFwLsRr27G9ijypBT3/DgR4ovJ
NTcfXDAu0R4vVgz8hDcI7tQwr6Lt0XYqA+fzEDU3QO78QQhHcsf0b07j2wARAQAB
tCNDaHJpcyBMYW1iIDxjaHJpc0BjaHJpcy1sYW1iLmNvLnVrPokCOgQTAQgAJAIb
AwIeAQIXgAULCQgHAwUVCgkICwUWAgMBAAUCSlo+IwIZAQAKCRAelT4n1DEeWC6j
D/9V2Xd1zfT7CK/W6LBZdpKsm1h0fmXUDpQUaHfWjiZDctt8Zp2fBPL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sLmqOpXakBElp0iO3/GV9AKe
Iwm/FiKOx0zbVG2U8k5CqB9YvU6R3+f+w2v73xtDvOrEwn2nPREh2lG66Zqg2piC
WN3A7i9vJRHCIm+He1c/PFrIFCTFft4nqupYtQcSk5DohJOS5pUPqMV20QxXWO55
QPcpkmiXnojnI54Uc4M+OgoVaALgOUlA0tQIqQd9qevix8xLzYS6m/0HfI1KF2Ii
luqmsz6hWRL8NhW7z80N4NNldD0ppHQQXcjRG294lWHYZ8j0XnQhEh5V4eOSOM1c
PVMGvuHaIa76YPPZXv0gfdEqnM2mQA0QUYEBE5UPtJOGLFSR/bSjewMEj9j2dYo7
Ms0Nuhe9shty3nm0VCkerGD7kSNv41dRCcLvmTBAfOZVLnB5gahTzVLQi+TFLrli
PhhdfRap1821rV73gzbST/zh8Gfjf0uEfgb6LRrwRotzGIw9n+m1fks43qs/lO+Z
xNfR
=qega
-----END PGP PUBLIC KEY BLOCK-----

149
diffoscope.spec Normal file
View File

@ -0,0 +1,149 @@
#
# spec file for package diffoscope
#
# Copyright (c) 2024 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/
#
Name: diffoscope
Version: 283
Release: 0
Summary: In-depth comparison of files, archives, and directories
License: GPL-3.0-or-later
Group: Development/Languages/Python
URL: https://diffoscope.org/
Source0: https://diffoscope.org/archive/diffoscope-%{version}.tar.bz2
Source1: https://diffoscope.org/archive/diffoscope-%{version}.tar.bz2.asc
Source2: diffoscope.keyring
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: python3-base >= 3.7
BuildRequires: python3-curses
BuildRequires: python3-libarchive-c
BuildRequires: python3-pytest
BuildRequires: python3-python-magic
BuildRequires: python3-setuptools
Requires: python3-curses
Requires: python3-libarchive-c
Requires: python3-python-magic
Requires(post): update-alternatives
Requires(postun): update-alternatives
# Tools required for proper function of this program
# in extras_require
Recommends: python3-distro
Recommends: python3-argcomplete
Recommends: python3-defusedxml
Recommends: python3-jsondiff
Recommends: python3-progressbar
# for getfacl
Suggests: acl
# for ar, readelf, objcopy and objdump
Suggests: binutils
Suggests: bzip2
# for img2txt
Suggests: caca-utils
# for isoinfo
Suggests: cdrkit-cdrtools-compat
# for cbfstool
Suggests: coreboot-utils
# for stat
Suggests: coreutils
Suggests: cpio
# for cmp and diff
Suggests: diffutils
# for lsattr
Suggests: e2fsprogs
# for ppudump
Suggests: fpc
# for msgunfmt
Suggests: gettext-tools
# for ghc
Suggests: ghc-compiler
Suggests: gzip
# for pedump
Suggests: mono-devel
Suggests: pdftk
# for pdftotext
Suggests: poppler-tools
# for RPM unpacking
Suggests: python3-rpm
Suggests: sqlite3
# for unsquashfs
Suggests: squashfs
# for zipinfo
Suggests: unzip
# for xxd
Suggests: vim
Suggests: xz
# currently missing:
# enjarify, javap, lipo, otool, showttf, sng
BuildArch: noarch
%description
diffoscope will try to get to the bottom of what makes files or
directories different. It will recursively unpack archives of many kinds
and transform various binary formats into more human readable form to
compare them. It can compare two tarballs, ISO images, or PDF just as
easily.
It can be scripted through error codes, and a report can be produced
with the detected differences. The report can be text or HTML.
When no type of report has been selected, diffoscope defaults
to write a text report on the standard output.
diffoscope is developed as part of the `“reproducible builds” Debian
project <https://wiki.debian.org/ReproducibleBuilds>`_.
It is meant to be able to quickly understand why two builds of the same
package produce different outputs. diffoscope was previously named
debbindiff.
%prep
%autosetup -p1
sed -i '0,/#!\/usr\/bin\/env/ d' diffoscope/main.py
%build
%python3_build
%install
%python3_install
%fdupes %{buildroot}%{python3_sitelib}/
mv %{buildroot}%{_bindir}/diffoscope %{buildroot}%{_bindir}/diffoscope-%{py3_ver}
mkdir -p %{buildroot}%{_sysconfdir}/alternatives
ln -s -f %{_sysconfdir}/alternatives/diffoscope %{buildroot}%{_bindir}/diffoscope
touch %{buildroot}%{_sysconfdir}/alternatives/diffoscope
%post
%{_sbindir}/update-alternatives --install \
%{_bindir}/diffoscope diffoscope %{_bindir}/diffoscope-%{py3_ver} 10
%postun
if [ "$1" = 0 ] ; then
%{_sbindir}/update-alternatives --remove diffoscope %{_bindir}/diffoscope-%{py3_ver}
fi
%check
# test_identification https://salsa.debian.org/reproducible-builds/diffoscope/-/issues/98
# comparators/test_python/test_diff https://salsa.debian.org/reproducible-builds/diffoscope/-/issues/284#note_280561
py.test-%{python3_bin_suffix} -k 'not ((test_python and test_diff) or test_identification)'
%files
%doc README.rst
%license COPYING
%{_bindir}/diffoscope
%{_bindir}/diffoscope-%{py3_ver}
%{python3_sitelib}/diffoscope
%{python3_sitelib}/diffoscope-%{version}*-info
%ghost %{_sysconfdir}/alternatives/diffoscope
%changelog