[cfe-commits] [PATCH] [Driver] Make default GCC install prefix and sysroot relocatable

Rafael EspĂ­ndola rafael.espindola at gmail.com
Tue Dec 11 10:33:40 PST 2012


>> Sorry, not sure I follow. Why doesn't:
>>
>> ../gcc/configure --prefix=/toolchain/install/dir --host=..
>> --target=... --build=...
>> ...
>> ../llvm/configure --prefix=/toolchain/install/dir
>>
>> produce a relocatable build like you want?
>
> This way I've tried, it's work only the gcc toolchain part (and not
> work if configure with --with-gcc-toolchain),
> but the sysroot part is not work.
>
> in our build the configure as follow
>
>  ../llvm/configure --target=arm-none-linux-gnueabi
> --prefix=/home/kito/arm-none-linux-gnueabi
> --with-default-sysroot=/home/kito/arm-none-linux-gnueabi/arm-none-linux-gnueabi/libc/
> --enable-targets=arm
>
> and the prefix folder contain a pre-build toolchain which is download
> from codesourcery.

Have you debugged why it doesn't work? I think this should be finding
the correct tools (assemblers, linkers, etc). Chandler, you guys use a
similar setup, no?

>> what about something like
>> --with-gcc-toolchain='$prefix/../relative/gcc/dir'? $prefix would then
>> be replaced at runtime with where clang is installed. Without $prefix
>> an absolute path is still assumed.
>
> I don't like it but acceptable :|
> Would you have interest merge it with the $prefix version?
> The sysroot relocatable is important for us since we are building a
> cross-compilation toolchain distribution with both gcc and clang.

Sorry, what do you mean by merge? In any case, we should first find
out why the above is not working, as it looks like your setup should
work out of the box.

Cheers,
Rafael



More information about the cfe-commits mailing list