Skip to content
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

Fails to build on Windows #1

Open
rjgotten opened this issue Dec 4, 2017 · 3 comments
Open

Fails to build on Windows #1

rjgotten opened this issue Dec 4, 2017 · 3 comments

Comments

@rjgotten
Copy link

rjgotten commented Dec 4, 2017

Fails to build on Windows with node-gyp and VS2015 Update 3.

Problem seems to be a redefinition of the int8_t type; a bug in the upstream library.

D:\build\node_modules\sfnt2woff-zopfli>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node "" rebuild )
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
  woff_decode.cc
  win_delay_load_hook.cc
D:\build\node_modules\sfnt2woff-zopfli\src\../sfnt2woff-zopfli/woff.h(45): error C2371: 'int8_t': redefinition; different basic types (compiling source file ..\src\woff_decode.cc) [D:\build\node_modules\sfnt2woff-zopfli\build\woff_decode.vcxproj]
  C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(17): note: see declaration of 'int8_t' (compiling source file ..\src\woff_decode.cc)
  woff_encode.cc
  win_delay_load_hook.cc
D:\build\node_modules\sfnt2woff-zopfli\src\../sfnt2woff-zopfli/woff.h(45): error C2371: 'int8_t': redefinition; different basic types (compiling source file ..\src\woff_encode.cc) [D:\build\node_modules\sfnt2woff-zopfli\build\woff_encode.vcxproj]
  C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(17): note: see declaration of 'int8_t' (compiling source file ..\src\woff_encode.cc)
@eqyiel
Copy link
Owner

eqyiel commented Dec 5, 2017

@rjgotten thanks for bringing this to my attention, I don't know how much I can help with this though because I don't have a windows machine. I'd be happy to accept a PR if there's anything that can be done to make this work for you.

This library needs a bit of TLC but I don't have time at the moment.

@rjgotten
Copy link
Author

rjgotten commented Dec 6, 2017

@eqyiel
It's a problem on the C++ end with the sfnt2woff-zopfli library itself. Ideally they'll fix it and all you'd need to do is pull in the updated version.

For when you're able to revisit your library at a later time, perhaps some food for thought: why not fall back to an Emscripten (or WASM; if supported) build of sfnt2woff-zopfli when the native build fails?

@eqyiel
Copy link
Owner

eqyiel commented Dec 6, 2017

@rjgotten that's a good idea, I'll look into it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants