-
-
Notifications
You must be signed in to change notification settings - Fork 817
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Impossible to install sqlite-3 in Mac M1 MacOS 12.1 #1538
Comments
Ok, it seems incredible but the problem was... the directory name ("My app") with spaces! |
Same problem. And I don't have spaces in my directory app. |
This happened to me as well. My app directory was |
Same problem, and I don't have spaces in my directory as well... |
I have same problem too, and my directory path without spaces as well. |
same problem on my M1... |
This issue still occurs. Encountering the 403 access denied error when trying to retrieve the precompiled bundle from S3. |
As a short follow-up: If you happen to be someone who
You just might want to check your |
If you use yarn to install packages, you may use npm, for me it works in this case. |
How should the Path look like?
|
If you want to use
|
If you are using:
Then you can try the following: # 1. Install sqlite3 with homebrew
brew install sqlite3
# 2. export compiler related env variables
export LDFLAGS="-L/opt/homebrew/opt/sqlite/lib"
export CPPFLAGS="-I/opt/homebrew/opt/sqlite/include"
export PKG_CONFIG_PATH="/opt/homebrew/opt/sqlite/lib/pkgconfig"
# 3. prepare for a fresh install
rm -rf node_modules
npm cache verify
# 4. use npm instead of yarn
npm i sqlite3 Thank you.操你妈的狗 node-gyp |
+1 |
None of the Answered helped so far for me, has Anyone something new found out? |
For me it worked when going back to Node 14 ( |
This comment worked to help me install sqllite3 #1413 (comment) on my M1 MacBook Pro with node v16.13.0 |
+1 |
Would you be able to try with |
P.S.: I did not need to do any additional changes suggested by @qiuzhanghua except for installing |
For me, |
I get a syntax error when doing this:
|
@visoft This looks seamless solution to me. Huge thanks! |
This fixed it for me. Not just a space in the containing directory - but no spaces anywhere in the complete path leading to the directory. Removing this spaces, everything worked. Thanks! |
Thanks for this! Issue solved for me. |
FYI v5.1.1 now comes with prebuilt Darwin ARM64 binaries 🙂 https://github.com/TryGhost/node-sqlite3/releases/tag/v5.1.1 |
This was the solution for me. Don't think the issue is M1 related at all. |
The issue is related to the M1 since when there isn't a precompiled binary release available it need to compile it from source locally, and the default build environment on macOS cannot compile node-sqlite3 without the additional configuration you've noted. But now that there is a binary release for arm64-darwin as of 5.1.1, you should not need to configure Python anymore 😁 |
This was the case for me: I have a real GCC as my
|
Just had the same issue but no M1 (Intel i9) and I was on macOS Catalina. I'll leave my solution here as reference: Running I hope this helps. |
I solved this problem by setting the node version to 12.22.0 and then using the 'yarn' command. |
This also worked for me, I had also tried installing sqlite using brew initially, but the error still popped up. Probably a combination of both or just this, regardless though it's working. |
This worked for me too - but why? |
We basically just telling npm to use |
I am running into this issue still. I'm using bun to install sqlite3 but I don't think that should make a difference. I'm getting the error I also tried the python set but got |
For the people using Bun and running into the error below.
Bun doesn't run package lifecycle scripts by default, as it's considered a security issue. In order to run the lifecycle scripts for After changing this, you'll need to regenerate the lockfile of Bun.
Hope this helps! |
Hello, I've tried with several versions of Node (12.x, 14.x, 16.x) to successful install sqlite-3 with
npm install sqlite3
but no way, I get always the same error. The dependency in package.json is"sqlite3": "5.0.2"
Here's the error generated by node v14.17.3:
The text was updated successfully, but these errors were encountered: