[Gcc] -m32 optioin: cannot find crt1.o / No such file or directory
32bit 빌드가 필요할때 위와 같이 -m32 옵션을 사용하여 컴파일 할 수 있다.
그런데 계속해서 에러가 발생했는데...
1
|
....No such file or directory
|
cs |
와 같은 문구가 계속 발생했다.
GCC 옵션중에 32bit 컴파일은 -m32 / m64 로 64bit를 빌드할 수 있다.
그런데 이런 양방향 빌드를 위해 필요한 작업이 있다. 이 환경을 작업해주는 패키지를 설치하면 해결할 수 있다.
1
|
sudo apt install gcc-multilib
|
cs |
https://www.tutorialspoint.com/how-to-compile-32-bit-program-on-64-bit-gcc-in-c-and-cplusplus
How to compile 32-bit program on 64- bit gcc in C and C++
How to compile 32-bit program on 64- bit gcc in C and C++ Nowadays the compiler comes with default 64-bit version. Sometimes we need to compile and execute a code into some 32bit system. In that time, we have to use this feature. At first, we have to check
www.tutorialspoint.com
https://stackoverflow.com/questions/6329887/compiling-problems-cannot-find-crt1-o
Compiling problems: cannot find crt1.o
I have a virtual Debian system which I use to develop. Today I wanted to try llvm/clang. After installing clang I can't compile my old c-projects (with gcc). This is the error: ... /usr/bin/ld: ...
stackoverflow.com