Bug 1472201

Summary: %kernel_module_package not actually honor %kmodtool_generate_buildreqs
Product: [Fedora] Fedora Reporter: Robin Lee <robinlee.sysu>
Component: redhat-rpm-configAssignee: Florian Festi <ffesti>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: dzickus, ffesti, jonathan, pmatilai, praiskup, robinlee.sysu
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: redhat-rpm-config-66-1.fc27.src.rpm Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-07-18 12:51:19 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:
Attachments:
Description Flags
Patch proposed to fix this issue. none

Description Robin Lee 2017-07-18 09:09:14 UTC
Created attachment 1300336 [details]
Patch proposed to fix this issue.

Description of problem:
No matter what %kmodtool_generate_buildreqs is defined, BuildRequires will be always generated.

The fix is simple, and the patch is attached.

Version-Release number of selected component (if applicable):
kernel-rpm-macros-63-1.fc26.noarch

How reproducible:
Always

Actual results:
No matter what %kmodtool_generate_buildreqs is defined, BuildRequires will be always generated.

Expected results:
When %kmodtool_generate_buildreqs is not defined or defined to '0', BuildRequires will not be generated.

Comment 1 Florian Festi 2017-07-18 10:31:23 UTC
Hmm, were is nobuildreqs="yes" set with the proposed patch? I have the sneaking suspicion that this patch breaks the normal use case.

Comment 2 Robin Lee 2017-07-18 10:44:57 UTC
kmodtool actually checks for 'no', not for 'yes'. That meas setting %nobuildreqs to 'yes' or anything other than 'no' has the same effect.

Comment 3 Florian Festi 2017-07-18 12:51:19 UTC
Added a nobuildreqs="yes" line just for good measures.