-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Error install canvas on Windows #414
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
Comments
have you followed https://github.com./LearnBoost/node-canvas/wiki/Installation---Windows ? |
Do you have GTK+ 2.x installed at C:\GTK ? |
I'm having a similar problem building on Windows 7 64bit. I've installed GTK 3.6.4 64bit and GTK 2.24 32bit but neither of them worked. I then installed GTK 2.22 64bit and that works. It would be good if the canvas build could provide more of a hint, then this issue could be closed. |
Does it also need exactly the 2010 version of visual c++? |
Hey guys, I've posted a solution for this. |
Please see the posted solution, or the updated wiki-page... |
unzipping GTK to C:\GTK worked, it is missing from the automatic instructions you still have to download GTK separately. @zorobabel How is your solution different than the instructions? (What can be updated in the wiki?) It isn't clear from the "Environment" heading if those are pre-requisites or will be installed by the time you're done. |
D:\Git\node-test>npm install
npm http GET https://registry.npmjs.org/canvas
npm http 200 https://registry.npmjs.org/canvas
npm http GET https://registry.npmjs.org/nan
npm http 200 https://registry.npmjs.org/nan
D:\Git\node-test\node_modules\canvas>node "D:\nodejs\node_modules\npm\bin\node-g
yp-bin....\node_modules\node-gyp\bin\node-gyp.js" rebuild
在此解决方案中一次生成一个项目。若要启用并行生成,请添加“/m”开关。
CanvasRenderingContext2d.cc
CanvasPattern.cc
color.cc
PixelArray.cc
..\src\color.cc(353): warning C4305: "???": ?"double"?"float"?? [D:\Git\node-te
st\node_modules\canvas\build\canvas.vcxproj]
..\src\color.cc(356): warning C4305: "*=": ?"double"?"float"?? [D:\Git\node-tes
t\node_modules\canvas\build\canvas.vcxproj]
ImageData.cc
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\CanvasRenderingContext2d
.cc) [D:\Git\node-test\node_modules\canvas\build\canvas.vcxproj]
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\ImageData.cc) [D:\Git\no
de-test\node_modules\canvas\build\canvas.vcxproj]
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\PixelArray.cc) [D:\Git\n
ode-test\node_modules\canvas\build\canvas.vcxproj]
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\CanvasPattern.cc) [D:\Gi
t\node-test\node_modules\canvas\build\canvas.vcxproj]
Canvas.cc
init.cc
Image.cc
CanvasGradient.cc
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\init.cc) [D:\Git\node-te
st\node_modules\canvas\build\canvas.vcxproj]
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\Canvas.cc) [D:\Git\node-
test\node_modules\canvas\build\canvas.vcxproj]
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\Image.cc) [D:\Git\node-t
est\node_modules\canvas\build\canvas.vcxproj]
d:\git\node-test\node_modules\canvas\src\Canvas.h(19): fatal error C1083: ?????
???:"cairo/cairo.h": No such file or directory (..\src\CanvasGradient.cc) [D:\G
it\node-test\node_modules\canvas\build\canvas.vcxproj]
gyp ERR! build error
gyp ERR! stack Error:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe
failed with exit code: 1gyp ERR! stack at ChildProcess.onExit (D:\nodejs\node_modules\npm\node_modul
es\node-gyp\lib\build.js:267:23)
gyp ERR! stack at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:797:
12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "node" "D:\nodejs\node_modules\npm\node_modules\node-gyp
bin\node-gyp.js" "rebuild"
gyp ERR! cwd D:\Git\node-test\node_modules\canvas
gyp ERR! node -v v0.10.25
gyp ERR! node-gyp -v v0.12.2
gyp ERR! not ok
npm ERR! [email protected] install:
node-gyp rebuild
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 canvas package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls canvas
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "D:\nodejs\node.exe" "D:\nodejs\node_modules\npm\bin\n
pm-cli.js" "install"
npm ERR! cwd D:\Git\node-test
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.24
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! D:\Git\node-test\npm-debug.log
npm ERR! not ok code 0
The text was updated successfully, but these errors were encountered: