Closed cheungxi closed 1 month ago
Thanks for reporting, @cheungxi!
You are using the built-in crossclang linker script to link binary objects that have been created by some other compiler. This will not work.
Mostly because of "-Xcrossclang-with-and-without-lc" (which tells our scripts to build both flavors of the dynamic library, one with, and one without dependencies, i.e., nodeps), but also because of "-target default".
See https://kohlschutter.github.io/junixsocket/crosscomp.html how to use crossclang.
Repurposing this ticket to keep track of out-of-the-box loongarch64 support.
@cheungxi Please see the above commit. Try the following snapshot selftest jar to see if junixsocket now works for you: https://oss.sonatype.org/content/repositories/snapshots/com/kohlschutter/junixsocket/junixsocket-selftest/2.10.1-SNAPSHOT/junixsocket-selftest-2.10.1-20240905.121638-4-jar-with-dependencies.jar
I've tried with openEuler-24.03-LTS, and that seems to work.
Please report back on this issue with your findings. Thanks for reporting!
Repurposing this ticket to keep track of out-of-the-box loongarch64 support.
@cheungxi Please see the above commit. Try the following snapshot selftest jar to see if junixsocket now works for you: https://oss.sonatype.org/content/repositories/snapshots/com/kohlschutter/junixsocket/junixsocket-selftest/2.10.1-SNAPSHOT/junixsocket-selftest-2.10.1-20240905.121638-4-jar-with-dependencies.jar
I've tried with openEuler-24.03-LTS, and that seems to work.
Please report back on this issue with your findings. Thanks for reporting!
Thank you very much !
I've tried with AOSC , and that also work (Selftest PASSED
).
I will use this porting compile mill source code.
when i run mvn -e -X clean install -target current
have a error
[ERROR] Error executing Maven.
java.io.FileNotFoundException: The specified user toolchains file does not exist: /home/loongson/tools/junixsocket/arget
at org.apache.maven.cli.MavenCli.toolchains (MavenCli.java:1121)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:277)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:203)
at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
at java.lang.reflect.Method.invoke (Method.java:580)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
[DEBUG] Shutting down adapter factory; available factories [file-lock, rwlock-local, semaphore-local, noop]; available name mappers [discriminating, file-gav, file-hgav, file-static, gav, static]
what is arget
? is target
?
mvn -e -X clean install -target current
is not a valid command. Where did you get that from?
You just specified a toolchain (-t
) named arget
...
You should be able to simply run "mvn clean install". (I will try that on loonarch64 later).
However, what I usually do is to crosscompile everything (all native platforms) from my Mac.
If you want to hack around the non-native code, you can simply skip the C part by running
mvn clean install -Duse-snapshots -rf :junixsocket-common
See https://kohlschutter.github.io/junixsocket/building.html for details
2.10.1 has just been released. Please test again, and re-open this ticket if necessary. Thanks again for reporting, @cheungxi !
Describe the bug I porting junixsocket to a new cpu architecture (loongarch)
ld cant find *.deps.so
To Reproduce Steps to reproduce the behavior:
./junixsocket-native/src/main/nar/aol.properties
add these code:mvn -e -X clean install >> a.txt
error message
then i
ls /home/loongson/tools/junixsocket/junixsocket-native/target/nar/obj/loongarch64-Linux-clang/
the output is :dont have *.nodeps.o