Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 56587 - development-sources-2.6.7 (maybe kernel-2.eclass) doesn't link /usr/src/linux
Summary: development-sources-2.6.7 (maybe kernel-2.eclass) doesn't link /usr/src/linux
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: x86-kernel@gentoo.org (DEPRECATED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-07-09 20:57 UTC by Stephen Ulmer
Modified: 2004-07-27 01:15 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stephen Ulmer 2004-07-09 20:57:26 UTC
I'm building a stage3 with catalyst using a custom profile. I've got
virtual/linux-sources defined as sys-kernel/development-sources, so it merges development-sources-2.6.7 (successfully).  The next package is device-mapper-1.00.08, which dies because there is no /usr/src/linux symlink in the stage3 chroot.

The test done by the device mapper ebuild seems reasonable. The development sources ebuild uses the kernel-2 eclass, which looks like it's supposed to create the link in the postinst_sources() function. I don't know why it's not getting called (or working if it is).

Reproducible: Always
Steps to Reproduce:



Expected Results:  
Either the development sources ebuild should link /usr/src/linux, or there
should be a way for me to have catalyst to inject the correct symlink (less
desireable).
Right now I'm creating a dangling symlink in the stage2 work area and re-making
the stage2 tar-ball myself.
Comment 1 Stephen Ulmer 2004-07-10 06:25:47 UTC
There is an analagous problem building a livecd-stage2. genkernel won't run because the /usr/src/linux symlink isn't there.  It *is* present in the livecd-stage1 area (because I had added it to the stage2 tarball) but disappears. If I add it by hand at just the right time, I can get the catalyst build to continue.
Comment 2 Michal Januszewski (RETIRED) gentoo-dev 2004-07-11 12:25:05 UTC
postinst_sources() most probably gets called (check if you can see the 'After installing a new kernel of any version, it is important..' message after the ebuild is installed - if you do, the function gets called). The thing is, the symlink will be created:
a) in ${ROOT} - do you have your ROOT env variable set when you're using the ebuild?
b) only if it doesn't already exist.
Comment 3 Eli Ben-Shoshan 2004-07-25 11:43:32 UTC
postinst_sources() is never called since pkg_postinst is defined in the ebuild. You need to call postinst_sources() explicitly in the ebuild. I added the call at the beginning on pkg_postint and it all looks good now.
Comment 4 Eli Ben-Shoshan 2004-07-25 11:45:29 UTC
Actually I believe the function that should be called, according the eclass HOWTO, should be kernel-2_pkg_postinst().
Comment 5 Michal Januszewski (RETIRED) gentoo-dev 2004-07-27 01:15:17 UTC
You're right. I've just fixed it in CVS. Thanks!