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
arm32 builds on armv6 pi fail with Atomic store(jlong) unsupported #715
Comments
@DanielMartensson Ohhhhhh this makes sense. You've compiled a feature from a runtime which arm32v6 doesn't support. I think you need to compile the same program on your Pi and see what happens. This is a rare case where WORA is broken. |
@karianna I already compile my program by using Project->Clean in Eclipse IDE. I know that should be standing "Compile only", but in this IDE, it's standing "Clean". The reason why I can't run the application on my Ubuntu computer (64-bit), is because Pi4J (a library included on my application) cannot run on other computers that is not a "Pi"-computer such as NanoPi, RaspberryPi, BananaPi and so on. One problem more, Eclipse IDE on Raspberry Pi will slow down my Raspberry Pi so mutch that it would take hours to compile. That's the reason why I compile on Ubuntu -> USB stick -> Raspberry Pi. Compiling Java code on Raspberry Pi, no matter what IDE I have, takes to long time. Is it not possible to make fix the WORA on OpenJDK 10.0.2+13 ? To run this application. WiringPi MUST be installed on the Raspberry Pi.
WiringPi is a C-library. Pi4J is a Java library who can communicate with WiringPi via JNI. |
@DanielMartensson Can you compile without eclipse? e.g. on the Command line using Ant/Maven et al? |
I think so. Well, I got lot's of jar files included and I don't know how to include them when I do the "javac" command in the terminal at my Pi. Have you download the package? I always using an IDE when I compile. Do you have any suggestion how to compile with that amount of jars included? |
@karianna I will try to compile a simple hello world project. Or do I need to use the same libraries like Pi4J? |
IIRC in eclipse, you'll have a file called
|
What if I have multiple of classes? In different folders too.
? |
@karianna Can you compile this and then upload it so I can run it with AdoptOpenJDK 10.0.2+13 ? It need to be a executable jar file. |
I don't have the appropriate platform to compile this on. But from your command line on the Pi you can run:
|
Can't even compile due to the same message above "Atomic store(jlong) unsupported in this platform". |
OK - let me try to find an ARM expert. |
You can join us on adoptopenjdk.net/slack.html and jump on the #arm channel |
For what it's worth I can replicate this on my Pi Zero-W |
@sxa555 Try to write
And see if you have the same CPU as me does:
|
Yeah the Zero-W is more or less the same as an original model A I think but with the wifi adapter added so all three lines are identical to what you've posted |
Hi, java -XX:-AssumeMP -jar JoystickStepperLCD.jar Alternatively, could you try running a JDK build from https://ci.adoptopenjdk.net/view/ev3dev/job/openjdk11_build_ev3_linux/ ? We are patching OpenJDK to run on an ARMv5 processor in a LEGO Mindstorms kit and it seems to work well so far. |
It worked! I need to use sudo to control the GPIO pins. I got the OpenJDK 8 installed, but I just change the JAVA_HOME to AdoptOpenJDK instead.
When I uninstall OpenJDK 8 I cannot find the command java when I run:
If I don't use the sudo command, I got the same as above:
Anyway! The OpenJDK 10.0.2 seems to work at 32-bit ARM. Does anyone know how I can bypass the sudo command and still got rights to use GPIO pins? |
Hi Daniel, could you show the output of cat /proc/cpuinfo on your board? I'm curious why -AssumeMP seems to have made a difference. |
|
Oh, ok. Well that fits then :) |
Do you know what's the solution for the issue why I need to use -XX:-AssumeMP to make it work? Will Oracle use AdoptOpenJDK for it's own purposes? I'm mean, OpenJDK 8 is the last version from Oracle who support ARM. |
OpenJDK 12ea detects multiprocessor systems on the fly, so that probably the best solution. Otherwise, we have a source patch that disables AssumeMP in code: |
Closing this as resolved - a document is being worked on our ARM channel in slack |
Hello!
I have Eclipse on my Ubuntu where I have installed OpenJDK 8 for running Eclipse IDE.
In Eclipse I use the Linux 64 OpenJDK-10.0.2+13 as compiler. I also use arm32 OpenJDK-10.0.2+13 on Raspberry Pi B+ v1.2
I installed the OpenJDK-10.0.2+13 on Raspberry Pi B+ v1.2 by using:
When I run my java program I have compile from Eclipse IDE. I got this error:
You can download the JoystickStepperLCD.jar from JoystickStepperLCD.zip where are located at:
https://github.com/DanielMartensson/Embedded-Systems/tree/master/JoystickStepperLCD
The text was updated successfully, but these errors were encountered: