Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 836602 - sys-apps/sysvinit-3.02-r3 fails to compile under musl: bootlogd.c:119:26: error: 'PATH_MAX' undeclared (first use in this function)
Summary: sys-apps/sysvinit-3.02-r3 fails to compile under musl: bootlogd.c:119:26: err...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal
Assignee: William Hubbs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-04-01 14:56 UTC by bug
Modified: 2022-04-13 22:54 UTC (History)
6 users (show)

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


Attachments
emerge -pvq and --info output (emlog,17.60 KB, text/plain)
2022-04-01 14:56 UTC, bug
Details
Build log (file_836602.txt,13.09 KB, text/plain)
2022-04-01 16:04 UTC, bug
Details

Note You need to log in before you can comment on or make changes to this bug.
Description bug 2022-04-01 14:56:58 UTC
Created attachment 768406 [details]
emerge -pvq and --info output

The file bootlogd.c seems to be missing a "#include <limits.h>" which causes the compilation to fail. This only happens on musl.
Comment 1 Mike Gilbert gentoo-dev 2022-04-01 15:29:49 UTC
Please attach a full build log and change the status back to UNCONFIRMED.
Comment 2 bug 2022-04-01 16:04:17 UTC
Created attachment 768409 [details]
Build log
Comment 3 Agostino Sarubbo gentoo-dev 2022-04-12 09:09:04 UTC
I can confirm
Comment 4 Oleksa 2022-04-12 13:36:04 UTC
Hello there!

I am affected also:

Portage 3.0.30 (python 3.9.12-final-0, default/linux/amd64/17.0/musl, gcc-11.2.1, musl-1.2.3, 5.15.32-gentoo-r1 x86_64)
CFLAGS="-O3 -march=native -mtune=ivybridge -pipe -falign-functions=32 -frecord-gcc-switches -fgraphite -fgraphite-identity -floop-nest-optimize -floop-parallelize-all"
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-04-13 01:56:59 UTC
I suppose for now we can use limits.h as that's what'll be used on glibc too,bbut note that other files have a define for PATH_MAX.
Comment 6 Larry the Git Cow gentoo-dev 2022-04-13 01:58:42 UTC
The bug has been closed via the following commit(s):

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

commit d89f6f62cfb518371c77cb10e8fc1e07b85569d9
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2022-04-13 01:58:29 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-04-13 01:58:29 +0000

    sys-apps/sysvinit: fix musl build
    
    Closes: https://bugs.gentoo.org/836602
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-apps/sysvinit/files/sysvinit-3.02-musl-limits.patch | 12 ++++++++++++
 sys-apps/sysvinit/sysvinit-3.02-r3.ebuild               |  2 ++
 2 files changed, 14 insertions(+)
Comment 7 Larry the Git Cow gentoo-dev 2022-04-13 22:54:25 UTC
The bug has been closed via the following commit(s):

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

commit 081e9ddfa7475f308a069c36d770bd2240ea380f
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2022-04-13 22:54:14 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-04-13 22:54:14 +0000

    sys-apps/sysvinit: add 3.03, drop 3.02-r3
    
    Closes: https://bugs.gentoo.org/836602
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-apps/sysvinit/Manifest                                   |  4 ++--
 sys-apps/sysvinit/files/sysvinit-3.02-musl-limits.patch      | 12 ------------
 .../{sysvinit-3.02-r3.ebuild => sysvinit-3.03.ebuild}        |  2 +-
 3 files changed, 3 insertions(+), 15 deletions(-)