Bug 196712 - O=/objdir builds fail for out-of-tree builds with 2.6.9-39.4
Summary: O=/objdir builds fail for out-of-tree builds with 2.6.9-39.4
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: kernel
Version: 4.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
: ---
Assignee: Doug Ledford
QA Contact: Brian Brock
URL:
Whiteboard:
Depends On:
Blocks: 181411
TreeView+ depends on / blocked
 
Reported: 2006-06-26 17:07 UTC by Kimball Murray
Modified: 2007-11-30 22:07 UTC (History)
2 users (show)

Fixed In Version: RHSA-2006-0575
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-08-10 23:37:12 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Fix patch for Makefile problem (489 bytes, patch)
2006-07-05 18:17 UTC, Doug Ledford
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2006:0575 0 normal SHIPPED_LIVE Important: Updated kernel packages available for Red Hat Enterprise Linux 4 Update 4 2006-08-10 04:00:00 UTC

Description Kimball Murray 2006-06-26 17:07:37 UTC
Description of problem:
Appears the latest changes to the infinband drivers introduce a build problem
for those who like to build kernel objects outside of the source directory
(using make O=/objdir).

Version-Release number of selected component (if applicable):
RHEL4, kernel 2.6.9-39.4

How reproducible:
100%

Steps to Reproduce:
1. Install kernel SRPM (rpm -i kernel-2.6.9-39.4.EL.src.rpm)
2. cd /usr/src/redhat/SPECS
3. rpmbuild --target=i686 -bp kernel-2.6.spec (or as appropriate)
4. mkdir /objdir
5. cd /usr/src/redhat/BUILD/kernel-2.6.9/linux-2.6.9
6. cp configs/kernel-2.6.9-i686-smp.config (or as appropriate) /objdir/.config
7. make O=/objdir oldconfig
8. make O=/objdir

The build will then commence, but will fail with this message:

/usr/src/redhat.old/BUILD/linux-2.6.9-39.4EL/drivers/infiniband/core/index.c:36:25:
> linux/index.h: No such file or directory
  
Actual results:
Build failure

Expected results:
Build success

Additional info:
If the build is done in-tree (without the O= build flag), the build will
succeed.  This behaves much like the build problem introduced with the lpfc
driver import a short while ago.

Comment 4 Doug Ledford 2006-07-05 18:17:44 UTC
Created attachment 131952 [details]
Fix patch for Makefile problem

This patch should solve the problem.  When building with a separate module
directory tree, the current directory (and therefore relative paths) are in the
object directory tree, not the source tree.  In order to make standard includes
work in that case, the KBUILD_SRC define is set and the srctree variable points
to the toplevel src directory.	We add an include that specifies
$(srctree)/<normal include path> into the include list and then our includes
are found like normal.

Comment 7 Jason Baron 2006-07-07 18:01:39 UTC
committed in stream U4 build 40.1. A test kernel with this patch is available
from http://people.redhat.com/~jbaron/rhel4/


Comment 8 Mike Gahagan 2006-07-14 15:38:56 UTC
Verified based on existing rhts results. s390x fails but that failure is due to
BZ 197743.

Comment 10 Red Hat Bugzilla 2006-08-10 23:37:16 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2006-0575.html



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