Bug 1447747

Summary: Make libselinux-python3 a weak dependency for setools(-console)
Product: [Fedora] Fedora Reporter: dac.override
Component: setoolsAssignee: Petr Lautrbach <plautrba>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: cpebenito, dwalsh, mgrepl, plautrba, pmoore, vmojzis
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: setools-4.1.0-3.fc26 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-06-09 19:05:11 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description dac.override 2017-05-03 16:38:39 UTC
Description of problem:

setools-console has no dependency on libselinux-python3

libselinux-python3 is not strictly needed, but it is needed to analyse currently loaded policy.

Therefore it should be considered to make libselinux-python3 a soft dependency for setools(-console)

Version-Release number of selected component (if applicable):
fedora 26

Comment 1 Petr Lautrbach 2017-05-19 21:24:21 UTC
It makes sense. Thanks!

Given that selinux python module seems to be imported from setools-python3 package I would add a weak dependency there:

diff --git a/setools.spec b/setools.spec
index 8f4ce26..6671e03 100644
--- a/setools.spec
+++ b/setools.spec
@@ -77,6 +77,7 @@ This package includes the following console tools:
 
 %package     python
 Summary:     Policy analysis tools for SELinux  
+Recommends:  libselinux-python
 
 %description python
 SETools is a collection of graphical tools, command-line tools, and
@@ -85,6 +86,7 @@ Python 2 modules designed to facilitate SELinux policy analysis.
 %package     python3
 Summary:     Policy analysis tools for SELinux  
 Obsoletes:   setools-libs < 4.0.0, setools-libs-tcl
+Recommends:  libselinux-python3
 
 %description python3
 SETools is a collection of graphical tools, command-line tools, and



Please try the following scratch build if it works as expected - https://koji.fedoraproject.org/koji/taskinfo?taskID=19630142

Comment 2 dac.override 2017-05-20 06:25:07 UTC
Not sure what I supposed to be testing here but I can confirm that the scratch built now considers libselinux-python3 a weak dependency. So from my (python3) perspective everything looks good. Thanks

Comment 3 Fedora Update System 2017-05-22 07:32:55 UTC
setools-4.1.0-3.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-441bfbabc5

Comment 4 Fedora Update System 2017-05-22 16:39:10 UTC
setools-4.1.0-3.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-441bfbabc5

Comment 5 Fedora Update System 2017-06-09 19:05:11 UTC
setools-4.1.0-3.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.