2014-07-09 3 views
1

크로스 컴파일러 툴체인을 설정하는 방법을 배우려면 http://www.openrisc.net/toolchain-build.html을 따르고 있습니다. 그리고 uClibc를 다시 빌드 한 결과 라이브러리 파일이 $ {SYSROOT}/usr/lib에 올바르게 설치되지 않았 음을 알았습니다. 내가 이전에 GMP, mpfr와 MPC를 설치gcc 컴파일, 구성 : 오류 : 오브젝트 파일의 접미어를 계산할 수 없습니다 : 컴파일 할 수 없습니다

.. 그래서 나는 처음부터 이상 할 시도하고 지금은 첫 번째 패스에 대한 gcc가 컴파일에 붙어있어 (5 8 밖으로 파일은 어쨌든 복사됩니다)./usr/local 아래에 설치되었습니다. (헤더 포함// usr/지방에있는 라이브러리는/usr/local/lib에) (GCC-build 디렉토리에서) 그래서 gcc가 컴파일을 위해, 내가 달릴

../gcc-svn/- configure --target = or32-linux --prefix = $ PREFIX --disable-libssp --srcdir = ../gcc-svn - 가능 언어 = c - 헤더없이 --enable-threads = single --disable-libgomp --disable-libmudflap --with-GMP =/usr/지방 --with-mpfr =/usr/지방 --with-MPC =/usr/지방

도망

make

그리고이 오류 메시지 (오류 부분 표시) 개체 파일의 접미사를 확인 ... 구성 : 오류 : /home/ckim/openrisc/toolchain/gcc-build/or32-linux/libgcc': configure: error: cannot compute suffix of object files: cannot compile See config.log '에 대한 자세한 내용은. 메이크업 [1] : * [구성 대상-관하여 libgcc] 오류 1 메이크업 [1] : 떠나 디렉토리`/ 홈/ckim/openrisc/툴체인/GCC 빌드 ' 메이크업 : * [모든] 오류 2

그래서 나는 /home/ckim/openrisc/toolchain/or32-linux/libgcc/config.log 파일을 들여다 보았다. 오류가있는 부분에이 부분이 표시됩니다. (전체의 로그 파일에있다 http://pastebin.com/6HdfrqBy)

....

configure:3020: /home/ckim/openrisc/toolchain/gcc-build/./gcc/xgcc -B/home/ckim/openrisc/toolchain/gcc-build/./gcc/ - 
B/home/ckim/openrisc/toolchain/or32-linux/bin/ -B/home/ckim/openrisc/toolchain/or32-linux/lib/ -isystem 
/home/ckim/openrisc/toolchain/or32-linux/include -isystem /home/ckim/openrisc/toolchain/or32-linux/sys-include -o 
conftest -g -O2 conftest.c >&5 
/home/ckim/openrisc/toolchain/gcc-build/./gcc/as: line 83: exec: : not found 
configure:3023: $? = 1 
configure:3211: checking for suffix of object files 
configure:3233: /home/ckim/openrisc/toolchain/gcc-build/./gcc/xgcc -B/home/ckim/openrisc/toolchain/gcc-build/./gcc/ - 
B/home/ckim/openrisc/toolchain/or32-linux/bin/ -B/home/ckim/openrisc/toolchain/or32-linux/lib/ -isystem 
/home/ckim/openrisc/toolchain/or32-linux/include -isystem /home/ckim/openrisc/toolchain/or32-linux/sys-include -c -g -O2 
conftest.c >&5 
/home/ckim/openrisc/toolchain/gcc-build/./gcc/as: line 83: exec: : not found 
configure:3237: $? = 1 
configure: failed program was: 
| /* confdefs.h */ 
| #define PACKAGE_NAME "GNU C Runtime Library" 
| #define PACKAGE_TARNAME "libgcc" 
| #define PACKAGE_VERSION "1.0" 
| #define PACKAGE_STRING "GNU C Runtime Library 1.0" 
| #define PACKAGE_BUGREPORT "" 
| #define PACKAGE_URL "http://www.gnu.org/software/libgcc/" 
| /* end confdefs.h. */ 
| 
| int 
| main() 
| { 
| 
| ; 
| return 0; 
| } 
configure:3251: error: in `/home/ckim/openrisc/toolchain/gcc-build/or32-linux/libgcc': 
configure:3254: error: cannot compute suffix of object files: cannot compile 
See `config.log' for more details. 

메시지 찾고 그것이 GMP, mfpr, MPC 라이브러리를 갖지 않는 관련 될 수 나타낸다. Cento6.4입니다. LD_LIBRARY_PATH 및 LIBRARY_PATH에/usr/local/lib (gmp, mpfr 및 mpc 용)가 있어야합니다. --program-prefix = or32-linux를 추가하려고 시도했지만 모든 파일을 제거한 후 시도했습니다 .. 누구든지 내게이 점에 대해 약간의 조명을 줄 수 있습니까?

+0

ADD : '쉬운 방법'을 시도하고 이번에는 효과가있었습니다. 그러나 나는 아직도 나의 질문에 대한 답을 알고 싶다. openrisc toolchain에 대한 –

+0

, 당신은 새로운 버전을 따라야합니다! http://opencores.org/or1k/OpenRISC_GNU_tool_chain#Linux_.28uClibc.29_toolchain_.28or1k-linux-uclibc.29 (Linux (uClibc) toolchain (or1k-linux-uclibc)에서 읽음) –

+0

내가 언급 한 새로운 도구로 위에, 모든 것은 산들 바람이다. –

답변

1

gcc 빌드 환경에 필요한 라이브러리를 포함시키기 위해 포함 된 종속성 스크립트를 사용해 보셨습니까?

contrib/download_prerequisites 

이렇게하면 라이브러리를 외부에서 빌드하고 gcc 구성을 가리키는 대보다 쉽게 ​​수행 할 수 있습니다.

관련 문제