Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

termux linux aarch64 not compatible! #77

Open
nmgwr opened this issue Dec 11, 2020 · 3 comments
Open

termux linux aarch64 not compatible! #77

nmgwr opened this issue Dec 11, 2020 · 3 comments

Comments

@nmgwr
Copy link

nmgwr commented Dec 11, 2020

The Android phone has termux installed and node 14.14.0 installed.

$ uname -a
Linux localhost 4.19.81-perf+ #1 SMP PREEMPT Fri Nov 13 21:32:47 CST 2020 aarch64 Android

Is aarch64 incompatible? Is there any way to be compatible?

error log:

/data/data/com.termux/files/home/web/yitiji-socketserver/node_modules/bindings/bindings.js:121
throw e;
^

Error: dlopen failed: "/data/data/com.termux/files/home/web/yitiji-socketserver/node_modules/node-snap7/build/Release/node_snap7.node" has bad ELF magic: cffaedfe
at Object.Module._extensions..node (internal/modules/cjs/loader.js:1122:18)
at Module.load (internal/modules/cjs/loader.js:928:32)
at Function.Module._load (internal/modules/cjs/loader.js:769:14)
at Module.require (internal/modules/cjs/loader.js:952:19)
at require (internal/modules/cjs/helpers.js:88:18)
at bindings (/data/data/com.termux/files/home/web/yitiji-socketserver/node_modules/bindings/bindings.js:112:48)
at Object. (/data/data/com.termux/files/home/web/yitiji-socketserver/node_modules/node-snap7/lib/node-snap7.js:8:45)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Object.require.extensions. [as .js] (/data/data/com.termux/files/home/web/yitiji-socketserver/node_modules/babel-register/lib/node.js:152:7)

@mathiask88
Copy link
Owner

Currently there are no android prebuilds available. Will be available with the NAPI rewrite. If you have a built toolchain on your phone you can try to npm -i node-snap7 --build-from-source

@nmgwr
Copy link
Author

nmgwr commented Dec 13, 2020

What means is built toolchain ?

run: npm -i node-snap7 --build-from-source

[root@localhost yitiji-socketserver]# npm -i node-snap7 --build-from-source

Usage: npm

where is one of:
access, adduser, audit, bin, bugs, c, cache, ci, cit,
clean-install, clean-install-test, completion, config,
create, ddp, dedupe, deprecate, dist-tag, docs, doctor,
edit, explore, fund, get, help, help-search, hook, i, init,
install, install-ci-test, install-test, it, link, list, ln,
login, logout, ls, org, outdated, owner, pack, ping, prefix,
profile, prune, publish, rb, rebuild, repo, restart, root,
run, run-script, s, se, search, set, shrinkwrap, star,
stars, start, stop, t, team, test, token, tst, un,
uninstall, unpublish, unstar, up, update, v, version, view,
whoami

npm -h quick help on
npm -l display full usage info
npm help search for help on
npm help npm involved overview

Specify configs in the ini-formatted file:
/root/.npmrc
or on the command line via: npm --key value
Config info can be viewed via: npm help config

[email protected] /usr/lib/node_modules/npm

@mathiask88
Copy link
Owner

Install C++11 build tools + python 2.7 to build native node modules and then npm i node-snap7 --build-from-source on your target platform (Sorry I had a typo in the last answer)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants