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

node v0.12.7 cross-compile failure on ubuntu 14.04 and gcc 4.8.4 #3181

Closed
Junkern opened this issue Oct 5, 2015 · 4 comments
Closed

node v0.12.7 cross-compile failure on ubuntu 14.04 and gcc 4.8.4 #3181

Junkern opened this issue Oct 5, 2015 · 4 comments
Labels
build Issues and PRs related to build files or the CI. windows Issues and PRs related to the Windows platform.

Comments

@Junkern
Copy link

Junkern commented Oct 5, 2015

I am compiling node v0.12.7 on ubuntu 14.04 running in a VM. I want to have a windows executable
./configure --dest-cpu=x64 --dest-os=win
make

In file included from ../src/node_counters.h:28:0, from ../src/node.cc:31: ../src/node_win32_perfctr_provider.h:33:8: error: ‘HANDLE’ does not name a type extern HANDLE NodeCounterProvider; ^ ../src/node_win32_perfctr_provider.h: In function ‘bool node::NODE_COUNTER_ENABLED()’: ../src/node_win32_perfctr_provider.h:35:45: error: ‘NodeCounterProvider’ was not declared in this scope INLINE bool NODE_COUNTER_ENABLED() { return NodeCounterProvider != NULL; }

@mscdex
Copy link
Contributor

mscdex commented Oct 5, 2015

It's not quite that easy. You can compile for Windows using a mingw cross compiler, but I'm not sure that mingw is really supported these days. Most likely you are going to need to compile under Visual Studio (at least Express), which means you'd need a Windows machine.

@mscdex mscdex added windows Issues and PRs related to the Windows platform. build Issues and PRs related to build files or the CI. labels Oct 5, 2015
@Junkern
Copy link
Author

Junkern commented Oct 5, 2015

I feared that such an answer would come up (would have been too easy to be true). Anyone knows whether compiling with mingw works?

@mscdex
Copy link
Contributor

mscdex commented Oct 5, 2015

Well, apparently someone has a set of patches for node v0.10.40 (as of this writing) for mingw-w64. So that might be a starting point, although there were a lot of changes between v0.10.40 and v4.x, so those patches may only help so much.

@Junkern
Copy link
Author

Junkern commented Oct 5, 2015

I am building node v0.12.7, btw ;) But still thanks a lot, I will look into this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Issues and PRs related to build files or the CI. windows Issues and PRs related to the Windows platform.
Projects
None yet
Development

No branches or pull requests

2 participants