Accepting request 761571 from home:scarabeus_iv:branches:security:forensics

- Switch to build and distribution under python3 as py2 is obsolete

OBS-URL: https://build.opensuse.org/request/show/761571
OBS-URL: https://build.opensuse.org/package/show/security:forensics/artifacts?expand=0&rev=11
This commit is contained in:
Greg Freemyer 2020-01-07 17:34:51 +00:00 committed by Git OBS Bridge
parent 6929c62907
commit 836550aa92
2 changed files with 13 additions and 6 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue Jan 7 12:16:02 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>
- Switch to build and distribution under python3 as py2 is obsolete
-------------------------------------------------------------------
Thu Oct 17 13:37:02 UTC 2019 - Richard Brown <rbrown@suse.com>

View File

@ -1,7 +1,7 @@
#
# spec file for package artifacts
#
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -27,6 +27,9 @@ Source0: https://github.com/ForensicArtifacts/artifacts/releases/download
Source1: https://github.com/ForensicArtifacts/artifacts/releases/download/%{timestamp}/artifacts-%{timestamp}.tar.gz.asc
# Key 0xD9625E5D7AD0177E by Joachim Metz https://github.com/joachimmetz
Source2: %{name}.keyring
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: python3-setuptools
BuildArch: noarch
%description
@ -44,7 +47,6 @@ from the GRR team.
%package validator
Summary: Digital Forensics Artifact Repository Validator
BuildRequires: python-setuptools
Requires: artifacts
%description validator
@ -57,10 +59,11 @@ themselves and not use these Python modules.
%setup -q -n artifacts-%{timestamp}
%build
python setup.py build
%python3_build
%install
python setup.py install --root=%{buildroot} --prefix=%{_prefix}
%python3_install
%fdupes %{buildroot}%{python3_sitelib}
# these are installed to the wrong dir by %{name}
rm %{buildroot}/usr/share/doc/%{name}/ACKNOWLEDGEMENTS
rm %{buildroot}/usr/share/doc/%{name}/AUTHORS
@ -74,8 +77,7 @@ rm %{buildroot}/usr/share/doc/%{name}/README
%files validator
%license LICENSE
%{python_sitelib}/artifacts-%{timestamp}-py2.7.egg-info
%{python_sitelib}/artifacts
%{python3_sitelib}/artifacts*
%{_bindir}/validator.py
%{_bindir}/stats.py