From: Rich Felker <dalias@libc.org>
To: musl@lists.openwall.com
Subject: Re: Bits deduplication: current situation
Date: Mon, 25 Jan 2016 12:17:22 -0500 [thread overview]
Message-ID: <20160125171721.GB238@brightrain.aerifal.cx> (raw)
In-Reply-To: <20160125090803.2db4a262@ncopa-desktop.alpinelinux.org>
On Mon, Jan 25, 2016 at 09:08:03AM +0100, Natanael Copa wrote:
> On Sun, 24 Jan 2016 22:59:25 -0500
> Rich Felker <dalias@libc.org> wrote:
>
> > I'm about to try starting the bits deduplication, but before getting
> > started, I took a quick survey of the current bits headers we have:
>
> ....
>
> > Ideas/requests/preferences/etc.?
>
> It would be nice to be able to build 32-bit boot loaders on 64 bit
> hosts with gcc -m32. Currently that does not work due to it picks up 64
> bit inttypes. We have a patch for xen's hvmloader:
>
> http://git.alpinelinux.org/cgit/aports/tree/main/xen/musl-hvmloader-fix-stdint.patch
> http://git.alpinelinux.org/cgit/aports/tree/main/xen/stdint_local.h
>
> Introduced with this commit:
> http://git.alpinelinux.org/cgit/aports/commit/main/xen/musl-hvmloader-fix-stdint.patch?id=bcf7b52774f1b0a3e405a207c3c4a5342b951f40
>
>
> This is for stdint.h but I think its related and I assume it affects
> limits.h too.
I don't really see a good way to fix this. musl is not designed for
treating "related" 32- and 64-bit archs as if they were a common arch.
It would probably not be hard to make this one usage case work in
practice, but it would be fragile and incomplete.
Is there a reason you can't just pass -nostdinc and then -I the gcc
include dir to use gcc's freestanding headers for a non-native target
like this? IMO the cleanest (albeit somewhat costlier) solution would
be just installing a proper i386 cross compiler.
Alternatively maybe gcc's -m32 could be fixed to use completely
different include paths rather than trying to use the same headers for
different archs. This actually affects third-party installed headers
that are generated for the target arch too, which may be wrongly
picked up if -m32 is used.
Rich
next prev parent reply other threads:[~2016-01-25 17:17 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-25 3:59 Rich Felker
2016-01-25 8:08 ` Natanael Copa
2016-01-25 17:17 ` Rich Felker [this message]
2016-01-25 10:46 ` Laurent Bercot
2016-01-25 14:56 ` Ward Willats
2016-01-25 15:37 ` Szabolcs Nagy
2016-01-25 19:22 ` Dan Gohman
2016-01-25 21:00 ` Rich Felker
2016-01-25 21:32 ` Szabolcs Nagy
2016-01-26 5:03 ` Dan Gohman
2016-01-26 10:18 ` Szabolcs Nagy
2016-01-26 15:16 ` Dan Gohman
2016-01-26 20:26 ` Szabolcs Nagy
2016-01-26 20:17 ` Rich Felker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160125171721.GB238@brightrain.aerifal.cx \
--to=dalias@libc.org \
--cc=musl@lists.openwall.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).