2

在我的一个项目中运行npm install时,我收到以下错误:

CMake Error at /usr/local/Cellar/cmake/3.19.4/share/cmake/Modules/CMakeTestCCompiler.cmake:66 (message):
  The C compiler

    "/Library/Developer/CommandLineTools/usr/bin/cc"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: /Users/user.name/.nvm/versions/node/v8.17.0/lib/node_modules/@devicefarmer/stf/node_modules/@julusian/jpeg-turbo/build/CMakeFiles/CMakeTmp
    
    Run Build Command(s):/usr/bin/make cmTC_e8f1f/fast && /Library/Developer/CommandLineTools/usr/bin/make  -f CMakeFiles/cmTC_e8f1f.dir/build.make CMakeFiles/cmTC_e8f1f.dir/build
    Building C object CMakeFiles/cmTC_e8f1f.dir/testCCompiler.c.o
    /Library/Developer/CommandLineTools/usr/bin/cc   -isysroot /Users/user.name/Library/Android/sdk -o CMakeFiles/cmTC_e8f1f.dir/testCCompiler.c.o -c /Users/user.name/.nvm/versions/node/v8.17.0/lib/node_modules/@devicefarmer/stf/node_modules/@julusian/jpeg-turbo/build/CMakeFiles/CMakeTmp/testCCompiler.c
    Linking C executable cmTC_e8f1f
    /usr/local/Cellar/cmake/3.19.4/bin/cmake -E cmake_link_script CMakeFiles/cmTC_e8f1f.dir/link.txt --verbose=1
    /Library/Developer/CommandLineTools/usr/bin/cc  -isysroot /Users/user.name/Library/Android/sdk -Wl,-search_paths_first -Wl,-headerpad_max_install_names -L/usr/local/opt/openssl@1.1/lib  CMakeFiles/cmTC_e8f1f.dir/testCCompiler.c.o -o cmTC_e8f1f 
    ld: library not found for -lSystem
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    make[1]: *** [cmTC_e8f1f] Error 1
    make: *** [cmTC_e8f1f/fast] Error 2
    
    

  

  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  CMakeLists.txt:1 (project)


-- Configuring incomplete, errors occurred!

尝试卸载和安装 CMake 但没有运气。

操作系统:MacOS Catalina 10.15.7

节点:v8.17.0

CMake:v3.19.4

4

0 回答 0