Clang LLVM for PPC. Clang unable to find PowerPC gcc toochain and binutils

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Clang LLVM for PPC. Clang unable to find PowerPC gcc toochain and binutils

Hans Wennborg via cfe-dev
Hi all

I am building Clang/LLVM for PowerPC processor. The cmake command i'm using is:

cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr/llvm6 -DCMAKE_CROSSCOMPILING=True -DLLVM_DEFAULT_TARGET_TRIPLE=powerpc-linux-gnu -DLLVM_TARGET_ARCH=PowerPC -DLLVM_TARGETS_TO_BUILD=PowerPC ../llvm-6.0.0.src

PowerPC gcc toolchain along with binutils are installed in /usr/powerpc-eabi directory.

My questions are:
1. How to tell LLVM about gcc toolchain and binutils installation directory? Do we have to change/modify/add the path of gcc toolchain in llvm-6.0.0.src/tools/clang/lib/Driver directory files?
2. LLVM is successfully built using above cmake. I'm not able to use --sysroot=/usr/powerpc-eabi. In fact it is ineffective.

Please help.

Rgs,
VSP

_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: Clang LLVM for PPC. Clang unable to find PowerPC gcc toochain and binutils

Hans Wennborg via cfe-dev
It would appear that the location of your build compiler is non-standard. I believe you should try with -DGCC_INSTALL_PREFIX=/usr/powerpc-eabi

Nemanja

On Mon, Jan 27, 2020 at 4:39 AM vsp 1729 via cfe-dev <[hidden email]> wrote:
Hi all

I am building Clang/LLVM for PowerPC processor. The cmake command i'm using is:

cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr/llvm6 -DCMAKE_CROSSCOMPILING=True -DLLVM_DEFAULT_TARGET_TRIPLE=powerpc-linux-gnu -DLLVM_TARGET_ARCH=PowerPC -DLLVM_TARGETS_TO_BUILD=PowerPC ../llvm-6.0.0.src

PowerPC gcc toolchain along with binutils are installed in /usr/powerpc-eabi directory.

My questions are:
1. How to tell LLVM about gcc toolchain and binutils installation directory? Do we have to change/modify/add the path of gcc toolchain in llvm-6.0.0.src/tools/clang/lib/Driver directory files?
2. LLVM is successfully built using above cmake. I'm not able to use --sysroot=/usr/powerpc-eabi. In fact it is ineffective.

Please help.

Rgs,
VSP
_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev

_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: Clang LLVM for PPC. Clang unable to find PowerPC gcc toochain and binutils

Hans Wennborg via cfe-dev
In reply to this post by Hans Wennborg via cfe-dev
On Mon, Jan 27, 2020 at 4:39 AM vsp 1729 via cfe-dev <[hidden email]> wrote:
Hi all

I am building Clang/LLVM for PowerPC processor. The cmake command i'm using is:

cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr/llvm6 -DCMAKE_CROSSCOMPILING=True -DLLVM_DEFAULT_TARGET_TRIPLE=powerpc-linux-gnu -DLLVM_TARGET_ARCH=PowerPC -DLLVM_TARGETS_TO_BUILD=PowerPC ../llvm-6.0.0.src

PowerPC gcc toolchain along with binutils are installed in /usr/powerpc-eabi directory.

My questions are:
1. How to tell LLVM about gcc toolchain and binutils installation directory? Do we have to change/modify/add the path of gcc toolchain in llvm-6.0.0.src/tools/clang/lib/Driver directory files?
There's an option --gcc-toolchain=.
 

2. LLVM is successfully built using above cmake. I'm not able to use --sysroot=/usr/powerpc-eabi. In fact it is ineffective.

Please help.

Rgs,
VSP
_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev

_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev