Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 888679 - linux-mod.eclass: recent changes break virtualbox-modules
Summary: linux-mod.eclass: recent changes break virtualbox-modules
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Kernel Bug Wranglers and Kernel Maintainers
URL:
Whiteboard:
Keywords:
: 888681 888863 (view as bug list)
Depends on:
Blocks:
 
Reported: 2022-12-28 05:50 UTC by Paul Thompson
Modified: 2022-12-30 03:48 UTC (History)
5 users (show)

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 Paul Thompson 2022-12-28 05:50:57 UTC
Line 625 :ln -s "${S}"/Module.symvers Module.symvers || die

That '|| die' was added, which causes the merge to die almost instantly, because the code basically touches Modules.symvers and then tries to symlink it to itself.
I do not know what the code is trying to do, but if I revert the change:

...
>>> Compiling source in /var/tmp/portage/app-emulation/virtualbox-modules-7.0.4/work ...
ln: failed to create symbolic link 'Module.symvers': File exists
...

And the build continues and succeeds. Perhaps something is odd in my setup, though some searching the web will show that same symlink failure occurring without killing builds in the past.
Comment 1 Ionen Wolkens gentoo-dev 2022-12-28 10:22:30 UTC
Yeah, haven't looked too deeply but I'll revert this bit in a few.
Comment 2 Ionen Wolkens gentoo-dev 2022-12-28 10:23:04 UTC
*** Bug 888681 has been marked as a duplicate of this bug. ***
Comment 3 Larry the Git Cow gentoo-dev 2022-12-28 10:24:28 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d779705500b4600919b6d5c187afc34870a0d2e5

commit d779705500b4600919b6d5c187afc34870a0d2e5
Author:     Ionen Wolkens <ionen@gentoo.org>
AuthorDate: 2022-12-28 10:14:06 +0000
Commit:     Ionen Wolkens <ionen@gentoo.org>
CommitDate: 2022-12-28 10:23:39 +0000

    linux-mod.eclass: revert adding || die for Modules.symvers
    
    Emergency fix given this apparently broke potentially several
    packages, at least e.g. virtualbox-modules, and zenpower3 from guru.
    
    Fixes: bc0ef44947363a33b5cd9b18bcc0d3c32b808311
    Closes: https://bugs.gentoo.org/888679
    Signed-off-by: Ionen Wolkens <ionen@gentoo.org>

 eclass/linux-mod.eclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Comment 4 Paul Zander 2022-12-28 18:32:37 UTC
The || die call afterwards trying to create the symlink is sane. The actual issue is that srcdir defaults to S. And therefore you want to not create the symlink if srcdir == S.

E.g.

if [[ "${S}" != "${srcdir}" ]]; then
	cd "${srcdir}" || die
	ln -s "${S}"/Module.symvers Module.symvers || die
fi
Comment 5 Mike Gilbert gentoo-dev 2022-12-30 03:48:56 UTC
*** Bug 888863 has been marked as a duplicate of this bug. ***