GithubHelp home page GithubHelp logo

Require in electron failed about frida-node HOT 3 CLOSED

frida avatar frida commented on August 26, 2024
Require in electron failed

from frida-node.

Comments (3)

snooze6 avatar snooze6 commented on August 26, 2024 1

Ok, It worked and immediately after that I realised that there is a frida-electron package which is exactly what I wanted in the releases page.
So I end up using electron 1.6.15 with the corresponding frida module. I simply created an .npmrc file and fill it with:

; userconfig /path/to/user/config/.npmrc
runtime = "electron"
target = "1.6.15"

My bad for not seeing the releases page.

from frida-node.

oleavr avatar oleavr commented on August 26, 2024

Did you npm install the frida module with these variables on the command-line: npm_config_runtime=electron npm_config_target=1.8.1? You will also have to build frida-node for 1.8.x (see frida/releng/release.py for details) — you can use npm link afterwards to use it in your Electron project.

from frida-node.

snooze6 avatar snooze6 commented on August 26, 2024

I've tried to require frida in nw.js which uses 8.6.0 and it has the same problem.

After that I tried to compile it using npm:

export npm_config_runtime=electron
export npm_config_target=1.8.1
npm install frida

Which gives me an error importing <frida-core.h>:

prebuild-install WARN install No prebuilt binaries found (target=1.8.1 runtime=electron arch=x64 platform=darwin)
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

  CXX(target) Release/obj.target/frida_binding/src/addon.o
In file included from ../src/addon.cc:1:
In file included from ../src/application.h:4:
In file included from ../src/glib_object.h:4:
In file included from ../src/runtime.h:4:
../src/glib_context.h:4:10: fatal error: 'frida-core.h' file not found
#include <frida-core.h>
         ^~~~~~~~~~~~~~
1 error generated.
make: *** [Release/obj.target/frida_binding/src/addon.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack     at emitTwo (events.js:125:13)
gyp ERR! stack     at ChildProcess.emit (events.js:213:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 16.7.0
gyp ERR! command "/usr/local/Cellar/node/8.7.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/**censored**/node_modules/frida
gyp ERR! node -v v8.7.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok 

Tomorrow I'll try to compile frida from source to check if it's possible to require it in something that isn't pure Node

from frida-node.

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.