Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 905419

Summary: dev-util/kbuild-0.1.9998.3592 fails to compile: kash/nodes..o Error 1
Product: Gentoo Linux Reporter: Pierre Saunders <pierre.saundersps>
Component: Current packagesAssignee: Viorel Munteanu <ceamac>
Status: RESOLVED FIXED    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 526268    
Attachments: build.log
emerge info
environment
kbuild-0.1.9998.3592/out/linux.amd64/release/obj/kash/nodes.c

Description Pierre Saunders 2023-05-01 13:23:49 UTC
Created attachment 861015 [details]
build.log

dev-util/kbuild-0.1.9998.3592 fails to compile on amd64.

The build.log is the same on my desktop (see attachments), my laptop or a virtual box instance. So the issue is most unlikely a hardware one.

Things I've tried :
- Changing the COMMON_FLAGS to '-march=native -O2 -pipe'
- Manually disabling distcc (even though it is disabled in the ebuild)
- Re-emerging the entire deep dependency tree (with emerge --emptytree)
- Switching GCC version to 11, 12 and 13

Final note : the version 0.1.9998.3499-r4 compile perfectly

I hope I gave enough information to move from there,
cheers.
Comment 1 Pierre Saunders 2023-05-01 13:24:11 UTC
Created attachment 861016 [details]
emerge info
Comment 2 Pierre Saunders 2023-05-01 13:24:32 UTC
Created attachment 861017 [details]
environment
Comment 3 Viorel Munteanu gentoo-dev 2023-05-03 07:10:15 UTC
Can you attach /var/tmp/portage/dev-util/kbuild-0.1.9998.3592/work/kbuild-0.1.9998.3592/out/linux.amd64/release/obj/kash/nodes.c ?

It is generated during build.
Comment 4 Pierre Saunders 2023-05-03 08:41:07 UTC
Created attachment 861074 [details]
kbuild-0.1.9998.3592/out/linux.amd64/release/obj/kash/nodes.c
Comment 5 Viorel Munteanu gentoo-dev 2023-05-03 09:00:18 UTC
Yours looks like this:

		TRACE2((psh, "copyfunc: %p - %u refs
", n->pblock, refs)); K_NOREF(refs);

mine like this:

		TRACE2((psh, "copyfunc: %p - %u refs\n", n->pblock, refs)); K_NOREF(refs);

Somehow it replaced \n with an actual EOL.

What is your /bin/sh?
Comment 6 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-05-03 09:05:35 UTC
(In reply to Viorel Munteanu from comment #5)
> What is your /bin/sh?

from emerge --info:
sh dash 0.5.12
Comment 7 Viorel Munteanu gentoo-dev 2023-05-03 09:10:12 UTC
Most probably this is the reason.  I will try to reproduce and fix it.  Meanwhile, you can build it with /bin/sh pointed to bash.
Comment 8 Pierre Saunders 2023-05-03 09:17:44 UTC
I confirm that it builds successfully with /bin/sh pointed to bash.
Comment 9 Larry the Git Cow gentoo-dev 2023-05-03 11:29:35 UTC
The bug has been closed via the following commit(s):

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

commit fa81d030f75f07a12381369ed97c9b6a99540019
Author:     Viorel Munteanu <ceamac@gentoo.org>
AuthorDate: 2023-05-03 11:27:35 +0000
Commit:     Viorel Munteanu <ceamac@gentoo.org>
CommitDate: 2023-05-03 11:28:54 +0000

    dev-util/kbuild: Fix building with /bin/sh -> /bin/dash
    
    Closes: https://bugs.gentoo.org/905419
    Signed-off-by: Viorel Munteanu <ceamac@gentoo.org>

 dev-util/kbuild/kbuild-0.1.9998.3592.ebuild | 3 +++
 1 file changed, 3 insertions(+)