简体   繁体   中英

When installing node 14.18.1 using nvm my mac uses python 3.9 and throws error on installation

I have an m1 mac with big surr. I needed node v14 to run an old angular app. i had nodev16 ialraedy installed so i tried to install nvm . installed successfully and i have no problem installing any of the different versions of node v16 but when installing node 14.18.1 it is using python 3.9 for some weird reason. I have installed python before is it by mistake using python 3.9 instead of 2.7

also i am searching internet and stack overflow and i read that node v14 cant be run on m1 mac is this true?

can someone please tell how to solve this error.

nvm install 14.18.1
Downloading and installing node v14.18.1...
Downloading https://nodejs.org/dist/v14.18.1/node-v14.18.1-darwin-arm64.tar.xz...

curl: (22) The requested URL returned error: 404 
Binary download from https://nodejs.org/dist/v14.18.1/node-v14.18.1-darwin-arm64.tar.xz failed, trying source.
grep: /Users/rohitkrishnamoorthy/.nvm/.cache/bin/node-v14.18.1-darwin-arm64/node-v14.18.1-darwin-arm64.tar.xz: No such file or directory
Provided file to checksum does not exist.
Binary download failed, trying source.
Detected that you have 8 CPU core(s)
Running with 7 threads to speed up the build
Clang v3.5+ detected! CC or CXX not specified, will use Clang as C/C++ compiler!
Local cache found: ${NVM_DIR}/.cache/src/node-v14.18.1/node-v14.18.1.tar.xz
Checksums match! Using existing downloaded archive ${NVM_DIR}/.cache/src/node-v14.18.1/node-v14.18.1.tar.xz
$>./configure --prefix=/Users/rohitkrishnamoorthy/.nvm/versions/node/v14.18.1 <
Node.js configure: Found Python 3.9.6...
INFO: configure completed successfully
/Library/Developer/CommandLineTools/usr/bin/make -C out BUILDTYPE=Release V=0
  touch /Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/obj.target/node_dtrace_header.stamp
  touch /Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/obj.target/specialize_node_d.stamp
  c++ -o /Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/obj.target/icuucx/deps/icu-small/source/common/uniset.o ../deps/icu-small/source/common/uniset.cpp '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_DARWIN_USE_64_BIT_INODE=1' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DU_COMMON_IMPLEMENTATION=1' '-DU_ATTRIBUTE_DEPRECATED=' '-D_CRT_SECURE_NO_DEPRECATE=' '-DU_STATIC_IMPLEMENTATION=1' '-DUCONFIG_NO_SERVICE=1' '-DU_ENABLE_DYLOAD=0' '-DU_HAVE_STD_STRING=1' '-DUCONFIG_NO_BREAK_ITERATION=0' -I../deps/icu-small/source/common  -O3 -gdwarf-2 -mmacosx-version-min=10.13 -arch x86_64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=gnu++1y -stdlib=libc++ -fno-exceptions -fno-strict-aliasing -MMD -MF /Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/.deps//Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/obj.target/icuucx/deps/icu-small/source/common/uniset.o.d.raw   -c
  c++ -o /Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/obj.target/icuucx/deps/icu-small/source/common/dictbe.o ../deps/icu-small/source/common/dictbe.cpp '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_DARWIN_USE_64_BIT_INODE=1' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DU_COMMON_IMPLEMENTATION=1' '-DU_ATTRIBUTE_DEPRECATED=' '-D_CRT_SECURE_NO_DEPRECATE=' '-DU_STATIC_IMPLEMENTATION=1' '-DUCONFIG_NO_SERVICE=1' '-DU_ENABLE_DYLOAD=0' '-DU_HAVE_STD_STRING=1' '-DUCONFIG_NO_BREAK_ITERATION=0' -I../deps/icu-small/source/common  -O3 -gdwarf-2 -mmacosx-version-min=10.13 -arch x86_64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=gnu++1y -stdlib=libc++ -fno-exceptions -fno-strict-aliasing -MMD -MF /Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/.deps//Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/obj.target/icuucx/deps/icu-small/source/common/dictbe.o.d.raw   -c
  c++ -o /Users/rohitkrishnamoorthy/.nvm/.cache/src/node-v14.18.1/files/out/Release/obj.target/icuucx/deps/icu-small/source/common/chariter.o ../deps/icu-small/source/common/chariter.cpp '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_DARWIN_USE_64_BIT_INODE=1' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DU_COMMON_IMPLEMENTATION=1' '-DU_ATTRIBUTE_DEPRECATED=' '-D_CRT_SECURE_NO_DEPRECATE=' '-DU_STATIC_IMPLEMENTATION=1' '-DUCONFIG_NO_SERVICE=1' '-DU_ENA

You might need to uninstall python 3.9 and install Python 2.7.18.

Node 14.18.1 does work on m1 mac but if you update to Monterey 12.3, the pre-installed Python will be removed. So you might have to install it again.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM