Created attachment 517282 [details] emerge --info Building mksh fails with "error: conflicting types for 'getrusage'" Same compile time error on more recent versions.
Created attachment 517284 [details] emerge --info mksh
Created attachment 517288 [details] emerge -pqv mksh
Created attachment 517290 [details] build log
Created attachment 517292 [details] environment
PS: With USE='-static' it (obviously) works.
does 56c release work?
(In reply to Pacho Ramos from comment #6) > does 56c release work? Same with 52. USE='-static' works, USE='static' fails.
(In reply to Alexander Hof from comment #7) > (In reply to Pacho Ramos from comment #6) > > does 56c release work? > > Same with 52. USE='-static' works, USE='static' fails. Still present in 57.
(In reply to Alexander Hof from comment #8) > (In reply to Alexander Hof from comment #7) > > (In reply to Pacho Ramos from comment #6) > > > does 56c release work? > > > > Same with 52. USE='-static' works, USE='static' fails. > > Still present in 57. Also in 57-r1.
Can you try with adding -DMKSH_NO_LIMITS to the CFLAGS? With this being added it then works for me. If it works for you too I'll fix the ebuild, otherwise I'll drop the dependency on klibc and use the system libc when possible (ie. musl).
(In reply to Haelwenn Monnier from comment #10) > Can you try with adding -DMKSH_NO_LIMITS to the CFLAGS? With this being > added it then works for me. If it works for you too I'll fix the ebuild, > otherwise I'll drop the dependency on klibc and use the system libc when > possible (ie. musl). It compiles with -DMKSH_NO_LIMITS, but then you lose mksh's ulimit abilities...
(In reply to Alexander Hof from comment #11) > (In reply to Haelwenn Monnier from comment #10) > > Can you try with adding -DMKSH_NO_LIMITS to the CFLAGS? With this being > > added it then works for me. If it works for you too I'll fix the ebuild, > > otherwise I'll drop the dependency on klibc and use the system libc when > > possible (ie. musl). > > It compiles with -DMKSH_NO_LIMITS, but then you lose mksh's ulimit > abilities... Well, I guess this is a limit of klibc, but AFAIK using klibc is the only way to get USE=static to properly work with ELIBC=glibc / TARGET=*-gnu* because glibc is broken.
Note: app-shells/mksh-57-r2 removes dependency on klibc so USE=static is masked by default and unmasked in uClibc and musl (so basically use-masking on glibc/TARGET=*-gnu*). Tagging it as resolved-obsolete because it's not applicable to the current ~* version.