Patrick Simmons
2010-Aug-23 23:56 UTC
[LLVMdev] Problem cross-compiling llvm-gcc for AIX-PowerPC
Compiling llvm-gcc on an x86 machine with --target=powerpc-ibm-aix5.1.0.0, I get the following error: make \ CFLAGS="-g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Wold-style-definition -Wmissing-format-attribute " \ CONFIG_H="config.h auto-host.h ../../llvm-gcc-4.2-2.7.source/gcc/../include/ansidecl.h" \ MAKEOVERRIDES= \ -f libgcc.mk all make[3]: Entering directory `/localhome/simmon12/aix-cross/obj/gcc' /localhome/simmon12/aix-cross/obj/./gcc/xgcc -B/localhome/simmon12/aix-cross/obj/./gcc/ -B/localhome/simmon12/aix-cross/obj/../install/powerpc-ibm-aix5.1.0.0/bin/ -B/localhome/simmon12/aix-cross/obj/../install/powerpc-ibm-aix5.1.0.0/lib/ -isystem /localhome/simmon12/aix-cross/obj/../install/powerpc-ibm-aix5.1.0.0/include -isystem /localhome/simmon12/aix-cross/obj/../install/powerpc-ibm-aix5.1.0.0/sys-include -O2 -O2 -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -mlong-double-128 -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I. -I../../llvm-gcc-4.2-2.7.source/gcc -I../../llvm-gcc-4.2-2.7.source/gcc/. -I../../llvm-gcc-4.2-2.7.source/gcc/../include -I../../llvm-gcc-4.2-2.7.source/gcc/../libcpp/include -I../../llvm-gcc-4.2-2.7.source/gcc/../libdecnumber -I../libdecnumber -I/localhome/simmon12/llvm-makefilebuild/include -DL_muldi3 -c ../../llvm-gcc-4.2-2.7.source/gcc/libgcc2.c -o libgcc/./_muldi3.o /localhome/simmon12/aix-cross/obj/./gcc/as: line 2: exec: -u: invalid option Is there anything else I should be doing to build a cross-compiler to generate LLVM bitcode for AIX? My ultimate goal here is just to get a compiler which can generate llvm bitcode I can manipulate and then run through the C backend to generate source I can then compile on AIX. Unfortunately, I must run the code on AIX on POWER. How should I best approach this problem? --Patrick -- If I'm not here, I've gone out to find myself. If I get back before I return, please keep me here.
Anton Korobeynikov
2010-Aug-24 15:44 UTC
[LLVMdev] Problem cross-compiling llvm-gcc for AIX-PowerPC
Hello> ../../llvm-gcc-4.2-2.7.source/gcc/libgcc2.c -o libgcc/./_muldi3.o > /localhome/simmon12/aix-cross/obj/./gcc/as: line 2: exec: -u: invalid optionHave you built & installed cross-binutils for your target? -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
Patrick Alexander Simmons
2010-Aug-24 19:12 UTC
[LLVMdev] Problem cross-compiling llvm-gcc for AIX-PowerPC
No, I hadn't. There's no special LLVM version of binutils, right? You just download binutils and compile it for a different target? I've looked up some stuff and I think I need a cross-glibc as well. Is it necessary to install AIX headers somewhere, too? Also, is there anything LLVM-specific necessary for cross-compiling llvm-gcc? I'm sorry if this is off-topic. If there's nothing LLVM-specific about cross-compiling llvm-gcc, I'll direct future questions to a GCC list. --Patrick On 08/24/2010 09:44 AM, Anton Korobeynikov wrote:> Hello > > >> ../../llvm-gcc-4.2-2.7.source/gcc/libgcc2.c -o libgcc/./_muldi3.o >> /localhome/simmon12/aix-cross/obj/./gcc/as: line 2: exec: -u: invalid option >> > Have you built& installed cross-binutils for your target? > >
Anton Korobeynikov
2010-Aug-24 19:19 UTC
[LLVMdev] Problem cross-compiling llvm-gcc for AIX-PowerPC
Hello, Patrick> I'm sorry if this is off-topic. If there's nothing LLVM-specific about > cross-compiling llvm-gcc, I'll direct future questions to a GCC list.wrt cross-compilation llvm-gcc is pretty much same as gcc. So, you need to have cross-tools available. The only difference is the magic --enable-llvm switch :) -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
Apparently Analagous Threads
- [LLVMdev] Problem cross-compiling llvm-gcc for AIX-PowerPC
- [LLVMdev] Problems building cfrontend 4 source on SUSE 10.1
- [LLVMdev] Problems building cfrontend 4 source on SUSE 10.1
- [LLVMdev] Problems building cfrontend 4 source on SUSE 10.1
- [LLVMdev] Problems building cfrontend 4 source on SUSE 10.1