Skip to content

Instantly share code, notes, and snippets.

@metamatt
Last active August 29, 2015 14:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save metamatt/e09f5bba9c6a5c00eedf to your computer and use it in GitHub Desktop.
Save metamatt/e09f5bba9c6a5c00eedf to your computer and use it in GitHub Desktop.
Be careful when building Node.js from source and asking for both debug and release versions.

If you build Node.js from source and want to try both the Debug and Relase configurations, and you notice that if you do

% ./configure --without-snapshot --debug
% make

you get both Debug and Release versions, and you think you can use them normally, think again:

magi@ubuntu ~/s/d/node> strings out/Debug/node | grep default_configuration
                       'default_configuration': 'Debug',
magi@ubuntu ~/s/d/node> strings out/Release/node | grep default_configuration
                       'default_configuration': 'Debug',

Note that even the "Release" binary memorized the configuration you built as "Debug", and thus, if you use npm or node-gyp to build native code extensions with this node binary, it'll be misdetected as Release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment