mailing list of musl libc
 help / color / mirror / code / Atom feed
* [musl] getpwuid() calls getline() which may be redefined
@ 2023-04-17 16:50 Robert Clausecker
  2023-04-17 19:39 ` Rich Felker
  0 siblings, 1 reply; 2+ messages in thread
From: Robert Clausecker @ 2023-04-17 16:50 UTC (permalink / raw)
  To: musl

Greetings,

I'm the maintainer of schilytools [1], a suite of tools including
cdrecord, mkisofs, star, smake, and others.  To produce Linux
binary releases for our users, I investigated building static
binaries with musl and found that the star command experienced
problems [3]: when built with

    smake LINKMODE=static LDOPTX=-static INS_RBASE=/opt/schily SHLIB_BUILD=\#

the program hangs reading from stdin.  With the help of psykose
from your IRC channel, we found that this is due to getpwuid()
calling getline(), a symbol which this program uses for a custom
function with a POSIX-incompatible signature.  This use of the
getline() symbol dates back to UNOS [2], an early UNIX close.

We'll try to work around this issue, likely by renaming our
getline() to something else.  I have filed this bug report with
you so you may decide if you wish to route the getline() call
through an internal symbol alias, proofing your library against
incompatible external redefinitions.

Yours,
Robert Clausecker

[1]: https://codeberg.org/schilytools/schilytools
[2]: https://en.wikipedia.org/wiki/UNOS_(operating_system)
[3]: https://codeberg.org/schilytools/schilytools/issues/31

-- 
()  ascii ribbon campaign - for an 8-bit clean world 
/\  - against html email  - against proprietary attachments

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-04-17 19:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-17 16:50 [musl] getpwuid() calls getline() which may be redefined Robert Clausecker
2023-04-17 19:39 ` Rich Felker

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).