Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 909447 - sys-kernel/gentoo-sources: ebuild ${path to ebuild} install is unable to resume with ebuild ${path to ebuild} merge
Summary: sys-kernel/gentoo-sources: ebuild ${path to ebuild} install is unable to resu...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Kernel Bug Wranglers and Kernel Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-07-01 15:45 UTC by tt_1
Modified: 2023-07-05 01:41 UTC (History)
3 users (show)

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


Attachments
full build log (build.log,17.15 KB, text/x-log)
2023-07-01 15:45 UTC, tt_1
Details
output from emerge --info (emerge-info,8.29 KB, text/plain)
2023-07-01 15:46 UTC, tt_1
Details
Preserve S during install (0001-Preserve-S-during-install.patch,736 bytes, patch)
2023-07-02 19:13 UTC, Mike Pagano
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description tt_1 2023-07-01 15:45:44 UTC
Created attachment 864976 [details]
full build log

so, I noticed this bug a while ago when checking out kernel live ebuilds of sys-kernel/raspberrypi-sources, where I thought of installing them via ebuild install and later merge them, if there were changes in the upstream src

I refrained to fill a bug, since going the normal route with: "emerge gentoo-sources -av" is working as expected, same for raspberrypi-sources, yet I was encouraged in irc to fill a bug for it. 

Here is the error, please also note the size of install dir: 

>>> Install sys-kernel/gentoo-sources-5.15.119 into /var/tmp/portage/sys-kernel/gentoo-sources-5.15.119/image
 * >>> Copying sources ...
>>> Completed installing sys-kernel/gentoo-sources-5.15.119 into /var/tmp/portage/sys-kernel/gentoo-sources-5.15.119/image

 * Final size of build directory:       0 KiB
 * Final size of installed tree:  1226100 KiB (1.1 GiB)

 * ERROR: sys-kernel/gentoo-sources-5.15.119::gentoo failed (test phase):
 *   The source directory '/var/tmp/portage/sys-kernel/gentoo-sources-5.15.119/work/linux-5.15.119-gentoo' doesn't exist
 * 
 * Call stack:

full build log is attached
Comment 1 tt_1 2023-07-01 15:46:22 UTC
Created attachment 864977 [details]
output from emerge --info
Comment 2 tt_1 2023-07-01 15:48:43 UTC
reproducer: 

ebuild /usr/portage/sys-kernel/gentoo-sources/gentoo-sources-5.15.119.ebuild install

ebuild /usr/portage/sys-kernel/gentoo-sources/gentoo-sources-5.15.119.ebuild merge
Comment 3 Ionen Wolkens gentoo-dev 2023-07-01 15:57:41 UTC
>failed (test phase)
Haven't tried myself but sounds more of an issue with ebuild(1) than gentoo-sources.

What's test phase doing there? Tests aren't even enabled, and tests shouldn't be run post-install.
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-07-01 16:00:31 UTC
We looked at it briefly in #gentoo yesterday and looks like eclass destroys S in src_install then I guess on the re-run src_test in portage checks if S exists before even checking if it should run
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-07-01 16:05:03 UTC
(Unclear to me off top of my head if destroying S is legal in itself too)
Comment 6 Mike Pagano gentoo-dev 2023-07-02 19:13:41 UTC
Created attachment 865045 [details, diff]
Preserve S during install

Maybe something like this ?
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-07-02 19:35:17 UTC
(In reply to Mike Pagano from comment #6)
> Created attachment 865045 [details, diff] [details, diff]
> Preserve S during install
> 
> Maybe something like this ?

lgtm, iirc this is faster than doins (I don't remember why doins is so slow for this but I know I've seen complaints over it in the past).

I'll need to check if Portage itself needs fixing here as well but that looks fine to me and like a good idea anyway
Comment 8 Larry the Git Cow gentoo-dev 2023-07-04 17:15:40 UTC
The bug has been closed via the following commit(s):

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

commit ec67e505c7629cea6dcaa0330089fcdb7d2137f9
Author:     Mike Pagano <mpagano@gentoo.org>
AuthorDate: 2023-07-04 17:14:30 +0000
Commit:     Mike Pagano <mpagano@gentoo.org>
CommitDate: 2023-07-04 17:14:30 +0000

    kernel-2.eclass: Preserve S during install
    
    Closes: https://bugs.gentoo.org/909447
    
    Signed-off-by: Mike Pagano <mpagano@gentoo.org>

 eclass/kernel-2.eclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)