Git Product home page Git Product logo

Comments (2)

matthewkeil avatar matthewkeil commented on July 26, 2024 1

I also ran across this issue and was able to resolve it @rvypandey and @gmarcz

The problem is that the install script attempts to download headers for the lldb version that is found on the system but the headers do not appear to match the binary that is included on M1 macs and the dlopen fails (I think that is what is happening).

I was able to resolve this by installing llvm via homebrew and ensuring it was found on the PATH (before the lldb that is bundled with xcode). Using the blurb in the docs did not correctly override the PATH for me and once that issue was resolved llnode was able to find the correct llvm-config and node-gyp built the dylib correctly.

Here are the commands I used to get things installed successfully.

$ brew install llvm
$ echo 'export PATH="/opt/homebrew/opt/llvm/bin:$PATH"' >> ~/.zshrc
$ # note that its before recopying PATH to make sure it resolves
$ zsh ~/.zshrc
$ which llvm-config

Double check withwhich llvm-config that its on PATH. The correct one, from the homebrew install, needs to come up or the llnode install attempts to download the incorrect headers causing the plugin to fail at load time. Even with restarting my shell the PATH was incorrect and I had to open a new one before this worked correctly for some reason 🤷‍♂️

Once llvm-config is found, llnode does not have to download the headers and the ones it uses will match the version of lldb that starts (handled by llvm-config which was not originally on my M1 mac). You can now successfully run the install and the dylib loads fine.

$ npm i -g llnode
$ llnode                            
(lldb) plugin load '/Users/matthewkeil/.nvm/versions/node/v20.5.1/lib/node_modules/llnode/llnode.dylib'
(lldb) settings set prompt '(llnode) '
(llnode) 

from llnode.

gmarcz avatar gmarcz commented on July 26, 2024

I have the same issue with the plugin on my MacBook Pro M1.
Installed with 'npm install -g llnode' command.

  • llnode: 4.0.0
  • node: v16.20.1
  • lldb: lldb-1403.0.17.67 Apple Swift version 5.8.1 (swiftlang-5.8.0.124.5 clang-1403.0.22.11.100)
  • OS: Darwin MacBook-Pro-M1.local 22.5.0 Darwin Kernel Version 22.5.0: Thu Jun 8 22:22:19 PDT 2023; root:xnu-8796.121.3~7/RELEASE_ARM64_T8103 arm64
  • Xcode: 14.3.1 Build version 14E300c

from llnode.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.