Building for 'node' target v0.11.15 fails
I have a dependency on node-sqlite3 v3.0.4 in my package.json. Node version : v0.11.15 Npm version : v2.1.6 I am on windows.
When I do npm install I get compile errors. The errors are similar to
https://github.com/mapbox/node-sqlite3/issues/328#issuecomment-68624926
https://github.com/mapbox/node-sqlite3/issues/382
$APPDIR>npm install npm WARN package.json [email protected] No repository field. npm WARN package.json [email protected] No README data /
[email protected] install $APPDIR\node_modules\sqlite3 node-pre-gyp install --fallback-to-build
$APPDIR\node_modules\sqlite3>node "C:\Program Files (x86)\nodejs\node_modules\npm\bin\node-gyp-bin..
..\node_modules\node-gyp\bin\node-gyp.js" rebuild --name=sqlite3 --configuration=Release --module_name=node_sqlite3 --version=3.0.
4 --major=3 --patch=4 --runtime=node --node_abi=node-v0.11.15 --platform=win32 --target_platform=win32 --arch=ia32 --target_arch=i
a32 --module_main=./lib/sqlite3 --host=https://mapbox-node-binary.s3.amazonaws.com/ --module_path=C:\ACTeamGITlab\ux\dataprov-sqli
te\node_modules\sqlite3\lib\binding\node-v0.11.15-win32-ia32 --module=$APPDIR\node_modules\sqlite3\lib
binding\node-v0.11.15-win32-ia32\node_sqlite3.node --remote_path=./sqlite3/v3.0.4/ --package_name=node-v0.11.15-win32-ia32.tar.gz
--staged_tarball=build\stage\sqlite3\v3.0.4\node-v0.11.15-win32-ia32.tar.gz --hosted_path=https://mapbox-node-binary.s3.amazonaws.
com/sqlite3/v3.0.4/ --hosted_tarball=https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v3.0.4/node-v0.11.15-win32-ia32.tar.gz
child_process: customFds option is deprecated, use stdio instead.
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
unpack_sqlite_dep
sqlite3.c
sqlite3.vcxproj -> $APPDIR\node_modules\sqlite3\build\Release\sqlite3.lib
database.cc
node_sqlite3.cc
statement.cc
..\src\statement.cc(105): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\dataprov-
sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(23): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(24): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(25): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(26): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(28): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\statement.cc(278): warning C4244: 'argument' : conversion from 'int64_t' to 'int', possible loss of data [C:\ACTeamGITlab
ux\dataprov-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(30): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(32): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(33): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(34): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(35): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(36): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(37): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(38): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(39): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(40): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(41): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(42): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(43): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(44): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(45): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(46): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(47): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(48): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(49): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(50): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(51): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(52): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(53): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(54): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(55): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(56): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(57): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\node_sqlite3.cc(58): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\datapro
v-sqlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\database.cc(134): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\dataprov-s
qlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
..\src\database.cc(135): error C2661: 'v8::Object::Set' : no overloaded function takes 3 arguments [C:\ACTeamGITlab\ux\dataprov-s
qlite\node_modules\sqlite3\build\node_sqlite3.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:267:2
3)
gyp ERR! stack at ChildProcess.emit (events.js:110:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:1067:12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "node" "C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "rebuild" "
--name=sqlite3" "--configuration=Release" "--module_name=node_sqlite3" "--version=3.0.4" "--major=3" "--patch=4" "--runtime=node"
"--node_abi=node-v0.11.15" "--platform=win32" "--target_platform=win32" "--arch=ia32" "--target_arch=ia32" "--module_main=./lib/sq
lite3" "--host=https://mapbox-node-binary.s3.amazonaws.com/" "--module_path=C:\ACTeamGITlab\ux\dataprov-sqlite\node_modules\s
qlite3\lib\binding\node-v0.11.15-win32-ia32" "--module=C:\ACTeamGITlab\ux\dataprov-sqlite\node_modules\sqlite3\lib\bindi
ng\node-v0.11.15-win32-ia32\node_sqlite3.node" "--remote_path=./sqlite3/v3.0.4/" "--package_name=node-v0.11.15-win32-ia32.tar.gz
" "--staged_tarball=build\stage\sqlite3\v3.0.4\node-v0.11.15-win32-ia32.tar.gz" "--hosted_path=https://mapbox-node-binary.s3.a
mazonaws.com/sqlite3/v3.0.4/" "--hosted_tarball=https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v3.0.4/node-v0.11.15-win32-ia3
2.tar.gz"
gyp ERR! cwd $APPDIR\node_modules\sqlite3
gyp ERR! node -v v0.11.15
gyp ERR! node-gyp -v v1.0.2
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute 'node-gyp.cmd rebuild --name=sqlite3 --configuration=Release --module_name=node_s
qlite3 --version=3.0.4 --major=3 --patch=4 --runtime=node --node_abi=node-v0.11.15 --platform=win32 --target_platform=win32 --arch
=ia32 --target_arch=ia32 --module_main=./lib/sqlite3 --host=https://mapbox-node-binary.s3.amazonaws.com/ --module_path=C:\ACTeamGI
Tlab\ux\dataprov-sqlite\node_modules\sqlite3\lib\binding\node-v0.11.15-win32-ia32 --module=$APPDIR\node
_modules\sqlite3\lib\binding\node-v0.11.15-win32-ia32\node_sqlite3.node --remote_path=./sqlite3/v3.0.4/ --package_name=node-v0.11.
15-win32-ia32.tar.gz --staged_tarball=build\stage\sqlite3\v3.0.4\node-v0.11.15-win32-ia32.tar.gz --hosted_path=https://mapbox-node
-binary.s3.amazonaws.com/sqlite3/v3.0.4/ --hosted_tarball=https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v3.0.4/node-v0.11.15
-win32-ia32.tar.gz' (1)
node-pre-gyp ERR! stack at ChildProcess.
npm ERR! [email protected] install: node-pre-gyp install --fallback-to-build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the sqlite3 package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-pre-gyp install --fallback-to-build
npm ERR! You can get their info via:
npm ERR! npm owner ls sqlite3
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request: npm ERR! $APPDIR\npm-debug.log
Seems very similar to the problem that was fixed by Set vs. ForceSet changes from #369.
Unfortunately, those changes have not been published in any new version of npm sqlite3 package yet.
+1
My solution to the same problem was to compile directly from git version: npm install https://github.com/mapbox/node-sqlite3/tarball/master --build-from-source --runtime=node-webkit --target_arch=ia32 --target=0.11.6
@martinib77
This fixed the problem I was having with this error as well.
Is the issue here that NPM is just behind the repo in patches?
Yes, definitely.
Looks like it's broken on 0.12.0 as well
That's because Node.js 0.12 is a direct descendant of 0.11.
Right, I just wanted to make it known.
Also seems to fail on io.js (with pretty much the same error). Is there any update on when this can be fixed?
npm install https://github.com/mapbox/node-sqlite3/tarball/master --build-from-source builds fine (no attestation of functionality). Perhaps cut a new release soon?
This is fixed in the v3.0.5 tag