https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115567
Bug ID: 115567 Summary: Internal Compiler Error: Segmentation Fault during build Product: gcc Version: 12.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: jjleksmi at gmail dot com Target Milestone: --- I am facing issues while building packages using cmake and make commands. When I run the make command it leads to an internal compiler error segmentation fault. I also get segmentation fault (core dumped) certain times when trying to run programs. This is the error I am getting while trying to make a package: ``` cmakefrom /home/jjayalekshmi/gz-rendering-cpy/src/ArrowVisual.cc:18: /usr/include/c++/11/tr1/exp_integral.tcc: In function ‘_Tp std::__detail::__expint_En_series(unsigned int, _Tp)’: /usr/include/c++/11/tr1/exp_integral.tcc:180:20: internal compiler error: Segmentation fault 180 | if (std::abs(__del) < __eps * std::abs(__ans)) | ^~~ 0x70dff104251f ??? ./signal/../sysdeps/unix/sysv/linux/x86_64/libc_sigaction.c:0 0x70dff1029d8f __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58 0x70dff1029e3f __libc_start_main_impl ../csu/libc-start.c:392 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <file:///usr/share/doc/gcc-11/README.Bugs> for instructions. make[2]: *** [src/CMakeFiles/gz-rendering8.dir/build.make:76: src/CMakeFiles/gz-rendering8.dir/ArrowVisual.cc.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:1626: src/CMakeFiles/gz-rendering8.dir/all] Error 2 make: *** [Makefile:166: all] Error 2 ``` And when I am trying to build https://github.com/UniversalRobots/Universal_Robots_ROS2_Driver?tab=readme-ov-file I am facing the same issue: ``` /home/jjayalekshmi/workspaces/ros_ur_driver/src/ros2_control/hardware_interface/test/mock_components/test_generic_system.cpp:1639:1: internal compiler error: Segmentation fault 1639 | } | ^ 0x7595d264251f ??? ./signal/../sysdeps/unix/sysv/linux/x86_64/libc_sigaction.c:0 c++: internal compiler error: Segmentation fault signal terminated program cc1plus Please submit a full bug report, with preprocessed source if appropriate. See <file:///usr/share/doc/gcc-11/README.Bugs> for instructions. gmake[2]: *** [CMakeFiles/test_generic_system.dir/build.make:76: CMakeFiles/test_generic_system.dir/test/mock_components/test_generic_system.cpp.o] Error 4 gmake[1]: *** [CMakeFiles/Makefile2:437: CMakeFiles/test_generic_system.dir/all] Error 2 gmake: *** [Makefile:146: all] Error 2 --- Failed <<< hardware_interface [23.2s, exited with code 2] Summary: 13 packages finished [24.7s] 1 package failed: hardware_interface 1 package had stderr output: hardware_interface 30 packages not processed ``` This is my gcc version: ``` Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/12/lto-wrapper OFFLOAD_TARGET_NAMES=nvptx-none:amdgcn-amdhsa OFFLOAD_TARGET_DEFAULT=1 Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Ubuntu 12.3.0-1ubuntu1~22.04' --with-bugurl=file:///usr/share/doc/gcc-12/README.Bugs --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,m2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-12 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --enable-libphobos-checking=release --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --enable-cet --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none=/build/gcc-12-ALHxjy/gcc-12-12.3.0/debian/tmp-nvptx/usr,amdgcn-amdhsa=/build/gcc-12-ALHxjy/gcc-12-12.3.0/debian/tmp-gcn/usr --enable-offload-defaulted --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu Thread model: posix Supported LTO compression algorithms: zlib zstd gcc version 12.3.0 (Ubuntu 12.3.0-1ubuntu1~22.04) ``` How can I resolve this compiler issue?