Skip to content

Issues building librascal on Mac M1 #383

Open
@rosecers

Description

@rosecers

Hey all,

Just trying to get librascal compiled on my new laptop, ran into some issues.

Output from mkdir build && cd build && cmake .. && make VERBOSE=1:

-- Build type is: Release
-- The CXX compiler identification is AppleClang 13.0.0.13000029
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /Library/Developer/CommandLineTools/usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Downloading wigxjpf 
-- Found PythonInterp: /opt/miniconda3/bin/python3 (found suitable version "3.9.5", minimum required is "3") 
-- Found PythonLibs: /opt/miniconda3/lib/libpython3.9.dylib
-- Performing Test HAS_FLTO
-- Performing Test HAS_FLTO - Success
-- Performing Test HAS_FLTO_THIN
-- Performing Test HAS_FLTO_THIN - Success
-- Installation ROOT: /opt/miniconda3
-- Warning: this does not have an effect - use NO_SYSTEM_FROM_IMPORTED if using imported targets
-- cpplint parser: /opt/miniconda3/bin/cpplint
-- clang-format not found, so the pretty-cpp target is unavailable
-- BLACK auto formatter: /opt/miniconda3/bin/black
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/rca/source_installs/librascal/build
/opt/miniconda3/bin/cmake -S/Users/rca/source_installs/librascal -B/Users/rca/source_installs/librascal/build --check-build-system CMakeFiles/Makefile.cmake 0
/opt/miniconda3/bin/cmake -E cmake_progress_start /Users/rca/source_installs/librascal/build/CMakeFiles /Users/rca/source_installs/librascal/build//CMakeFiles/progress.marks
/Library/Developer/CommandLineTools/usr/bin/make  -f CMakeFiles/Makefile2 all
/Library/Developer/CommandLineTools/usr/bin/make  -f src/CMakeFiles/rascal.dir/build.make src/CMakeFiles/rascal.dir/depend
cd /Users/rca/source_installs/librascal/build && /opt/miniconda3/bin/cmake -E cmake_depends "Unix Makefiles" /Users/rca/source_installs/librascal /Users/rca/source_installs/librascal/src /Users/rca/source_installs/librascal/build /Users/rca/source_installs/librascal/build/src /Users/rca/source_installs/librascal/build/src/CMakeFiles/rascal.dir/DependInfo.cmake --color=
Dependee "/Users/rca/source_installs/librascal/build/src/CMakeFiles/rascal.dir/DependInfo.cmake" is newer than depender "/Users/rca/source_installs/librascal/build/src/CMakeFiles/rascal.dir/depend.internal".
Dependee "/Users/rca/source_installs/librascal/build/src/CMakeFiles/CMakeDirectoryInformation.cmake" is newer than depender "/Users/rca/source_installs/librascal/build/src/CMakeFiles/rascal.dir/depend.internal".
Scanning dependencies of target rascal
/Library/Developer/CommandLineTools/usr/bin/make  -f src/CMakeFiles/rascal.dir/build.make src/CMakeFiles/rascal.dir/build
[  3%] Building CXX object src/CMakeFiles/rascal.dir/rascal/utils/json_io.cc.o
cd /Users/rca/source_installs/librascal/build/src && /Library/Developer/CommandLineTools/usr/bin/c++ -Drascal_EXPORTS -I/Users/rca/source_installs/librascal/src -isystem /opt/miniconda3/include/eigen3 -isystem /Users/rca/source_installs/librascal/build/external/wigxjpf/inc -isystem /Users/rca/source_installs/librascal/build/external/wigxjpf/cfg -Wall -Wextra -Weffc++ -Wno-non-virtual-dtor -O3 -DNDEBUG -march=native -arch x86_64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk -fPIC -Werror -std=gnu++14 -o CMakeFiles/rascal.dir/rascal/utils/json_io.cc.o -c /Users/rca/source_installs/librascal/src/rascal/utils/json_io.cc
error: unknown target CPU 'vortex'
note: valid target CPU values are: nocona, core2, penryn, bonnell, atom, silvermont, slm, goldmont, goldmont-plus, tremont, nehalem, corei7, westmere, sandybridge, corei7-avx, ivybridge, core-avx-i, haswell, core-avx2, broadwell, skylake, skylake-avx512, skx, cascadelake, cooperlake, cannonlake, icelake-client, icelake-server, tigerlake, sapphirerapids, alderlake, knl, knm, k8, athlon64, athlon-fx, opteron, k8-sse3, athlon64-sse3, opteron-sse3, amdfam10, barcelona, btver1, btver2, bdver1, bdver2, bdver3, bdver4, znver1, znver2, znver3, x86-64, x86-64-v2, x86-64-v3, x86-64-v4
make[2]: *** [src/CMakeFiles/rascal.dir/rascal/utils/json_io.cc.o] Error 1
make[1]: *** [src/CMakeFiles/rascal.dir/all] Error 2
make: *** [all] Error 2

@Luthaf gave me a short-term patch, but this should be fixed long-term. Have fun :)!

Metadata

Metadata

Assignees

No one assigned

    Labels

    compilationIssues related to compilation procedure or settings

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions