sharp installation issues #119

Closed
opened 2024-05-22 00:18:08 +00:00 by CJ_Clippy · 2 comments
Owner

If I had a dollar for every time I had trouble installing sharp, I would be a very, very rich man.

Every time I have the issue I have to research to find out how to fix it. I'm making this note to remind myself how to fix the problem.

pnpm i               ✔  34m 32s  
Scope: all 5 workspace projects
../bot                                   |  +96 ++++++++++
../next                                  | +521 ++++++++++++++++++++++++++++++++++++++++++++++++++++
Lockfile is up to date, resolution step is skipped
Packages: +1480
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
../uppy                                  | +381 ++++++++++++++++++++++++++++++++++++++
../bot                                   | Progress: resolved 96, reused 96, downloaded 0, added 0, done
../next                                  | Progress: resolved 521, reused 496, downloaded 0, added 0, doProgress: resolved 1480, reused 1189, downloaded 0, added 0, done
../uppy                                  | Progress: resolved 381, reused 87, downloaded 0, added 0, done
../bot/node_modules/.pnpm/esbuild@0.19.12/node_modules/esbuild: Running postinstall script, done in 129ms
../next/node_modules/.pnpm/@fortawesome+fontawesome-free@6.5.2/node_modules/@fortawesome/fontawesome-free: Running postinstall script...
../next/node_modules/.pnpm/@fortawesome+fontawesome-free@6.5.2/node_modules/@fortawesome/fontawesome-fre../next/node_modules/.pnpm/@fortawesome+fontawesome-common-types@6.5.2/node_modules/@fortawesome/fontawesome-common-types: Running postinstall script, done in 97ms
node_modules/.pnpm/core-js@3.36.1/node_modules/core-js: Running postinstall script, done in 77ms
node_modules/.pnpm/core-js-pure@3.36.1/node_modules/core-js-pure: Running postinstall script, done in 63ms
../next/node_modules/.pnpm/@fortawesome+fontawesome-svg-core@6.5.2/node_modules/@fortawesome/fontawesome-svg-core: Running postinstall script...
../next/node_modules/.pnpm/@fortawesome+free-brands-svg-icons@6.5.2/node_modules/@fortawesome/free-brand../next/node_modules/.pnpm/@fortawesome+fontawesome-svg-core@6.5.2/node_modules/@fortawesome/fontawesome../next/node_modules/.pnpm/@fortawesome+free-brands-svg-icons@6.5.2/node_modules/@fortawesome/free-brand../next/node_modules/.pnpm/@fortawesome+free-solid-svg-icons@6.5.2/node_modules/@fortawesome/free-solid-svg-icons: Running postinstall script, done in 90ms
node_modules/.pnpm/esbuild@0.19.11/node_modules/esbuild: Running postinstall script, done in 104ms
node_modules/.pnpm/esbuild@0.16.17/node_modules/esbuild: Running postinstall script, done in 144ms
node_modules/.pnpm/@swc+core@1.4.13/node_modules/@swc/core: Running postinstall script, done in 84ms
node_modules/.pnpm/sharp@0.33.3/node_modules/sharp: Running install script, done in 103ms
node_modules/.pnpm/canvas@2.11.2/node_modules/canvas: Running install script...
node_modules/.pnpm/better-sqlite3@8.0.1/node_modules/better-sqlite3: Running install script, failed in 23.6sext/node_modules/.pnpm/sharp@0.30.7/node_modules/sharp: Running install script, done in 21.3s
.../node_modules/better-sqlite3 install$ prebuild-install || node-gyp rebuild --release
│ prebuild-install warn install No prebuilt binaries found (target=20.13.1 runtime=node arch=x64 libc…
│ gyp info it worked if it ends with ok
│ gyp info using node-gyp@10.1.0
│ gyp info using node@20.13.1 | linux | x64
│ gyp info find Python using Python version 3.12.3 found at "/usr/bin/python3"
│ gyp http GET https://nodejs.org/download/release/v20.13.1/node-v20.13.1-headers.tar.gz
│ gyp http 200 https://nodejs.org/download/release/v20.13.1/node-v20.13.1-headers.tar.gz
│ gyp http GET https://nodejs.org/download/release/v20.13.1/SHASUMS256.txt
│ gyp http 200 https://nodejs.org/download/release/v20.13.1/SHASUMS256.txt
│ gyp info spawn /usr/bin/python3
│ gyp info spawn args [
│ gyp info spawn args '/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/pnpm/dist/node_modules/n…
│ 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 '/home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/bett…
│ gyp info spawn args '-I',
│ gyp info spawn args '/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/pnpm/dist/node_modules/n…
│ gyp info spawn args '-I',
│ gyp info spawn args '/home/cj/.cache/node-gyp/20.13.1/include/node/common.gypi',
│ gyp info spawn args '-Dlibrary=shared_library',
│ gyp info spawn args '-Dvisibility=default',
│ gyp info spawn args '-Dnode_root_dir=/home/cj/.cache/node-gyp/20.13.1',
│ gyp info spawn args '-Dnode_gyp_dir=/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/pnpm/dist…
│ gyp info spawn args '-Dnode_lib_file=/home/cj/.cache/node-gyp/20.13.1/<(target_arch)/node.lib',
│ gyp info spawn args '-Dmodule_root_dir=/home/cj/Documents/futureporn-monorepo/packages/strapi/node_…
│ 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' ]
│ make: Entering directory '/home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm…
│   TOUCH ba23eeee118cd63e16015df367567cb043fed872.intermediate
│   ACTION deps_sqlite3_gyp_locate_sqlite3_target_copy_builtin_sqlite3 ba23eeee118cd63e16015df367567c…
│   TOUCH Release/obj.target/deps/locate_sqlite3.stamp
│   CC(target) Release/obj.target/sqlite3/gen/sqlite3/sqlite3.o
│ make: cc: No such file or directory
│ make: *** [deps/sqlite3.target.mk:198: Release/obj.target/sqlite3/gen/sqlite3/sqlite3.o] Error 127
│ rm ba23eeee118cd63e16015df367567cb043fed872.intermediate
│ make: Leaving directory '/home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/…
│ gyp ERR! build error 
│ gyp ERR! stack Error: `make` failed with exit code: 2
│ gyp ERR! stack at ChildProcess.<anonymous> (/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/p…
│ gyp ERR! System Linux 6.9.0-1-MANJARO
│ gyp ERR! command "/home/cj/.nvm/versions/node/v20.13.1/bin/node" "/home/cj/.nvm/versions/node/v20.1…
│ gyp ERR! cwd /home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/better-sqlit…
│ gyp ERR! node -v v20.13.1
│ gyp ERR! node-gyp -v v10.1.0
│ gyp ERR! not ok 
└─ Failed in 23.6s at /home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/better-sqlite3@8.0.1/node_modules/better-sqlite3
../next/node_modules/.pnpm/sharp@0.30.7/node_modules/sharp: Running install script, done in 21.3s
 ELIFECYCLE  Command failed with exit code 1.
If I had a dollar for every time I had trouble installing `sharp`, I would be a very, very rich man. Every time I have the issue I have to research to find out how to fix it. I'm making this note to remind myself how to fix the problem. ``` pnpm i  ✔  34m 32s  Scope: all 5 workspace projects ../bot | +96 ++++++++++ ../next | +521 ++++++++++++++++++++++++++++++++++++++++++++++++++++ Lockfile is up to date, resolution step is skipped Packages: +1480 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ ../uppy | +381 ++++++++++++++++++++++++++++++++++++++ ../bot | Progress: resolved 96, reused 96, downloaded 0, added 0, done ../next | Progress: resolved 521, reused 496, downloaded 0, added 0, doProgress: resolved 1480, reused 1189, downloaded 0, added 0, done ../uppy | Progress: resolved 381, reused 87, downloaded 0, added 0, done ../bot/node_modules/.pnpm/esbuild@0.19.12/node_modules/esbuild: Running postinstall script, done in 129ms ../next/node_modules/.pnpm/@fortawesome+fontawesome-free@6.5.2/node_modules/@fortawesome/fontawesome-free: Running postinstall script... ../next/node_modules/.pnpm/@fortawesome+fontawesome-free@6.5.2/node_modules/@fortawesome/fontawesome-fre../next/node_modules/.pnpm/@fortawesome+fontawesome-common-types@6.5.2/node_modules/@fortawesome/fontawesome-common-types: Running postinstall script, done in 97ms node_modules/.pnpm/core-js@3.36.1/node_modules/core-js: Running postinstall script, done in 77ms node_modules/.pnpm/core-js-pure@3.36.1/node_modules/core-js-pure: Running postinstall script, done in 63ms ../next/node_modules/.pnpm/@fortawesome+fontawesome-svg-core@6.5.2/node_modules/@fortawesome/fontawesome-svg-core: Running postinstall script... ../next/node_modules/.pnpm/@fortawesome+free-brands-svg-icons@6.5.2/node_modules/@fortawesome/free-brand../next/node_modules/.pnpm/@fortawesome+fontawesome-svg-core@6.5.2/node_modules/@fortawesome/fontawesome../next/node_modules/.pnpm/@fortawesome+free-brands-svg-icons@6.5.2/node_modules/@fortawesome/free-brand../next/node_modules/.pnpm/@fortawesome+free-solid-svg-icons@6.5.2/node_modules/@fortawesome/free-solid-svg-icons: Running postinstall script, done in 90ms node_modules/.pnpm/esbuild@0.19.11/node_modules/esbuild: Running postinstall script, done in 104ms node_modules/.pnpm/esbuild@0.16.17/node_modules/esbuild: Running postinstall script, done in 144ms node_modules/.pnpm/@swc+core@1.4.13/node_modules/@swc/core: Running postinstall script, done in 84ms node_modules/.pnpm/sharp@0.33.3/node_modules/sharp: Running install script, done in 103ms node_modules/.pnpm/canvas@2.11.2/node_modules/canvas: Running install script... node_modules/.pnpm/better-sqlite3@8.0.1/node_modules/better-sqlite3: Running install script, failed in 23.6sext/node_modules/.pnpm/sharp@0.30.7/node_modules/sharp: Running install script, done in 21.3s .../node_modules/better-sqlite3 install$ prebuild-install || node-gyp rebuild --release │ prebuild-install warn install No prebuilt binaries found (target=20.13.1 runtime=node arch=x64 libc… │ gyp info it worked if it ends with ok │ gyp info using node-gyp@10.1.0 │ gyp info using node@20.13.1 | linux | x64 │ gyp info find Python using Python version 3.12.3 found at "/usr/bin/python3" │ gyp http GET https://nodejs.org/download/release/v20.13.1/node-v20.13.1-headers.tar.gz │ gyp http 200 https://nodejs.org/download/release/v20.13.1/node-v20.13.1-headers.tar.gz │ gyp http GET https://nodejs.org/download/release/v20.13.1/SHASUMS256.txt │ gyp http 200 https://nodejs.org/download/release/v20.13.1/SHASUMS256.txt │ gyp info spawn /usr/bin/python3 │ gyp info spawn args [ │ gyp info spawn args '/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/pnpm/dist/node_modules/n… │ 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 '/home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/bett… │ gyp info spawn args '-I', │ gyp info spawn args '/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/pnpm/dist/node_modules/n… │ gyp info spawn args '-I', │ gyp info spawn args '/home/cj/.cache/node-gyp/20.13.1/include/node/common.gypi', │ gyp info spawn args '-Dlibrary=shared_library', │ gyp info spawn args '-Dvisibility=default', │ gyp info spawn args '-Dnode_root_dir=/home/cj/.cache/node-gyp/20.13.1', │ gyp info spawn args '-Dnode_gyp_dir=/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/pnpm/dist… │ gyp info spawn args '-Dnode_lib_file=/home/cj/.cache/node-gyp/20.13.1/<(target_arch)/node.lib', │ gyp info spawn args '-Dmodule_root_dir=/home/cj/Documents/futureporn-monorepo/packages/strapi/node_… │ 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' ] │ make: Entering directory '/home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm… │ TOUCH ba23eeee118cd63e16015df367567cb043fed872.intermediate │ ACTION deps_sqlite3_gyp_locate_sqlite3_target_copy_builtin_sqlite3 ba23eeee118cd63e16015df367567c… │ TOUCH Release/obj.target/deps/locate_sqlite3.stamp │ CC(target) Release/obj.target/sqlite3/gen/sqlite3/sqlite3.o │ make: cc: No such file or directory │ make: *** [deps/sqlite3.target.mk:198: Release/obj.target/sqlite3/gen/sqlite3/sqlite3.o] Error 127 │ rm ba23eeee118cd63e16015df367567cb043fed872.intermediate │ make: Leaving directory '/home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/… │ gyp ERR! build error │ gyp ERR! stack Error: `make` failed with exit code: 2 │ gyp ERR! stack at ChildProcess.<anonymous> (/home/cj/.nvm/versions/node/v20.13.1/lib/node_modules/p… │ gyp ERR! System Linux 6.9.0-1-MANJARO │ gyp ERR! command "/home/cj/.nvm/versions/node/v20.13.1/bin/node" "/home/cj/.nvm/versions/node/v20.1… │ gyp ERR! cwd /home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/better-sqlit… │ gyp ERR! node -v v20.13.1 │ gyp ERR! node-gyp -v v10.1.0 │ gyp ERR! not ok └─ Failed in 23.6s at /home/cj/Documents/futureporn-monorepo/packages/strapi/node_modules/.pnpm/better-sqlite3@8.0.1/node_modules/better-sqlite3 ../next/node_modules/.pnpm/sharp@0.30.7/node_modules/sharp: Running install script, done in 21.3s  ELIFECYCLE  Command failed with exit code 1. ```
CJ_Clippy added the
bug
label 2024-05-22 00:18:08 +00:00
Author
Owner

Ok my bad, this was actually not a sharp issue. It was instead an issue of missing base-devel package. (Arch/Manjaro fresh install yesterday)

Ok my bad, this was actually not a sharp issue. It was instead an issue of missing `base-devel` package. (Arch/Manjaro fresh install yesterday)
CJ_Clippy changed title from fucking sharp to sharp installation issues 2024-05-22 01:59:42 +00:00
Author
Owner

More libvips errors today after I upgraded sharp to version 0.33.5. Putting notes here. I realized that there's no need to have libvips installed locally, because it only needs to exist inside k8s environment. Uninstalled both base-devel and libvips from local machine. If vips is needed locally, I think it might be better and more reliable to use devbox/nix vips package.

More libvips errors today after I upgraded sharp to version 0.33.5. Putting notes here. I realized that there's no need to have libvips installed locally, because it only needs to exist inside k8s environment. Uninstalled both `base-devel` and `libvips` from local machine. If vips is needed locally, I think it might be better and more reliable to use devbox/nix `vips` package.
Sign in to join this conversation.
No description provided.