Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 1 Mar 2018 22:12:26 +0100
From: EJ <>
Subject: Re: Generating headers for a specific target

Hi Rich,

> On 1 Mar 2018, at 21:59, Rich Felker <> wrote:
> On Thu, Mar 01, 2018 at 09:49:42PM +0100, EJ wrote:
>> Hello,
>> Is there a way to generate the headers for a specific target without
>> having access to the target or a cross-compiler for the target?
>> I’m not interested in compiling must, just in a complete set of header files.
> Yes, with a few caveats. Keep in mind that for archs with subarchs,
> there will be preprocessor conditionals in the bits headers which
> depend on predefined macros from the compiler, so you can't
> use/process the headers without knowing the values of those macros.

Understood. I’m still planning to run the headers through a properly
configured compiler fornt-end, so that shouldn’t be a problem.

> With that said, something like this should work from a clean tree:
> 	make includedir=/where/you/want/them ARCH=whatever install-headers
> or out-of-tree in a clean dir:
> 	make -f /path/to/musl/Makefile srcdir=/path/to/musl \
> 	includedir=/where/you/want/them ARCH=whatever install-headers
> filling in ARCH=whatever with the musl name for the target arch (not
> including the subarch part).

The above works like a charm.

> The above make invocations are not entirely documented/public
> interfaces, but are probably 90% so and unlikely to change/break in
> practice. It might be a good idea to check that they still work with
> new versions when upgrading musl though.


Thanks for your quick and informative response!

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.