Skip to content

"Image not found" with require("nodegit") on Mac OS X #51

Closed

Description

@jbmusso

Greeting,

I'm having trouble using nodegit on Mac OS X

Did :

npm install nodegit

Install went fine, no warning/error issued.

Then in my code :

require("nodegit")

Executing code yields the following error :

Error: dlopen(/Users/speciman/Documents/development/jsdiff/node_modules/nodegit/build/Release/nodegit.node, 1): Library not loaded: /Users/faceleg/Work/Web/js-apprentice.com/Site/node_modules/nodegit/vendor/libgit2/build/libgit2.0.dylib
Referenced from: /Users/speciman/Documents/development/jsdiff/node_modules/nodegit/build/Release/nodegit.node
Reason: image not found
at Object.Module._extensions..node (module.js:485:11)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:362:17)
at require (module.js:378:17)
at Object. (/Users/speciman/Documents/development/jsdiff/node_modules/nodegit/lib/index.js:29:17)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)

Here are the versions I'm using :
Mac OS X 10.8.2
Node 0.8.21
Npm 1.2.11

Any thoughts? Thanks :)

Activity

  1. tbranyen commented on Mar 14, 2013

    @tbranyen
    Member

    Duplicate of #46

  2. faceleg commented on Mar 14, 2013

    @faceleg
    Collaborator

    @tbranyen Actually this is different I think, I've noticed this line:

    Error: dlopen(/Users/speciman/Documents/development/jsdiff/node_modules/nodegit/build/Release/nodegit.node, 1): Library not loaded: /Users/faceleg/Work/Web/js-apprentice.com/Site/node_modules/nodegit/vendor/libgit2/build/libgit2.0.dylib

    Which references a file on my machine. I think I've commited an absolute file reference somewhere.

  3. tbranyen commented on Mar 15, 2013

    @tbranyen
    Member

    Yup just confirmed the same problem here.

  4. jbmusso commented on Mar 15, 2013

    @jbmusso
    Author

    Thanks for looking into it! I indeed noticed that absolute file reference but forgot to mention it for some weird reasons, sorry. Feel free to ask me should you want me to run some tests or try some commands on my machine, I'd be glad to help.

  5. faceleg commented on Mar 16, 2013

    @faceleg
    Collaborator

    @tbranyen @Speciman I'll try to get onto this tonight

  6. faceleg commented on Mar 21, 2013

    @faceleg
    Collaborator

    @Speciman does this issue persist with v0.0.74?

  7. tbranyen commented on Mar 21, 2013

    @tbranyen
    Member

    @faceleg looks good on my end, awesome work :)

  8. jbmusso commented on Mar 23, 2013

    @jbmusso
    Author

    Thanks, I can't tell yet because I'm getting a gyp/python2 related error while installing v0.0.74 :P

    gyp ERR! stack Error: Can't find Python executable "python2", you can set the PYTHON env variable.
    gyp ERR! stack at failNoPython (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:113:14)

    (...truncated...)

    I guess updating the env path myself should fix this error but I thought I should let you know about this possible issue.

    which python

    /usr/bin/python

    Let me know if you want me to open a distinct issue with full error message.

  9. tbranyen commented on Mar 23, 2013

    @tbranyen
    Member

    Was python2 hardcoded? I'd imagine we should check for python2 first, and fall back to python in its absence.

  10. jbmusso commented on Mar 23, 2013

    @jbmusso
    Author

    I believe it was hardcoded, I did a simple npm install nodegit and encountered this error.

  11. added a commit that references this issue on Mar 24, 2013
    87cccb3
  12. faceleg commented on Mar 24, 2013

    @faceleg
    Collaborator

    @tbranyen yes it was hardcoded. I've updated it to do as you've suggested.

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