title: sqlite3 on m1 chip npm is failing
body: <p>I'm attempting to install the sqlite3 module on my mac m1 and it's giving me a ton of errors. Yes, I have xcode installed and up-to-date. I've tried using sudo npm i, and also removed the .node-gyp folder from the root. I was able to send the same code base to another non m1 mac and it installed without trouble.</p>
  <p>I'm also on node v14.x</p>
  <pre><code>npm ERR! code 1
  npm ERR! path /Users/nathanleggatt/Projects/chimp/node_modules/sqlite3
  npm ERR! command failed
  npm ERR! command sh -c node-pre-gyp install --fallback-to-build
  npm ERR! ACTION deps_sqlite3_gyp_action_before_build_target_unpack_sqlite_dep Release/obj/gen/sqlite-autoconf-3300100/sqlite3.c
  npm ERR!   TOUCH Release/obj.target/deps/action_before_build.stamp
  npm ERR!   CC(target) Release/obj.target/sqlite3/gen/sqlite-autoconf-3300100/sqlite3.o
  npm ERR!   LIBTOOL-STATIC Release/sqlite3.a
  npm ERR! Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/lib/binding/node-v83-darwin-x64/node_sqlite3.node --module_name=node_sqlite3 --module_path=/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/lib/binding/node-v83-darwin-x64 --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v83' (1)
  npm ERR! node-pre-gyp info it worked if it ends with ok
  npm ERR! node-pre-gyp info using node-pre-gyp@0.11.0
  npm ERR! node-pre-gyp info using node@14.15.3 | darwin | x64
  npm ERR! node-pre-gyp WARN Using request for node-pre-gyp https download 
  npm ERR! node-pre-gyp info check checked for &quot;/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/lib/binding/node-v83-darwin-x64/node_sqlite3.node&quot; (not found)
  npm ERR! node-pre-gyp http GET https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v4.1.1/node-v83-darwin-x64.tar.gz
  npm ERR! node-pre-gyp http 403 https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v4.1.1/node-v83-darwin-x64.tar.gz
  npm ERR! node-pre-gyp WARN Tried to download(403): https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v4.1.1/node-v83-darwin-x64.tar.gz 
  npm ERR! node-pre-gyp WARN Pre-built binaries not found for sqlite3@4.1.1 and node@14.15.3 (node-v83 ABI, unknown) (falling back to source compile with node-gyp) 
  npm ERR! node-pre-gyp http 403 status code downloading tarball https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v4.1.1/node-v83-darwin-x64.tar.gz 
  npm ERR! gyp info it worked if it ends with ok
  npm ERR! gyp info using node-gyp@8.4.1
  npm ERR! gyp info using node@14.15.3 | darwin | x64
  npm ERR! gyp info ok 
  npm ERR! gyp info it worked if it ends with ok
  npm ERR! gyp info using node-gyp@8.4.1
  npm ERR! gyp info using node@14.15.3 | darwin | x64
  npm ERR! gyp info find Python using Python version 3.9.10 found at &quot;/usr/local/opt/python@3.9/bin/python3.9&quot;
  npm ERR! gyp info spawn /usr/local/opt/python@3.9/bin/python3.9
  npm ERR! gyp info spawn args [
  npm ERR! gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
  npm ERR! gyp info spawn args   'binding.gyp',
  npm ERR! gyp info spawn args   '-f',
  npm ERR! gyp info spawn args   'make',
  npm ERR! gyp info spawn args   '-I',
  npm ERR! gyp info spawn args   '/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/build/config.gypi',
  npm ERR! gyp info spawn args   '-I',
  npm ERR! gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
  npm ERR! gyp info spawn args   '-I',
  npm ERR! gyp info spawn args   '/Users/nathanleggatt/Library/Caches/node-gyp/14.15.3/include/node/common.gypi',
  npm ERR! gyp info spawn args   '-Dlibrary=shared_library',
  npm ERR! gyp info spawn args   '-Dvisibility=default',
  npm ERR! gyp info spawn args   '-Dnode_root_dir=/Users/nathanleggatt/Library/Caches/node-gyp/14.15.3',
  npm ERR! gyp info spawn args   '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
  npm ERR! gyp info spawn args   '-Dnode_lib_file=/Users/nathanleggatt/Library/Caches/node-gyp/14.15.3/&lt;(target_arch)/node.lib',
  npm ERR! gyp info spawn args   '-Dmodule_root_dir=/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3',
  npm ERR! gyp info spawn args   '-Dnode_engine=v8',
  npm ERR! gyp info spawn args   '--depth=.',
  npm ERR! gyp info spawn args   '--no-parallel',
  npm ERR! gyp info spawn args   '--generator-output',
  npm ERR! gyp info spawn args   'build',
  npm ERR! gyp info spawn args   '-Goutput_dir=.'
  npm ERR! gyp info spawn args ]
  npm ERR! gyp info ok 
  npm ERR! gyp info it worked if it ends with ok
  npm ERR! gyp info using node-gyp@8.4.1
  npm ERR! gyp info using node@14.15.3 | darwin | x64
  npm ERR! gyp info spawn make
  npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
  npm ERR! libtool: unrecognized option `-static'
  npm ERR! libtool: Try `libtool --help' for more information.
  npm ERR! make: *** [Release/sqlite3.a] Error 1
  npm ERR! gyp ERR! build error 
  npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
  npm ERR! gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
  npm ERR! gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
  npm ERR! gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
  npm ERR! gyp ERR! System Darwin 20.3.0
  npm ERR! gyp ERR! command &quot;/usr/local/bin/node&quot; &quot;/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js&quot; &quot;build&quot; &quot;--fallback-to-build&quot; &quot;--module=/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/lib/binding/node-v83-darwin-x64/node_sqlite3.node&quot; &quot;--module_name=node_sqlite3&quot; &quot;--module_path=/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/lib/binding/node-v83-darwin-x64&quot; &quot;--napi_version=7&quot; &quot;--node_abi_napi=napi&quot; &quot;--napi_build_version=0&quot; &quot;--node_napi_label=node-v83&quot;
  npm ERR! gyp ERR! cwd /Users/nathanleggatt/Projects/chimp/node_modules/sqlite3
  npm ERR! gyp ERR! node -v v14.15.3
  npm ERR! gyp ERR! node-gyp -v v8.4.1
  npm ERR! gyp ERR! not ok 
  npm ERR! node-pre-gyp ERR! build error 
  npm ERR! node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/lib/binding/node-v83-darwin-x64/node_sqlite3.node --module_name=node_sqlite3 --module_path=/Users/nathanleggatt/Projects/chimp/node_modules/sqlite3/lib/binding/node-v83-darwin-x64 --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v83' (1)
  npm ERR! node-pre-gyp ERR! stack     at ChildProcess.&lt;anonymous&gt; (/Users/nathanleggatt/Projects/chimp/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
  npm ERR! node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
  npm ERR! node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:1048:16)
  npm ERR! node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:288:5)
  npm ERR! node-pre-gyp ERR! System Darwin 20.3.0
  npm ERR! node-pre-gyp ERR! command &quot;/usr/local/bin/node&quot; &quot;/Users/nathanleggatt/Projects/chimp/node_modules/.bin/node-pre-gyp&quot; &quot;install&quot; &quot;--fallback-to-build&quot;
  npm ERR! node-pre-gyp ERR! cwd /Users/nathanleggatt/Projects/chimp/node_modules/sqlite3
  npm ERR! node-pre-gyp ERR! node -v v14.15.3
  npm ERR! node-pre-gyp ERR! node-pre-gyp -v v0.11.0
  npm ERR! node-pre-gyp ERR! not ok
  
  npm ERR! A complete log of this run can be found in:
  npm ERR!     /Users/nathanleggatt/.npm/_logs/2022-01-27T06_39_15_358Z-debug-0.log
  </code></pre>