You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not sure if this is a jpm issue or a janet issue, but putting it here for now.
I'm using the latest commits for janet and jpm, and am using alpine linux on an x86 laptop and PostmarketOS on an arm laptop (an alpine linux derivative).
The following error crops up on my arm aarch64 laptop.
$ jpm new-c-project ctest
author?
description?
$ cd ctest
$ jpm build
compiling c/module.c to build/c__module.0...
generating meta file build/ctest-native.meta.janet...
creating native module build/ctest-native.so...
compiling c/module.c to build/c__module.static.o...
creating static library build/ctest-native.a...
$ jpm test
running test/basic.janet ...
Hello!
running test/native.janet ...
error: could not load native build/ctest-native.so: Dynamic loading not supported
in native [src/core/corelib.c] on line 288
in native-loader [boot.janet] on line 3060, column 40
in require-1 [boot.janet] on line 3088, column 18
in import* [boot.janet] (tail call) on line 3121, column 15
non-zero exit code in test/native.janet:
x Failing test scripts:
When running the same scenario on my x86 laptop it completes the jpm test without any errors.
P.S.: Thank you by the way for all the work in creating / maintaining Janet and tools. I'm enjoying it greatly so far.
The text was updated successfully, but these errors were encountered:
"Dynamic loading not supported" indicates either your version of libc isn't configured for dynamic loading or that we are missing some flags somewhere. Not sure exactly, I would need to investigate to debug this. I think it has less to do with aarch64 vs x86 than it has to do with the operating system here.
lenzj
changed the title
JPM new-c-project works on x86 but not on arm
JPM new-c-project dynamic loading not supported
Nov 25, 2024
I think you are correct that it is an OS issue more than an aarch64 vs. x86 issue. I created a clean alpine linux container using podman on both operating systems and it worked fine without issues. I changed the issue title accordingly. I can close this as I assume that dynamic loading is a fundamental requirement to be able to load a c module in a janet script. If you think there is something worth investigating here let me know and I will leave the issue open and help where I can.
As a workaround I plan on compiling my janet scripts to static linked executables within a container on the PostmarketOS system.
I'm not sure if this is a jpm issue or a janet issue, but putting it here for now.
I'm using the latest commits for janet and jpm, and am using alpine linux on an x86 laptop and PostmarketOS on an arm laptop (an alpine linux derivative).
The following error crops up on my arm aarch64 laptop.
When running the same scenario on my x86 laptop it completes the jpm test without any errors.
P.S.: Thank you by the way for all the work in creating / maintaining Janet and tools. I'm enjoying it greatly so far.
The text was updated successfully, but these errors were encountered: