Skip to content

Symbol not found on macOS Sierra #1622

Closed

Description

@tommoor

System information

  • node version: 10
  • OS/version/architecture: macOS Sierra 10.12
  • Applicable nodegit version: 0.23.0

We have an Electron 4.0 application that works fine on all newer versions of macOS, however on Sierra (and possibly below?) this error is thrown at runtime:

Error: dlopen(/Applications/AppName.app/Contents/Resources/app.asar.unpacked/node_modules/nodegit/build/Release/nodegit.node, 1): Symbol not found: _EVP_aes_128_cbc
  Referenced from: /Applications/AppName.app/Contents/Resources/app.asar.unpacked/node_mod…
  at Object.<anonymous>(nodegit.js:12:12)
  at Object.<anonymous>(nodegit.js:1145:3)

Would love any pointers you might have…

Edit: We've confirmed this is the case on other macOS versions older than Sierra such as El Capitan.

Activity

  1. implausible commented on Feb 6, 2019

    @implausible
    Member

    Perhaps we need to start building the prebuilts for it. I'll see what I can do.

  2. implausible commented on Feb 6, 2019

    @implausible
    Member

    Hmm, seems there are some issues with even building for electron 4. Something major must have changed. I wonder if they started exporting boringssl.

  3. tommoor commented on Feb 7, 2019

    @tommoor
    Author

    Please see this comment for some additional info on the changes in 4.X

    electron/electron#16195 (comment)

    It does seem as though the cbc cipher is exposed by boring, but I’ll admit this is largely over my head

  4. implausible commented on Feb 7, 2019

    @implausible
    Member

    Aha so what happened is that the electron team has moved from naming their folders iojs-x.y.z to x.y.z, and now it's not as easily possible to determine that we're building for electron and not regular node. Wonderful!

  5. implausible commented on Feb 7, 2019

    @implausible
    Member

    Since they switched their naming, they also started providing variables in the config.gypi file which tells us whether it was built_with_electron or not. Hopefully I can get a patch out for 0.23.1 and 0.24.1 shortly. Sorry for the inconvenience!

  6. implausible commented on Feb 7, 2019

    @implausible
    Member

    I'll see if I run an alpha release for nodegit 0.25.0, if I can get it to build on Electron 4 and get back to you!

  7. nornagon commented on Feb 7, 2019

    @nornagon

    See electron/electron#13176

    We don't currently export BoringSSL symbols from the Electron binary.

    [edit] ... and now i see that you've already commented on that issue. My bad, I thought this issue was filed against electron :)

  8. implausible commented on Feb 7, 2019

    @implausible
    Member

    No problem! I just initially went there out of intuition, because I can imagine boringssl + openssl symbols fighting to the death.

  9. tommoor commented on Feb 9, 2019

    @tommoor
    Author

    @implausible what is your current thinking on the cause of this? Sorry to be a hassle but this is a critical issue on our end.

    I'm thinking of maybe forking NodeGit and trying to create a version that retains Node 10 support (which we 100% need) but reverts the changes to OpenSSL – do you think that's even plausible based on your knowledge of the codebase?

  10. tommoor commented on Feb 11, 2019

    @tommoor
    Author

    Found the original PR, it looks like the two are tightly entwined 😢

    Also, had to laugh:
    #1545 (comment)

  11. implausible commented on Feb 11, 2019

    @implausible
    Member

    This is purely caused by the change in header location in Electron 4+.

    The problem is that the detection algorithm used to determine that NodeGit is being built for Electron is not working quite right in the binding.gyp file.

    If you were to fork NodeGit as a temporary solution, I would suggest the steps where we are downloading the prebuilt of OpenSSL for Electron, just enable that step always. (so long as you're just building for Electron). When my coworker gets in today, we will boot up on OSX and figure out why the patch I was working on here: #1623 failed to work for OSX, but worked otherwise. Once we have that figured out it should be another day or so until we can get some patches for 0.23.0 and 0.24.0 out with Electron 4 support.

  12. implausible commented on Feb 11, 2019

    @implausible
    Member

    This should do it! #1626 It looks like I missed some references to the old way of detecting if we were in electron.

  13. implausible commented on Feb 12, 2019

    @implausible
    Member

    Just wrapping up some windows builds. I hope to have 0.23.1 and 0.24.1 out today.

  14. implausible commented on Feb 12, 2019

    @implausible
    Member

    0.23.1 is out now.

  15. implausible commented on Feb 12, 2019

    @implausible
    Member

    0.24.1 is out.

  16. implausible commented on Feb 12, 2019

    @implausible
    Member

    This issue should be resolved. Let me know if there are any further issues.

  17. tommoor commented on Feb 22, 2019

    @tommoor
    Author

    @implausible thanks for your work and turning this one around fast, much appreciated 🙏

  18. Autr commented on Oct 27, 2020

    @Autr

    Hello, I am having this same bug:

    MacOS High Sierra
    Node v13.12.0
    nodegit 0.27.0
    Electron 6.1.11

    App threw an error during load
    [1] Error: dlopen(/Users/Gilbert/Code/multigit/node_modules/nodegit/build/Release/nodegit.node, 1): Symbol not found: _EVP_aes_128_cbc
    [1]   Referenced from: /Users/Gilbert/Code/multigit/node_modules/nodegit/build/Release/nodegit.node
    [1]   Expected in: flat namespace
    
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