Skip to content
This repository was archived by the owner on Dec 2, 2026. It is now read-only.
This repository was archived by the owner on Dec 2, 2026. It is now read-only.

Unable to install nodegit#v0.23.0 on Node 10 #1581

Closed

Description

@mvhirsch

Hi folks,

I'm running nodegit on my machine and was really happy to see support for node 10!
Sadly, I'm unable to install it. Can someone please help me with some ideas on how to fix it?

System information

  • node version: 10.13.0
  • npm or yarn version: 6.4.1
  • OS/version/architechture: Linux, Fedora 28 64-bit
  • Applicable nodegit version: 0.23.0
$>  ls -l /usr/lib64/libssl*
-rwxr-xr-x. 1 root root 360824 Sep  3 15:29 /usr/lib64/libssl3.so
lrwxrwxrwx. 1 root root     16 Sep 20 15:46 /usr/lib64/libssl.so -> libssl.so.1.1.0i
lrwxrwxrwx. 1 root root     16 Apr  5  2018 /usr/lib64/libssl.so.10 -> libssl.so.1.0.2o
-rwxr-xr-x. 1 root root 471024 Apr  5  2018 /usr/lib64/libssl.so.1.0.2o
lrwxrwxrwx. 1 root root     16 Sep 20 15:46 /usr/lib64/libssl.so.1.1 -> libssl.so.1.1.0i
-rwxr-xr-x. 1 root root 468080 Sep 20 15:46 /usr/lib64/libssl.so.1.1.0i
$>  ls -l /usr/lib64/libcrypto*
lrwxrwxrwx. 1 root root      19 Sep 20 15:46 /usr/lib64/libcrypto.so -> libcrypto.so.1.1.0i
lrwxrwxrwx. 1 root root      19 Apr  5  2018 /usr/lib64/libcrypto.so.10 -> libcrypto.so.1.0.2o
-rwxr-xr-x. 1 root root 2729216 Apr  5  2018 /usr/lib64/libcrypto.so.1.0.2o
lrwxrwxrwx. 1 root root      19 Sep 20 15:46 /usr/lib64/libcrypto.so.1.1 -> libcrypto.so.1.1.0i
-rwxr-xr-x. 1 root root 2907248 Sep 20 15:46 /usr/lib64/libcrypto.so.1.1.0i

Reproduce

Simply run: $> npm install nodegit

Output looks like:

> nodegit@0.23.0 install /tmp/node_modules/nodegit
> node lifecycleScripts/preinstall && node lifecycleScripts/install

[nodegit] Running pre-install script
[nodegit] Running install script
node-pre-gyp
WARN Using request for node-pre-gyp https download
[nodegit] Success: "/tmp/node_modules/nodegit/build/Release/nodegit.node" is installed via remote
[nodegit] Completed installation successfully.

> nodegit@0.23.0 postinstall /tmp/node_modules/nodegit
> node lifecycleScripts/postinstall

[nodegit] WARN - Could not finish postinstall
{ Error: Command failed: node "/tmp/node_modules/nodegit/dist/nodegit.js"
/tmp/node_modules/nodegit/dist/nodegit.js:16
    throw ex;
    ^

Error: libcrypto.so.1.0.0: cannot open shared object file: No such file or directory
    at Object.Module._extensions..node (internal/modules/cjs/loader.js:717:18)
    at Module.load (internal/modules/cjs/loader.js:598:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:537:12)
    at Function.Module._load (internal/modules/cjs/loader.js:529:3)
    at Module.require (internal/modules/cjs/loader.js:636:17)
    at require (internal/modules/cjs/helpers.js:20:18)
    at Object.<anonymous> (/tmp/node_modules/nodegit/dist/nodegit.js:12:12)
    at Module._compile (internal/modules/cjs/loader.js:688:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:699:10)
    at Module.load (internal/modules/cjs/loader.js:598:32)

    at ChildProcess.exithandler (child_process.js:289:12)
    at ChildProcess.emit (events.js:182:13)
    at maybeClose (internal/child_process.js:962:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5)
  killed: false,
  code: 1,
  signal: null,
  cmd: 'node "/tmp/node_modules/nodegit/dist/nodegit.js"' }

As you can see, I've installed compat-openssl10 on my maschine (libssl.so.1.0.2) and openssl (libssl.so.1.1.0). But nodegit still asks for libcrypto.so.1.0.0 and libssl.so.1.0.0. I do not know why. Where is my error?

I've tried linking ln -s /usr/lib64/libcrypto.so.1.0.2.0o /usr/lib64/libcrypto.so.1.0.0 (same for libssl), which leads to another error, telling me nodegit cannot find OPENSSL_1.0.0 in libssl.so.1.0.0 (which seems to be correct, since I've just linked 1.0.2 for it :-)). Any thoughts?

Activity

  1. maxkorp commented on Nov 13, 2018

    @maxkorp
    Collaborator

    Ugh, and I'm unable to get fedora to install on my machine at home to try to take a stab at this locally.

    How did you install node?

  2. mvhirsch commented on Nov 14, 2018

    @mvhirsch
    Author

    Thank you for answering!

    I'm using nvm, so I've just nvm install 10 (which currently installs v10.13.0 alongside with npm v6.4.1) and running npm install nodegit.

    My nvm --version is 0.33.9

  3. mvhirsch commented on Nov 14, 2018

    @mvhirsch
    Author

    Funfact:

    $> nvm install 11.1
    $> npm install nodegit
    

    Just works (it installed nodegit#v0.23.0 successfully). Why not latest LTS? 🤔

  4. implausible commented on Dec 13, 2018

    @implausible
    Member

    I feel like these links here in the binding.gyp are unnecessary for building nodegit on linux for Node (non-electron) https://github.com/nodegit/nodegit/blob/master/generate/templates/templates/binding.gyp#L194 and might be causing the issue you're seeing. @mvhirsch

  5. mvhirsch commented on Dec 17, 2018

    @mvhirsch
    Author

    @implausible you mean, the line in binding.gyp can be removed - and it works?

  6. implausible commented on Dec 17, 2018

    @implausible
    Member

    Sort of, those links are necessary in electron builds, but should not be necessary in regular node builds (node provides the libraries and headers for crypto / ssl). Let's watch the progress of this PR #1600

  7. mvhirsch commented on Feb 15, 2019

    @mvhirsch
    Author

    Fixed with #1600 in v0.24.0

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