Bug 1141218

Summary: pulp.spec:547: W: libdir-macro-in-noarch-package agent %{_libdir}/gofer/plugins/pulpplugin.*
Product: [Retired] Pulp Reporter: Randy Barlow <rbarlow>
Component: consumersAssignee: pulp-bugs
Status: CLOSED UPSTREAM QA Contact: pulp-qe-list
Severity: medium Docs Contact:
Priority: medium    
Version: MasterCC: cduryee, jortel
Target Milestone: ---Keywords: Task, Triaged
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-28 22:19:21 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 Randy Barlow 2014-09-12 13:09:45 UTC
Description of problem:
rpmlint -i pulp.spec gives the following warning:

pulp.spec:547: W: libdir-macro-in-noarch-package agent %{_libdir}/gofer/plugins/pulpplugin.*
The %{_libdir} or %{_lib} macro was found in a noarch package in a section
that gets included in binary packages.  This is most likely an error because
these macros are expanded on the build host and their values vary between
architectures, probably resulting in a package that does not work properly on
all architectures at runtime. Investigate whether the package is really
architecture independent or if some other dir/macro should be instead.

gofer should use Python's entry point system to locate plugins rather than putting Python code in /usr/lib/.

Version-Release number of selected component (if applicable):
2.4.0-1

How reproducible:
Every time

Steps to Reproduce:
1. Run rpmlint -i pulp.spec

Actual results:
The above warning is printed.

Expected results:
No warnings should be printed.

Comment 1 Jeff Ortel 2014-09-17 20:33:38 UTC
Gofer supports loading plugins from /usr/share/gofer/plugins as well as /usr/lib/gofer/plugins and /usr/lib64/gofer/plugins.

Gofer 1.0+ supports loading plugins from the python path.  This can be done by simply adding a property to the plugin descriptor:

[main]
plugin: pulp.agent.gofer.pulpplugin

--- 

Any of the above solutions will resolve this bug.

Comment 2 Brian Bouterse 2015-02-28 22:19:21 UTC
Moved to https://pulp.plan.io/issues/520