From 4e6ed39d61947e9ee17ba624bb0606ee8885ff44 Mon Sep 17 00:00:00 2001 From: Erich Cordoba Date: Tue, 1 Oct 2019 11:36:59 -0500 Subject: [PATCH] Adding %fdupes macro to python-fmclient and fm-rest-api in opensuse The rpmlint tool complains about having duplicated files in these two packages. The %fdupes macro helps to remove these duplicated files and thus pass rpmlint checks. Story: 2006508 Task: 36867 Change-Id: I031352e06c74da65dc62b9a6c51dbb87371432d1 Signed-off-by: Erich Cordoba --- fm-rest-api/opensuse/fm-rest-api.spec | 3 +++ python-fmclient/opensuse/python-fmclient.spec | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/fm-rest-api/opensuse/fm-rest-api.spec b/fm-rest-api/opensuse/fm-rest-api.spec index 5fd8a182..5f56445f 100644 --- a/fm-rest-api/opensuse/fm-rest-api.spec +++ b/fm-rest-api/opensuse/fm-rest-api.spec @@ -7,6 +7,7 @@ Group: Development/Tools/Other URL: https://opendev.org/starlingx/fault Source0: %{name}-%{version}.tar.gz BuildRequires: insserv-compat +BuildRequires: fdupes BuildRequires: python-oslo.db BuildRequires: python-oslo.messaging BuildRequires: python-oslo.middleware @@ -69,6 +70,8 @@ install -m 640 fm/db/sqlalchemy/migrate_repo/migrate.cfg %{buildroot}%{pythonroo oslo-config-generator --config-file fm/config-generator.conf --output-file %{_builddir}/fm.conf.sample install -p -D -m 644 %{_builddir}/fm.conf.sample %{buildroot}%{_sysconfdir}/fm/fm.conf +%fdupes %{buildroot}%{pythonroot}/fm + %files %defattr(-,root,root,-) %license LICENSE diff --git a/python-fmclient/opensuse/python-fmclient.spec b/python-fmclient/opensuse/python-fmclient.spec index 1d654c7a..e9cdb903 100644 --- a/python-fmclient/opensuse/python-fmclient.spec +++ b/python-fmclient/opensuse/python-fmclient.spec @@ -13,6 +13,7 @@ License: Apache-2.0 Group: Development/Tools/Other URL: https://opendev.org/starlingx/fault Source0: %{name}-%{version}.tar.gz +BuildRequires: fdupes BuildRequires: git BuildRequires: python-setuptools BuildRequires: python2-pbr @@ -53,6 +54,10 @@ python setup.py install --root=%{buildroot} \ install -d -m 755 %{buildroot}%{local_etc_bash_completiond} install -p -D -m 664 tools/fm.bash_completion %{buildroot}%{local_etc_bash_completiond}/fm.bash_completion +%fdupes %{buildroot}%{pythonroot}/fmclient +%fdupes %{buildroot}%{pythonroot}/%{pypi_name}-%{version}*.egg-info + + %files %license LICENSE %{_bindir}/*