Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241026021141.GZ10433@brightrain.aerifal.cx>
Date: Fri, 25 Oct 2024 22:11:41 -0400
From: Rich Felker <dalias@...c.org>
To: Thorsten Glaser <tg@...bsd.de>
Cc: musl@...ts.openwall.com, Alyssa Ross <hi@...ssa.is>
Subject: Re: Prototypes without implementations

On Sat, Oct 26, 2024 at 03:57:15AM +0200, Thorsten Glaser wrote:
> On Sat, 26 Oct 2024, Laurent Bercot wrote:
> 
> > I'd rather have libcs omit stub implementations entirely, so that
> > applications can test for functionality without having to run anything.
> > Stub implementations make tests and integration of replacement
> 
> Fully agreed. It’s easy to make a compile+link test; my autoconf
> replacement depends on it (and does that right) but runtime is a
> whole other issue.
> 
> I don’t even mind about headers declaring functions that aren’t
> there because only a fool tool would look at headers only… though
> omitting them when it’s easy to know (e.g. via cpp predefs) it’s
> not there is of course better.

My leaning would be not to do the ENOSYS thing, not only for this
reason, but because doing so might preclude having them with a
different signature on a different arch, if that were later needed.
I'm not sure how realistic that happening is, but if it's plausible,
it might be a good argument for moving the prototypes back to the
x86-specific bits headers like I think Alyssa was proposing. OTOH it
looks like some other archs already have these syscalls, and that was
the motivation for the original change.. so more investigation is
probably needed.

Rich

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.