You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a linux based runners on my projects, but run some services run on Windows (x64 and x86).
When trying to install the project to use Windows prebuilt binaries, it tries to use the host detected C++ lib, not the target one. When it checks for prebuilts, it does not find any binary using musl or glibc libraries to download...
The target files should be: napi-v6-win32-unknown-ia32 or napi-v6-win32-unknown-x64.
Is there another way to cross-install this project?
On alpine:
FROM node:18.12.1-alpine
...
RUN npm ci --omit=dev --target_arch=ia32 --target_platform=win32:
...
17.99 npm ERR! node-pre-gyp info check checked for "/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32/node_sqlite3.node" (not found)
On debian:
FROM node:18.12.1-bullseye
...
RUN npm ci --omit=dev --target_arch=ia32 --target_platform=win32:
...
20.52 npm ERR! node-pre-gyp info check checked for "/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32/node_sqlite3.node" (not found)
The other way around also happens (but I do not need it), just tried for post it here.
On Windows:
node-pre-gyp ERR! install response status 404 Not Found on https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.6/napi-v6-linux-unknown-x64.tar.gz
Relevant logs or output
node:18.12.1-alpine:
RUN npm ci --omit=dev --target_arch=ia32 --target_platform=win32:
#0 1.655 npm WARN old lockfile
#0 1.656 npm WARN old lockfile The package-lock.json file was created with an old version of npm,
#0 1.657 npm WARN old lockfile so supplemental metadata must be fetched from the registry.
#0 1.657 npm WARN old lockfile
#0 1.658 npm WARN old lockfile This is a one-time fix-up, please be patient...
#0 1.658 npm WARN old lockfile
#0 18.91 npm WARN deprecated @npmcli/[email protected]: This functionality has been moved to @npmcli/fs
#0 20.52 npm ERR! code 1
#0 20.52 npm ERR! path /app/node_modules/sqlite3
#0 20.52 npm ERR! command failed
#0 20.52 npm ERR! command sh -c node-pre-gyp install --fallback-to-build
#0 20.52 npm ERR! Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32/node_sqlite3.node --module_name=node_sqlite3 --module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32 --napi_version=8 --node_abi_napi=napi --napi_build_version=6 --node_napi_label=napi-v6' (1)
#0 20.52 npm ERR! node-pre-gyp info it worked if it ends with ok
#0 20.52 npm ERR! node-pre-gyp info using [email protected]
#0 20.52 npm ERR! node-pre-gyp info using [email protected] | linux | x64
#0 20.52 npm ERR! node-pre-gyp info check checked for "/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32/node_sqlite3.node" (not found)
#0 20.52 npm ERR! node-pre-gyp http GET https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.6/napi-v6-win32-musl-ia32.tar.gz
#0 20.52 npm ERR! node-pre-gyp ERR! install response status 404 Not Found on https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.6/napi-v6-win32-musl-ia32.tar.gz
#0 20.52 npm ERR! node-pre-gyp WARN Pre-built binaries not installable for [email protected] and [email protected] (node-v108 ABI, musl) (falling back to source compile with node-gyp)
#0 20.52 npm ERR! node-pre-gyp WARN Hit error response status 404 Not Found on https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.6/napi-v6-win32-musl-ia32.tar.gz
#0 20.52 npm ERR! gyp info it worked if it ends with ok
#0 20.52 npm ERR! gyp info using [email protected]
#0 20.52 npm ERR! gyp info using [email protected] | linux | x64
#0 20.52 npm ERR! gyp info ok
#0 20.52 npm ERR! gyp info it worked if it ends with ok
#0 20.52 npm ERR! gyp info using [email protected]
#0 20.52 npm ERR! gyp info using [email protected] | linux | x64
#0 20.52 npm ERR! gyp ERR! find Python
#0 20.52 npm ERR! gyp ERR! find Python Python is not set from command line or npm configuration
#0 20.52 npm ERR! gyp ERR! find Python Python is not set from environment variable PYTHON
#0 20.52 npm ERR! gyp ERR! find Python checking if "python3" can be used
#0 20.52 npm ERR! gyp ERR! find Python - "python3" is not in PATH or produced an error
#0 20.52 npm ERR! gyp ERR! find Python checking if "python" can be used
#0 20.52 npm ERR! gyp ERR! find Python - "python" is not in PATH or produced an error
#0 20.52 npm ERR! gyp ERR! find Python
#0 20.52 npm ERR! gyp ERR! find Python **********************************************************
#0 20.52 npm ERR! gyp ERR! find Python You need to install the latest version of Python.
#0 20.52 npm ERR! gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
#0 20.52 npm ERR! gyp ERR! find Python you can try one of the following options:
#0 20.52 npm ERR! gyp ERR! find Python - Use the switch --python="/path/to/pythonexecutable"
#0 20.52 npm ERR! gyp ERR! find Python (accepted by both node-gyp and npm)
#0 20.53 npm ERR! gyp ERR! find Python - Set the environment variable PYTHON
#0 20.53 npm ERR! gyp ERR! find Python - Set the npm configuration variable python:
#0 20.53 npm ERR! gyp ERR! find Python npm config set python "/path/to/pythonexecutable"
#0 20.53 npm ERR! gyp ERR! find Python For more information consult the documentation at:
#0 20.53 npm ERR! gyp ERR! find Python https://github.com/nodejs/node-gyp#installation
#0 20.53 npm ERR! gyp ERR! find Python **********************************************************
#0 20.53 npm ERR! gyp ERR! find Python
#0 20.53 npm ERR! gyp ERR! configure error
#0 20.53 npm ERR! gyp ERR! stack Error: Could not find any Python installation to use
#0 20.53 npm ERR! gyp ERR! stack at PythonFinder.fail (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/find-python.js:330:47)
#0 20.53 npm ERR! gyp ERR! stack at PythonFinder.runChecks (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/find-python.js:159:21)
#0 20.53 npm ERR! gyp ERR! stack at PythonFinder.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/find-python.js:202:16)
#0 20.53 npm ERR! gyp ERR! stack at PythonFinder.execFileCallback (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/find-python.js:294:16)
#0 20.53 npm ERR! gyp ERR! stack at exithandler (node:child_process:420:5)
#0 20.53 npm ERR! gyp ERR! stack at ChildProcess.errorhandler (node:child_process:432:5)
#0 20.53 npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:513:28)
#0 20.53 npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:289:12)
#0 20.53 npm ERR! gyp ERR! stack at onErrorNT (node:internal/child_process:476:16)
#0 20.53 npm ERR! gyp ERR! stack at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
#0 20.53 npm ERR! gyp ERR! System Linux 5.15.90.1-microsoft-standard-WSL2
#0 20.53 npm ERR! gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32/node_sqlite3.node" "--module_name=node_sqlite3" "--module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32" "--napi_version=8" "--node_abi_napi=napi" "--napi_build_version=6" "--node_napi_label=napi-v6"
#0 20.53 npm ERR! gyp ERR! cwd /app/node_modules/sqlite3
#0 20.53 npm ERR! gyp ERR! node -v v18.12.1
#0 20.53 npm ERR! gyp ERR! node-gyp -v v9.3.1
#0 20.53 npm ERR! gyp ERR! not ok
#0 20.53 npm ERR! node-pre-gyp ERR! build error
#0 20.53 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 configure --fallback-to-build --module=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32/node_sqlite3.node --module_name=node_sqlite3 --module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-musl-ia32 --napi_version=8 --node_abi_napi=napi --napi_build_version=6 --node_napi_label=napi-v6' (1)
#0 20.53 npm ERR! node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/app/node_modules/@mapbox/node-pre-gyp/lib/util/compile.js:89:23)
#0 20.53 npm ERR! node-pre-gyp ERR! stack at ChildProcess.emit (node:events:513:28)
#0 20.53 npm ERR! node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1091:16)
#0 20.53 npm ERR! node-pre-gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:302:5)
#0 20.53 npm ERR! node-pre-gyp ERR! System Linux 5.15.90.1-microsoft-standard-WSL2
#0 20.53 npm ERR! node-pre-gyp ERR! command "/usr/local/bin/node" "/app/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
#0 20.53 npm ERR! node-pre-gyp ERR! cwd /app/node_modules/sqlite3
#0 20.53 npm ERR! node-pre-gyp ERR! node -v v18.12.1
#0 20.53 npm ERR! node-pre-gyp ERR! node-pre-gyp -v v1.0.10
#0 20.53 npm ERR! node-pre-gyp ERR! not ok
#0 20.53
#0 20.53 npm ERR! A complete log of this run can be found in:
#0 20.53 npm ERR! /root/.npm/_logs/2023-03-30T17_11_49_233Z-debug-0.log
node:18.12.1-bullseye:
RUN npm ci --omit=dev --target_arch=ia32 --target_platform=win32:
#0 1.332 npm WARN old lockfile
#0 1.332 npm WARN old lockfile The package-lock.json file was created with an old version of npm,
#0 1.332 npm WARN old lockfile so supplemental metadata must be fetched from the registry.
#0 1.333 npm WARN old lockfile
#0 1.334 npm WARN old lockfile This is a one-time fix-up, please be patient...
#0 1.334 npm WARN old lockfile
#0 12.42 npm WARN deprecated @npmcli/[email protected]: This functionality has been moved to @npmcli/fs
#0 17.03 npm notice
#0 17.03 npm notice New major version of npm available! 8.19.2 -> 9.6.2
#0 17.03 npm notice Changelog: <https://github.com/npm/cli/releases/tag/v9.6.2>
#0 17.03 npm notice Run `npm install -g [email protected]` to update!
#0 17.03 npm notice
#0 17.03 npm ERR! code 1
#0 17.03 npm ERR! path /app/node_modules/sqlite3
#0 17.04 npm ERR! command failed
#0 17.04 npm ERR! command sh -c -- node-pre-gyp install --fallback-to-build
#0 17.04 npm ERR! make: Entering directory '/app/node_modules/sqlite3/build'
#0 17.04 npm ERR! CC(target) Release/obj.target/nothing/../node-addon-api/nothing.o
#0 17.04 npm ERR! AR(target) Release/obj.target/../node-addon-api/nothing.a
#0 17.04 npm ERR! COPY Release/nothing.a
#0 17.04 npm ERR! ACTION deps_sqlite3_gyp_action_before_build_target_unpack_sqlite_dep Release/obj/gen/sqlite-autoconf-3410100/sqlite3.c
#0 17.04 npm ERR! TOUCH Release/obj.target/deps/action_before_build.stamp
#0 17.04 npm ERR! CC(target) Release/obj.target/sqlite3/gen/sqlite-autoconf-3410100/sqlite3.o
#0 17.04 npm ERR! make: Leaving directory '/app/node_modules/sqlite3/build'
#0 17.04 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=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32/node_sqlite3.node --module_name=node_sqlite3 --module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32 --napi_version=8 --node_abi_napi=napi --napi_build_version=6 --node_napi_label=napi-v6' (1)
#0 17.04 npm ERR! node-pre-gyp info it worked if it ends with ok
#0 17.04 npm ERR! node-pre-gyp info using [email protected]
#0 17.04 npm ERR! node-pre-gyp info using [email protected] | linux | x64
#0 17.04 npm ERR! node-pre-gyp info check checked for "/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32/node_sqlite3.node" (not found)
#0 17.04 npm ERR! node-pre-gyp http GET https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.6/napi-v6-win32-glibc-ia32.tar.gz
#0 17.04 npm ERR! node-pre-gyp ERR! install response status 404 Not Found on https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.6/napi-v6-win32-glibc-ia32.tar.gz
#0 17.04 npm ERR! node-pre-gyp WARN Pre-built binaries not installable for [email protected] and [email protected] (node-v108 ABI, glibc) (falling back to source compile with node-gyp)
#0 17.04 npm ERR! node-pre-gyp WARN Hit error response status 404 Not Found on https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.6/napi-v6-win32-glibc-ia32.tar.gz
#0 17.04 npm ERR! gyp info it worked if it ends with ok
#0 17.04 npm ERR! gyp info using [email protected]
#0 17.04 npm ERR! gyp info using [email protected] | linux | x64
#0 17.04 npm ERR! gyp info ok
#0 17.04 npm ERR! gyp info it worked if it ends with ok
#0 17.04 npm ERR! gyp info using [email protected]
#0 17.04 npm ERR! gyp info using [email protected] | linux | x64
#0 17.04 npm ERR! gyp info find Python using Python version 3.9.2 found at "/usr/bin/python3"
#0 17.04 npm ERR! gyp http GET https://nodejs.org/download/release/v18.12.1/node-v18.12.1-headers.tar.gz
#0 17.04 npm ERR! gyp http 200 https://nodejs.org/download/release/v18.12.1/node-v18.12.1-headers.tar.gz
#0 17.04 npm ERR! gyp http GET https://nodejs.org/download/release/v18.12.1/SHASUMS256.txt
#0 17.04 npm ERR! gyp http 200 https://nodejs.org/download/release/v18.12.1/SHASUMS256.txt
#0 17.04 npm ERR! gyp info spawn /usr/bin/python3
#0 17.04 npm ERR! gyp info spawn args [
#0 17.04 npm ERR! gyp info spawn args '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
#0 17.04 npm ERR! gyp info spawn args 'binding.gyp',
#0 17.04 npm ERR! gyp info spawn args '-f',
#0 17.04 npm ERR! gyp info spawn args 'make',
#0 17.04 npm ERR! gyp info spawn args '-I',
#0 17.04 npm ERR! gyp info spawn args '/app/node_modules/sqlite3/build/config.gypi',
#0 17.04 npm ERR! gyp info spawn args '-I',
#0 17.04 npm ERR! gyp info spawn args '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
#0 17.04 npm ERR! gyp info spawn args '-I',
#0 17.04 npm ERR! gyp info spawn args '/root/.cache/node-gyp/18.12.1/include/node/common.gypi',
#0 17.04 npm ERR! gyp info spawn args '-Dlibrary=shared_library',
#0 17.04 npm ERR! gyp info spawn args '-Dvisibility=default',
#0 17.04 npm ERR! gyp info spawn args '-Dnode_root_dir=/root/.cache/node-gyp/18.12.1',
#0 17.04 npm ERR! gyp info spawn args '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
#0 17.04 npm ERR! gyp info spawn args '-Dnode_lib_file=/root/.cache/node-gyp/18.12.1/<(target_arch)/node.lib',
#0 17.04 npm ERR! gyp info spawn args '-Dmodule_root_dir=/app/node_modules/sqlite3',
#0 17.04 npm ERR! gyp info spawn args '-Dnode_engine=v8',
#0 17.04 npm ERR! gyp info spawn args '--depth=.',
#0 17.04 npm ERR! gyp info spawn args '--no-parallel',
#0 17.04 npm ERR! gyp info spawn args '--generator-output',
#0 17.05 npm ERR! gyp info spawn args 'build',
#0 17.05 npm ERR! gyp info spawn args '-Goutput_dir=.'
#0 17.05 npm ERR! gyp info spawn args ]
#0 17.05 npm ERR! gyp info ok
#0 17.05 npm ERR! gyp info it worked if it ends with ok
#0 17.05 npm ERR! gyp info using [email protected]
#0 17.05 npm ERR! gyp info using [email protected] | linux | x64
#0 17.05 npm ERR! gyp info spawn make
#0 17.05 npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
#0 17.05 npm ERR! In file included from Release/obj/gen/sqlite-autoconf-3410100/sqlite3.c:14183:
#0 17.05 npm ERR! /usr/include/stdio.h:27:10: fatal error: bits/libc-header-start.h: No such file or directory
#0 17.05 npm ERR! 27 | #include <bits/libc-header-start.h>
#0 17.05 npm ERR! | ^~~~~~~~~~~~~~~~~~~~~~~~~~
#0 17.05 npm ERR! compilation terminated.
#0 17.05 npm ERR! make: *** [deps/sqlite3.target.mk:143: Release/obj.target/sqlite3/gen/sqlite-autoconf-3410100/sqlite3.o] Error 1
#0 17.05 npm ERR! gyp ERR! build error
#0 17.05 npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
#0 17.05 npm ERR! gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:201:23)
#0 17.05 npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:513:28)
#0 17.05 npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:291:12)
#0 17.05 npm ERR! gyp ERR! System Linux 5.15.90.1-microsoft-standard-WSL2
#0 17.05 npm ERR! gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32/node_sqlite3.node" "--module_name=node_sqlite3" "--module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32" "--napi_version=8" "--node_abi_napi=napi" "--napi_build_version=6" "--node_napi_label=napi-v6"
#0 17.05 npm ERR! gyp ERR! cwd /app/node_modules/sqlite3
#0 17.05 npm ERR! gyp ERR! node -v v18.12.1
#0 17.05 npm ERR! gyp ERR! node-gyp -v v9.1.0
#0 17.05 npm ERR! gyp ERR! not ok
#0 17.05 npm ERR! node-pre-gyp ERR! build error
#0 17.05 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=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32/node_sqlite3.node --module_name=node_sqlite3 --module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-win32-glibc-ia32 --napi_version=8 --node_abi_napi=napi --napi_build_version=6 --node_napi_label=napi-v6' (1)
#0 17.05 npm ERR! node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/app/node_modules/@mapbox/node-pre-gyp/lib/util/compile.js:89:23)
#0 17.05 npm ERR! node-pre-gyp ERR! stack at ChildProcess.emit (node:events:513:28)
#0 17.05 npm ERR! node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1091:16)
#0 17.05 npm ERR! node-pre-gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:302:5)
#0 17.05 npm ERR! node-pre-gyp ERR! System Linux 5.15.90.1-microsoft-standard-WSL2
#0 17.05 npm ERR! node-pre-gyp ERR! command "/usr/local/bin/node" "/app/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
#0 17.05 npm ERR! node-pre-gyp ERR! cwd /app/node_modules/sqlite3
#0 17.05 npm ERR! node-pre-gyp ERR! node -v v18.12.1
#0 17.05 npm ERR! node-pre-gyp ERR! node-pre-gyp -v v1.0.10
#0 17.05 npm ERR! node-pre-gyp ERR! not ok
#0 17.05
#0 17.05 npm ERR! A complete log of this run can be found in:
#0 17.05 npm ERR! /root/.npm/_logs/2023-03-30T17_23_08_172Z-debug-0.log
Version
5.1.6
Node.js Version
18.12.1
How did you install the library?
--target_arch=ia32 ( or x64 ) --target_platform=win32
Additional
Trying to install natively and then using the rebuild --target_arch=ia32 --target_platform=win32 command also ends up with the same result!
The text was updated successfully, but these errors were encountered:
Issue Summary
I have a linux based runners on my projects, but run some services run on Windows (x64 and x86).
When trying to install the project to use Windows prebuilt binaries, it tries to use the host detected C++ lib, not the target one. When it checks for prebuilts, it does not find any binary using
musl
orglibc
libraries to download...The target files should be:
napi-v6-win32-unknown-ia32
ornapi-v6-win32-unknown-x64
.Is there another way to cross-install this project?
On alpine:
On debian:
The other way around also happens (but I do not need it), just tried for post it here.
On Windows:
Relevant logs or output
node:18.12.1-alpine:
node:18.12.1-bullseye:
Version
5.1.6
Node.js Version
18.12.1
How did you install the library?
--target_arch=ia32 ( or x64 ) --target_platform=win32
Additional
Trying to install natively and then using the
rebuild --target_arch=ia32 --target_platform=win32
command also ends up with the same result!The text was updated successfully, but these errors were encountered: