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

message show "mach-o, but wrong architecture " when run on MacBook m1(architecture is arm64) #75

Open
fanzhiri opened this issue Oct 17, 2021 · 1 comment

Comments

@fanzhiri
Copy link

/Users/fanzhiri/GitHub/awtk-nodejs/node_modules/bindings/bindings.js:127
throw e;
^

Error: dlopen(/Users/fanzhiri/GitHub/awtk-nodejs/build/Release/awtk.node, 1): no suitable image found. Did find:
/Users/fanzhiri/GitHub/awtk-nodejs/build/Release/awtk.node: mach-o, but wrong architecture
/Users/fanzhiri/GitHub/awtk-nodejs/build/Release/awtk.node: mach-o, but wrong architecture
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 (/Users/fanzhiri/GitHub/awtk-nodejs/node_modules/bindings/bindings.js:117:48)
at Object. (/Users/fanzhiri/GitHub/awtk-nodejs/awtk.js:1:31)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Module.load (internal/modules/cjs/loader.js:928:32)

fanzhiri@fanzhirideAir awtk-nodejs % file /Users/fanzhiri/GitHub/awtk-nodejs/build/Release/awtk.node
/Users/fanzhiri/GitHub/awtk-nodejs/build/Release/awtk.node: Mach-O 64-bit bundle arm64

@fanzhiri
Copy link
Author

fanzhiri@fanzhirideAir awtk-nodejs % node demos/button.js
binding.js bindings opts:awtk.node
binding.js bindings opts.module_root:/Users/fanzhiri/GitHub/awtk-nodejs
binding.js bindings exports.getFileName():/Users/fanzhiri/GitHub/awtk-nodejs/awtk.js
binding.js bindings path.extname(opts.bindings):.node
binding.js opts.path :undefined
binding.js opts.path :undefined
binding.js opts.path :undefined
/Users/fanzhiri/GitHub/awtk-nodejs/node_modules/bindings/bindings.js:127
throw e;
^

Error: dlopen(/Users/fanzhiri/GitHub/awtk-nodejs/build/Release/awtk.node, 0x0001): tried: '/Users/fanzhiri/GitHub/awtk-nodejs/build/Release/awtk.node' (mach-o file, but is an incompatible architecture (have 'arm64', need 'x86_64')), '/usr/local/lib/awtk.node' (no such file), '/usr/lib/awtk.node' (no such file)
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 (/Users/fanzhiri/GitHub/awtk-nodejs/node_modules/bindings/bindings.js:117:48)
at Object. (/Users/fanzhiri/GitHub/awtk-nodejs/awtk.js:1:31)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Module.load (internal/modules/cjs/loader.js:928:32)

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

1 participant