You'll need to find files in the file system which preserve the triplet passed to / probed by configure
on the build time of your target userland.
In common GNU/Linux distributions the best bet would be querying to common command binaries like bash
curl
make
svn
. In the following example on Debian/armhf (QEMU image taken from here) I got the canonical triplet arm-unknown-linux-gnueabihf
by bash --version
. So it would be basically safe to configure my cross toolchain for this system by /path/to/configure --target=arm-unknown-linux-gnueabihf
.
root@debian-armhf:~# bash --version
GNU bash, version 4.2.37(1)-release (arm-unknown-linux-gnueabihf)
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
There's no reliable way to know non-canonical triplet like arm-linux-gnueabihf
x86_64-linux-gnu
from the userland, and there might be distribution specific conventions like Debian multiarch and tuples. You'll need to collect info from your distribution's document or other resources online.
uname -a
get you here?Linux MyDeviceName 2.6.35.3-571-gcca29a0-g8b63513-dirty #162 PREEMPT Tue Aug 4 10:57:29 CEST 2015 armv5tejl GNU/Linux
Freescale MX28EVK
?armv5tejl
core,GNU/Linux
as OS, and if you really need the vendor, too, trylshw -class cpu
and ignore the "should be run as super-user" part.