Ubuntu 20.04의 소스에서 GCC 11을 빌드하고 싶습니다. ROS용 패키지를 만드는 데 문제가 있어서 GNU를 업데이트하기로 결정했습니다. 내 gcc 및 g++ 버전은 11.1.0입니다.
다운로드한 gcc 버전을 추출하고 구성하려고 하면
../gcc-releases-gcc-11.1.0/configure -v --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu --prefix=/usr/local/gcc-11.1.0 --enable-checking=release --enable-languages=c,c++,fortran --disable-multilib --program-suffix=-11.1
다음 오류가 발생합니다.
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether ln works... yes
checking whether ln -s works... yes
checking for a sed that does not truncate output... /usr/bin/sed
checking for gawk... no
checking for mawk... mawk
checking for libatomic support... yes
checking for libitm support... yes
checking for libsanitizer support... yes
checking for libvtv support... yes
checking for libhsail-rt support... yes
checking for libphobos support... yes
checking for x86_64-linux-gnu-gcc... x86_64-linux-gnu-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether x86_64-linux-gnu-gcc accepts -g... yes
checking for x86_64-linux-gnu-gcc option to accept ISO C89... none needed
checking whether we are using the GNU C++ compiler... no
checking whether /usr/bin/gcc-11.1.0 accepts -g... no
checking whether g++ accepts -static-libstdc++ -static-libgcc... no
checking for x86_64-linux-gnu-gnatbind... no
checking for gnatbind... no
checking for x86_64-linux-gnu-gnatmake... no
checking for gnatmake... no
checking whether compiler driver understands Ada... no
checking how to compare bootstrapped objects... cmp --ignore-initial=16 $$f1 $$f2
checking whether /usr/bin/gcc-11.1.0 supports C++11 features by default... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with -std=gnu++11... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with -std=gnu++0x... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with -std=c++11... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with +std=c++11... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with -h std=c++11... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with -std=c++0x... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with +std=c++0x... no
checking whether /usr/bin/gcc-11.1.0 supports C++11 features with -h std=c++0x... no
configure: error: *** A compiler with support for C++11 language features is required.
많이 찾아봤는데 해결이 안되네요. 의견 있으십니까?
감사해요