Bug 728012 - %kernel_module_package macro doesn't work flavor option
Summary: %kernel_module_package macro doesn't work flavor option
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: driver-update-program
Version: 6.0
Hardware: x86_64
OS: Linux
Target Milestone: rc
: ---
Assignee: Jon Masters
QA Contact: Cui Chun
Depends On:
Blocks: 725987
TreeView+ depends on / blocked
Reported: 2011-08-03 22:50 UTC by joyce.yu
Modified: 2012-03-05 03:22 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2012-03-05 03:22:49 UTC
Target Upstream Version:

Attachments (Terms of Use)

Description joyce.yu 2011-08-03 22:50:46 UTC
Description of problem:

kmodtool doesn't embed version/release number specified by
"%kernel_module_package flavor macros in KMP packages. 

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

How reproducible:

Steps to Reproduce:
1.create kmp.spec

Name:    kmp
Summary: Dummy summary
Version: 1.0
Release: 0
License: GPL
Group:   System Environment/Kernel

BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: %kernel_module_package_buildreqs

Test bug 252188
Example ussage from http://driverupdateprogram.com

%kernel_module_package 2.6.32-71.el6.x86_64

* Tue Oct  9 2007 Foo Bar
- Updated original examples

2.Run "rpmbuild --target=x86_64 -bb kmp.spec"

error: Failed build dependencies:
        kernel-2.6.32-71.el6.x86_64-devel is needed by sxgevf-1.0-0.x86_64

Actual results:

Not able to build other flavor of the kernel

Expected results:
Nothing was created

Additional info:

Comment 4 Jon Masters 2012-03-05 03:22:49 UTC
I realize that this bug is likely the result of a badly worded example on my part in the documentation. The intention of the "flavor" is to specify other kernel variants, such as "xen", "kdump", "pae", etc. In the case of RHEL6, there really aren't many variants left and so use of this is very rare indeed.

Given this, I apologize for not realizing sooner that your request wasn't actually for a feature change in the macro, but merely a simple clarification. In general, if you want to specify a specific kernel version, all you need to do is set %kernel_version to whatever the version number you want to build against, which will override the default. Generally, the latest kernel is preferred, or a build is done using mock, but in case that you need to choose a specific kernel, please set "%kernel_version 2.6.32-release_goes_here".

We will get the documentation updated. Again, many apologies for not realizing the true nature of this request much sooner. If I can be of any assistance, please do not hesitate to email me directly at jcm@redhat.com in general.

Note You need to log in before you can comment on or make changes to this bug.