Closed darkomenz closed 1 year ago
Oops I found a typo and corrected the path to mpi.
cmake -DMPI_INCLUDE_PATH=/usr/lib/aarch64-linux-gnu/openmpi/include -DMPI_LIBRARIES=/usr/lib/aarch64-linux-gnu -DGMSH_INCLUDE_PATH=/usr/include -DGMSH_LIBRARIES=/usr/lib/aarch64-linux-gnu -DBLAS_INCLUDE_PATH=/usr/include -DBLAS_LIBRARIES=/usr/lib/aarch64-linux-gnu -DMETIS_INCLUDE_PATH=/usr/include -DMETIS_LIBRARIES=/usr/lib/aarch64-linux-gnu -DMUMPS_INCLUDE_PATH=/usr/include -DMUMPS_LIBRARIES=/usr/lib/aarch64-linux-gnu -DPETSCCONF_INCLUDE_PATH=/usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include -DPETSC_INCLUDE_PATH=/usr/share/petsc/3.15/include -DPETSC_LIBRARIES=/usr/lib/aarch64-linux-gnu -DSLEPC_INCLUDE_PATH=/usr/include/slepc -DSLEPC_LIBRARIES=/usr/lib/aarch64-linux-gnu ..
I tried to compile this library on a Raspberry PI CM4 and it failed.
ubuntu@ubuntu:~/C++/Dependencies/sparselizard/build$ sudo apt-get install -y cmake libomp-dev libopenblas-dev libmetis-dev libopenmpi-dev libmumps-dev petsc-dev slepc-dev libgmsh-dev Reading package lists... Done Building dependency tree... Done Reading state information... Done libgmsh-dev is already the newest version (4.8.4+ds2-2build1). libmetis-dev is already the newest version (5.1.0.dfsg-7build2). libmumps-dev is already the newest version (5.4.1-2). libomp-dev is already the newest version (1:14.0-55~exp2). libopenblas-dev is already the newest version (0.3.20+ds-1). libopenmpi-dev is already the newest version (4.1.2-2ubuntu1). petsc-dev is already the newest version (3.15.5+dfsg1-1build2). slepc-dev is already the newest version (3.15.2+dfsg1-2). cmake is already the newest version (3.22.1-1ubuntu1.22.04.1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
ubuntu@ubuntu:~/C++/Dependencies/sparselizard/build$ cmake -DMPI_INCLUDE_PATH=/usr/lib/aarch64-linux-gnu/openmpi -DMPI_LIBRARIES=/usr/lib/aarch64-linux-gnu -DGMSH_INCLUDE_PATH=/usr/include -DGMSH_LIBRARIES=/usr/lib/aarch64-linux-gnu -DBLAS_INCLUDE_PATH=/usr/include -DBLAS_LIBRARIES=/usr/lib/aarch64-linux-gnu -DMETIS_INCLUDE_PATH=/usr/include -DMETIS_LIBRARIES=/usr/lib/aarch64-linux-gnu -DMUMPS_INCLUDE_PATH=/usr/include -DMUMPS_LIBRARIES=/usr/lib/aarch64-linux-gnu -DPETSCCONF_INCLUDE_PATH=/usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include -DPETSC_INCLUDE_PATH=/usr/share/petsc/3.15/include -DPETSC_LIBRARIES=/usr/lib/aarch64-linux-gnu -DSLEPC_INCLUDE_PATH=/usr/include/slepc -DSLEPC_LIBRARIES=/usr/lib/aarch64-linux-gnu .. -- The CXX compiler identification is GNU 11.3.0 -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- MPI headers found at /usr/lib/aarch64-linux-gnu/openmpi -- MPI library found at /usr/lib/aarch64-linux-gnu -- Gmsh headers found at /usr/include -- Gmsh library found at /usr/lib/aarch64-linux-gnu -- Blas header cblas.h found at /usr/include -- Blas library found at /usr/lib/aarch64-linux-gnu -- Metis headers found at /usr/include -- Metis library found at /usr/lib/aarch64-linux-gnu -- Mumps headers found at /usr/include -- Mumps library found at /usr/lib/aarch64-linux-gnu -- Petsc header petsc.h found at /usr/share/petsc/3.15/include -- Petsc header petscconf.h found at /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include -- Petsc library found at /usr/lib/aarch64-linux-gnu -- Slepc headers found at /usr/include/slepc -- Slepc library found at /usr/lib/aarch64-linux-gnu -- Configuring done WARNING: Target "sparselizard" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "sparselizard" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "sparselizard" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "sparselizard" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "sparselizard" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "sparselizard" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "sparselizard" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "default" requests linking to directory "/usr/lib/aarch64-linux-gnu". Targets may link only to libraries. CMake is dropping the item. -- Generating done -- Build files have been written to: /home/ubuntu/C++/Dependencies/sparselizard/build
ubuntu@ubuntu:~/C++/Dependencies/sparselizard/build$ cmake --build . -j$(nproc) [ 0%] Building CXX object src/CMakeFiles/sparselizard.dir/densemat.cpp.o [ 1%] Building CXX object src/CMakeFiles/sparselizard.dir/element.cpp.o [ 2%] Building CXX object src/CMakeFiles/sparselizard.dir/fourier.cpp.o [ 2%] Building CXX object src/CMakeFiles/sparselizard.dir/harmonic.cpp.o In file included from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscvec.h:9, from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscmat.h:6, from /home/ubuntu/C++/Dependencies/sparselizard/src/densemat.h:19, from /home/ubuntu/C++/Dependencies/sparselizard/src/densemat.cpp:1: /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscsys.h:138:12: fatal error: mpi.h: No such file or directory 138 | # include
| ^
| ^
| ^ [src/CMakeFiles/sparselizard.dir/build.make:90: src/CMakeFiles/sparselizard.dir/element.cpp.o] Error 1
In file included from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscvec.h:9,
from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscmat.h:6,
from /home/ubuntu/C++/Dependencies/sparselizard/src/densemat.h:19,
from /home/ubuntu/C++/Dependencies/sparselizard/src/mesh/gentools.h:20,
from /home/ubuntu/C++/Dependencies/sparselizard/src/element.h:14,
from /home/ubuntu/C++/Dependencies/sparselizard/src/mesh/elements.h:12,
from /home/ubuntu/C++/Dependencies/sparselizard/src/mesh/rawmesh.h:12,
from /home/ubuntu/C++/Dependencies/sparselizard/src/universe.h:14,
from /home/ubuntu/C++/Dependencies/sparselizard/src/harmonic.h:14,
from /home/ubuntu/C++/Dependencies/sparselizard/src/harmonic.cpp:1:
/usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscsys.h:138:12: fatal error: mpi.h: No such file or directory
138 | # include
| ^
~~ compilation terminated. In file included from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscvec.h:9, from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscmat.h:6, from /home/ubuntu/C++/Dependencies/sparselizard/src/densemat.h:19, from /home/ubuntu/C++/Dependencies/sparselizard/src/fourier.h:11, from /home/ubuntu/C++/Dependencies/sparselizard/src/fourier.cpp:1: /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscsys.h:138:12: fatal error: mpi.h: No such file or directory 138 | # include~~ compilation terminated. gmake[2]: [src/CMakeFiles/sparselizard.dir/build.make:76: src/CMakeFiles/sparselizard.dir/densemat.cpp.o] Error 1 gmake[2]: Waiting for unfinished jobs.... gmake[2]: [src/CMakeFiles/sparselizard.dir/build.make:104: src/CMakeFiles/sparselizard.dir/fourier.cpp.o] Error 1 In file included from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscvec.h:9, from /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscmat.h:6, from /home/ubuntu/C++/Dependencies/sparselizard/src/densemat.h:19, from /home/ubuntu/C++/Dependencies/sparselizard/src/mesh/gentools.h:20, from /home/ubuntu/C++/Dependencies/sparselizard/src/element.h:14, from /home/ubuntu/C++/Dependencies/sparselizard/src/element.cpp:1: /usr/lib/petscdir/petsc3.15/aarch64-linux-gnu-real/include/petscsys.h:138:12: fatal error: mpi.h: No such file or directory 138 | # include~~ compilation terminated. gmake[2]:~~ compilation terminated. gmake[2]: [src/CMakeFiles/sparselizard.dir/build.make:118: src/CMakeFiles/sparselizard.dir/harmonic.cpp.o] Error 1 gmake[1]: [CMakeFiles/Makefile2:131: src/CMakeFiles/sparselizard.dir/all] Error 2 gmake: *** [Makefile:136: all] Error 2 ubuntu@ubuntu:~/C++/Dependencies/sparselizard/build$