>> Is it possible that real target is so called x32, i.e. x86_64 with >> 32-bit address space limitation? In such case linux-x32 would be the >> right target... > > I don't believe this is x32 since {x86_64|amd64} and __ILP32__ are not > defined; see preprocessor output below.
Got it. But just in case x32 was fixed anyway :-) > The compiler reports its i686: > > # gcc -dumpmachine > i686-pc-linux-gnu > > The machine appears to be i686: > > # readelf -h /bin/ls | grep -i 'class\|machine' > Class: ELF32 > Machine: Intel 80386 > > The machine reports that its x86_64 through uname, though: > > # uname -m > x86_64 > > Maybe uname cannot be trusted for Gentoo? Well, x86_64 is a string kernel returns to a user-land program, right? And the thing is that it doesn't care if the program is 32- or 64-bit one (unless you've changed "personality" for the said program). So that above simply means that you have ended up with so to say 32-bit /, i.e. with 32-bit /bin/ls, 32-bit compiler, the whole thing, but booted 64-bit kernel. There is no reason why it wouldn't work. I mean such mix of kernel and user-land. It's not common, but it works. Question is if it's really the way all Gentoos get installed. On certain level it makes sense to have all the system programs to be 32-bit, because they are not performance-critical, so you can afford to trade a bit worse performance to minimize memory and disk space consumption (latter can be surely appropriate for a LiveCD). But they ought to provide compiler capable of generating 64-bit code. So that user can compiler performance-critical applications. Yes, 32-bit compiler can actually be configured to generate code of either bitness, but it's not common nowadays. Very much like 64-bit compiler can be configured to generate code of either bitness, which is commonplace. The fact that it managed to compile first assembly module simply means that assembler was configured to assemble code of either bitness. As they are configured separately, binutils and compiler, it's not impossible combination. > # cat /etc/gentoo-release > Gentoo Base System release 2.2 Once again, is it really average Gentoo installation? If it's not, then I'd say that it's not OpenSSL problem. If you still have to compile for this installation, then just invoke './Configure linux-elf ...' manually. On side note, this is also the way to test 32-bit builds on 64-bit OS, though it normally takes extra option, './Configure linux-elf -m32 ...' -- openssl-dev mailing list To unsubscribe: https://mta.openssl.org/mailman/listinfo/openssl-dev