config-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DO NOT use file format of /bin/sh for x32 detection!


From: Thorsten Glaser
Subject: Re: DO NOT use file format of /bin/sh for x32 detection!
Date: Sun, 4 Mar 2018 04:13:40 +0100 (CET)
User-agent: Alpine 2.21 (DEB 202 2017-01-01)

On Thu, 1 Mar 2018, James Clarke wrote:

> x32, so it's not a *pure* system, but build=host=target=x32.

Well, “pure” x32 systems don’t exist, as it’s a userland-only
architecture, the kernel is simply amd64 for example. Same for
arm64ilp32 and arm64/aarch64 and perhaps(?) MIPS n32/n64.

Worse, x32 users are expected to run mixed (Multi-Arch)
systems, usually with amd64, though mine uses i386 for
those binaries not working with x32 yet.

But this is not even the case here: the x32 binary of any
utility built with klibc is indistinguishable from the
amd64 binary of the same utility built with klibc because
klibc treats x32 as amd64.


For --build= I agree checking the compiler isn’t usually
necessary, and the build system should be similar enough
to amd64, so checking a binary is a somewhat(!) sensible
approach. I’d suggest checking the uname binary, since
it’s unlikely to be built into the shell and called from
config.guess anyway, or perhaps $CC, although that could
have arguments so only its first word.

A slight issue could arise from programs that do use
HOST_CC/CC_FOR_BUILD to create code targetting the build
environment, e.g. for generation of source code. However,
these are unlikely to need foo64ilp32-specific treatment,
and assembly code users are requested to change their code
to check defined(__ILP32__) already anyway, so the result
of config.guess would rarely be used.

I’d still prefer checking CC_FOR_BUILD for correctness,
personally, though. But then, I’m a BSD person…


For --host= checking the compiler is an absolute must,
though. --target= must be manually passed, so that’s
indeed not needing consideration.

bye,
//mirabilos
-- 
tarent solutions GmbH
Rochusstraße 2-4, D-53123 Bonn • http://www.tarent.de/
Tel: +49 228 54881-393 • Fax: +49 228 54881-235
HRB 5168 (AG Bonn) • USt-ID (VAT): DE122264941
Geschäftsführer: Dr. Stefan Barth, Kai Ebenrett, Boris Esser, Alexander Steeg

*************************************************

**Besuchen Sie uns auf der EuroCIS!**
27. Februar bis 01. März 2018, Messe Düsseldorf / **Halle 10,** ** Stand
F15**
Leading Trade Fair for Retail Technology
[www.tarent.de/eurocis](http://www.tarent.de/eurocis)

Wir empfehlen unsere Vorträge

?Preisbeobachtung, Händlermonitoring, Plagiaterkennung: Ihre
Wettbewerbsvorteile?
am 27. Februar, 14:00 Uhr im EuroCIS Forum / Halle 10, Stand F04

?Internet of Things ? Der Handel im Wandel?
am 01. März, 11:30 Uhr im Omnichannel Forum / Halle 10, Stand A70

*************************************************

**Visit us at EuroCIS!** 27th February to 1st March, 2018, Messe
Düsseldorf
/ **Hall 10,** ** Booth F15**
Leading Trade Fair for Retail Technology
[www.tarent.de/eurocis](http://www.tarent.de/eurocis)

We recommend our presentations

?Your view on prices, retailers and plagiarism: Competitive advantages
with
monitoring apps?
on 27th February, 2 pm at EuroCIS Forum / Hall 10, Booth F04

?Internet of Things ? Retailing in a Changing World?
on 1st March, 11:30 am at Omnichannel Forum / Hall 10, Booth A70

*************************************************



reply via email to

[Prev in Thread] Current Thread [Next in Thread]