GEOS
GEOS copied to clipboard
Segmentation fault (core dumped) when compiling suitesparse
Hello, Support engineer,
I am using VirtualBox on Win11 OS to host a Ubuntu 22.04.1 LTS system on my personal laptop. I was able to clear a few obstacles when compiling the third-party libraries. However, the compilation was eventually stuck when compiling suitesparse. I cannot find any information on the website and search engines, hence I need your help to get through this issue.
Let me rerun "make", and then I will get the following message:
lh@lh-VirtualBox:~/Geosx/thirdPartyLibs/build-myplatform-release$ make
[ 77%] Built target uncrustify
[ 77%] Built target doxygen
[ 77%] Built target hdf5
[ 77%] Built target conduit
[ 77%] Built target silo
[ 77%] Built target raja
[ 77%] Built target chai
[ 77%] Built target mathpresso
[ 77%] Built target pugixml
[ 77%] Built target trilinos
[ 77%] Built target parmetis
[ 77%] Built target metis
[ 77%] Built target superlu_dist
[ 77%] Built target hypre
[ 77%] Performing configure step for 'suitesparse'
make config CC=/usr/bin/gcc CFLAGS="-O3 -DNDEBUG -D'SuiteSparse_long=long long int' -DSuiteSparse_long_max=2147483647 -DSuiteSparse_long_idd=\"d\" -D'SuiteSparse_long_id=\"%d\"'" CXX=/usr/bin/g++ CXXFLAGS="-O3 -DNDEBUG" FC=/usr/bin/gfortran FCFLAGS="-O3 -DNDEBUG -O3" JOBS=16 CFOPENMP= INSTALL=/home/lh/Geosx/thirdPartyLibs/install-myplatform-release/suitesparse BLAS="-Wl,-rpath,/usr/lib/x86_64-linux-gnu/blas /usr/lib/x86_64-linux-gnu/blas/libblas.so" LAPACK="-Wl,-rpath,/usr/lib/x86_64-linux-gnu/lapack /usr/lib/x86_64-linux-gnu/lapack/liblapack.so" MY_METIS_LIB="/home/lh/Geosx/thirdPartyLibs/install-myplatform-release/metis/lib/libmetis.a" MY_METIS_INC="/home/lh/Geosx/thirdPartyLibs/install-myplatform-release/metis/include" CUDA=no
Segmentation fault (core dumped)
make[2]: *** [CMakeFiles/suitesparse.dir/build.make:93: suitesparse/src/suitesparse-stamp/suitesparse-configure] Error 139
make[1]: *** [CMakeFiles/Makefile2:662: CMakeFiles/suitesparse.dir/all] Error 2
make: *** [Makefile:101: all] Error 2
Since my compilation has already completed 77%, I guess most of my prerequisites and settings should be on the right track (such as lapack, blas, make4.2.1, flex, bison, etc..). I have no idea why there is a segmentation fault error here. I am attaching my cmake file, which was slightly modified from darwin-clang.cmake (I can't find a cmake file for ubuntu in the host-configs directory).
Your feedback is greatly appreciated, and please feel free to let me know if you need any additional information.
Thanks a bunch.
Hi, how much memory do you have in your box? Do you compile in parallel? If you run out of memory, reducing the number of parallel compilations could help.
Hi, how much memory do you have in your box? Do you compile in parallel? If you run out of memory, reducing the number of parallel compilations could help.
Thanks for your response. I used 8GB for my VirtualBox and I was not using parallel compilation. I just increased it to 12GB but the error remains the same. I do not see the issue is related to memory.
@hluo50 - were you able to resolve this issue?
@hluo50 - were you able to resolve this issue?
Hi, @cssherman , I did not spare more effort ...
@hluo50 - were you able to resolve this issue?
Hi, @cssherman , I did not spare more effort ...
Sorry to hear that - as you can imagine, debugging the build process for external dependencies can be challenging, as we don't have direct control of them. We are currently working on a major overhaul of our build process (using the spack package manager), which may help avoid this issue.