[LLVMdev] The Trouble with Triples

Renato Golin renato.golin at linaro.org
Thu Jul 9 02:45:08 PDT 2015


On 9 July 2015 at 10:39, David Chisnall <David.Chisnall at cl.cam.ac.uk> wrote:
> The use-case that I’d really like to go from mostly-working to actually-working is the ability to create symlinked versions of clang with a triple prefix and have it behave sensibly.  We can symlink clang to mips64-unknown-freebsd-clang and get a working cross-compiler, more or less, except that we also want to specify things like the default sysroot.  Having the bit in the name of the compiler just be a name for a config file containing a set of command-line options would be very nice - we’d have a set of predefined names, and then if someone wanted to provide a androidsdk-v47-arm.conf (or whatever) and just drop it into a known location then they’d be able to use androidsdk-v47-arm-clang as a cross compiler.

This already works well with Clang, but is restricted to the triples
that actually make sense. If you need to change anything that the
triple can't, you're on your own.

But I agree this is a sensible alternative, or even in conjunction,
with CMake options or config files.

cheers,
--renato




More information about the llvm-dev mailing list