Skip to content

Header problem when porting old code. #782

Closed

Description

@jcvernaleo

I have some legacy code that I'm trying to port to the latest node and I seem to be hitting an issue related to node-gyp.
I'm running on Ubuntu 15.04. I'm using node installed from nvm (no other node on the system):

jcv@yoshi ~ $ nvm use v4.2.1
Now using node v4.2.1 (npm v3.3.8)
jcv@yoshi ~ $ node-gyp -v
v3.0.3

My code builds fine with node v0.10.40 but nothing newer.
With node4.2.1 when I run node-gyp rebuild I get:

/home/jcv/.node-gyp/4.2.1/include/node/node_internals.h:5:18: fatal error: util.h: No such file or directory
 #include "util.h"

My code needs to include node_internals.h but based on that error I don't see how something with node_internals.h can compile. ~/.node-gyp/4.2.1/include/node/ does not have util.h or util-inl.h
Is there something I'm missing? Some package (system or node)? Or some step I don't understand.
Any ideas would be greatly appreciated.

Activity

  1. bnoordhuis commented on Oct 22, 2015

    @bnoordhuis
    Member

    Sorry, you're on your own. You shouldn't be including node_internals.h in your project. Only node.h, node_buffer.h and node_object_wrap.h are considered "public" headers.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions