Closed bhsrampage closed 1 year ago
You are trying to use an outdated version of better-sqlite3 (v7.6.2) which lacks several adjustments to run / compile on MacOS with arm64. Please use the latest version of better-sqlite3 8.4.0 to make use of the prebuilt binary for MacOS.
You are trying to use an outdated version of better-sqlite3 (v7.6.2) which lacks several adjustments to run / compile on MacOS with arm64. Please use the latest version of better-sqlite3 8.4.0 to make use of the prebuilt binary for MacOS.
Actualy its a part of my projects dependency tree which goes as follows @walletconnect/react-native-dapp -> keyvaluestorage -> better-sqlite3
Well then either notify that project to update its dependencies or make use of yarns capabilities to load specific module versions and load the latest better-sqlite3 release. Should be possible as there have been no changes to the better-sqlite3 API itself.
There is no way to retroactive make version 7.6.2 compile on MacOS with arm64 without manually backporting the changes included in the later versions.
Thank you. Specifying the newer version of this package under "resolutions" key in package.json helped solve the issue
For yarn :
"resolutions": { "better-sqlite3": "^8.4.0" },
For npm :
"overrides": { "better-sqlite3": "^8.4.0" },
yarn install v1.22.19 [1/4] π Resolving packages... [2/4] π Fetching packages... [3/4] π Linking dependencies... warning " > @react-native-seoul/masonry-list@1.4.1" has unmet peer dependency "expo@*". warning "react-native > react-native-codegen > jscodeshift@0.13.1" has unmet peer dependency "@babel/preset-env@^7.1.6". warning " > react-native-crypto@2.2.0" has unmet peer dependency "react-native-randombytes@>=2.0.0 <4.0.0". warning "@react-native-community/eslint-config > @typescript-eslint/eslint-plugin > tsutils@3.21.0" has unmet peer dependency "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta". [4/4] π¨ Building fresh packages... [-/10] β waiting... [2/10] β better-sqlite3 [-/10] β waiting... [-/10] β waiting... error /Users/burhanuddinsavliwala/Developer/Divytech/offer-nft/node_modules/better-sqlite3: Command failed. Exit code: 1 Command: prebuild-install || npm run build-release Arguments: Directory: /Users/burhanuddinsavliwala/Developer/Divytech/offer-nft/node_modules/better-sqlite3 Output: prebuild-install warn install Request timed out
gyp info it worked if it ends with ok gyp info using node-gyp@9.3.1 gyp info using node@20.2.0 | darwin | arm64 gyp info find Python using Python version 3.11.3 found at "/opt/homebrew/opt/python@3.11/bin/python3.11" gyp info spawn /opt/homebrew/opt/python@3.11/bin/python3.11 gyp info spawn args [ gyp info spawn args '/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py', gyp info spawn args 'binding.gyp', gyp info spawn args '-f', gyp info spawn args 'make', gyp info spawn args '-I', gyp info spawn args '/Users/burhanuddinsavliwala/Developer/Divytech/offer-nft/node_modules/better-sqlite3/build/config.gypi', gyp info spawn args '-I', gyp info spawn args '/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp/addon.gypi', gyp info spawn args '-I', gyp info spawn args '/Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/common.gypi', gyp info spawn args '-Dlibrary=shared_library', gyp info spawn args '-Dvisibility=default', gyp info spawn args '-Dnode_root_dir=/Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0', gyp info spawn args '-Dnode_gyp_dir=/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp', gyp info spawn args '-Dnode_lib_file=/Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/<(target_arch)/node.lib', gyp info spawn args '-Dmodule_root_dir=/Users/burhanuddinsavliwala/Developer/Divytech/offer-nft/node_modules/better-sqlite3', gyp info spawn args '-Dnode_engine=v8', gyp info spawn args '--depth=.', gyp info spawn args '--no-parallel', gyp info spawn args '--generator-output', gyp info spawn args 'build', gyp info spawn args '-Goutput_dir=.' gyp info spawn args ] gyp info spawn make gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ] TOUCH ba23eeee118cd63e16015df367567cb043fed872.intermediate ACTION deps_sqlite3_gyp_locate_sqlite3_target_copy_builtin_sqlite3 ba23eeee118cd63e16015df367567cb043fed872.intermediate TOUCH Release/obj.target/deps/locate_sqlite3.stamp CC(target) Release/obj.target/sqlite3/gen/sqlite3/sqlite3.o LIBTOOL-STATIC Release/sqlite3.a CXX(target) Release/obj.target/better_sqlite3/src/better_sqlite3.o In file included from ../src/better_sqlite3.cpp:4: In file included from ./src/better_sqlite3.lzz:11: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/node.h:73: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8.h:24: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-array-buffer.h:12: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-local-handle.h:12: /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:465:30: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] SHARED_EXTERNAL_POINTER_TAGS(CHECK_SHARED_EXTERNAL_POINTER_TAGS) ^ /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:465:30: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:465:30: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:465:30: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:465:30: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] PER_ISOLATE_EXTERNAL_POINTER_TAGS(CHECK_NON_SHARED_EXTERNAL_POINTER_TAGS) ^ /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:466:35: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:693:61: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] static_assert(kJSObjectType + 1 == kFirstJSApiObjectType); ^ , "" /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:694:55: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] static_assert(kJSObjectType < kLastJSApiObjectType); ^ , "" /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-internal.h:695:63: warning: 'static_assert' with no message is a C++17 extension [-Wc++17-extensions] static_assert(kFirstJSApiObjectType < kLastJSApiObjectType); ^ , "" In file included from ../src/better_sqlite3.cpp:4: In file included from ./src/better_sqlite3.lzz:11: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/node.h:73: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8.h:24: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-array-buffer.h:13: In file included from /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-object.h:9: /Users/burhanuddinsavliwala/Library/Caches/node-gyp/20.2.0/include/node/v8-maybe.h:106:45: error: no template named 'is_lvalue_reference_v' in namespace 'std'; did you mean 'is_lvalue_reference'? template <class U, std::enable_if_t<!std::is_lvalue_reference_v>*>