-
Notifications
You must be signed in to change notification settings - Fork 18
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
classpath 0.99 build issue #49
Comments
same / similar problem here. How can we start investigating this? |
I am quite a newbie in linux development and bitbake use, so it is difficult for me to find the source of the problem. |
Also using 4.8.1, but on Gentoo. Pasted my error log: |
The log is the same as mine. Looks like the problem comes form ecj-initial, which calls jamvm-initial. |
I thougt about missing dependencies, because there are many "No such file errors" (See line 499) |
according to this thread http://www.linuxquestions.org/questions/linux-software-2/prelink-configuration-error-fatal-error-ac_nonexistent-h-no-such-file-or-direct-939408/ it may not be a problem. |
Yeah youre right. I just saw that the problem is a segfaulting jamvm-initial |
There were similar problems in the past: http://www.mail-archive.com/openembedded-devel@lists.openembedded.org/msg27428.html |
looks like your problem is not exactly the same as mine. In the config.log I do not get a segfault but this error : |
Acutally this doesnt make it better! :D I am playing around with bb files, but no luck, yet! :( |
can you run a hello world program with your jamvm initial? if no, which message do you get? |
I am getting a: Aborting the VM -- couldn't allocate the heap: Cannot allocate memory but dont know if I do it the right way. What steps do you follow to test it with a simple HelloWorld? |
I found hello.jar here : http://code.google.com/p/kmttg/downloads/detail?name=hello.jar&can=4&q= then : "path-to-jamvm-initial"/jamvm-initial -jar hello.jar |
jamvm-initial -Xmx512m -jar hello.jar ” terminated by signal SIGSEGV (Address boundary error) |
ok, investigating in jamvm source code to find the function that fails |
can you explain how you got this log? I never used execve and would be interested in doing the same test on my computer |
see "man strace" ;) I configured my yocto/oe environment to use my local crossdev arm toolchain, instead of the internal on. will check if this changes somethin. But since I am on battery now, I have to test it later. |
Hi, sorry for the late answer. Yes it is possible that newer gcc miscompiles jamvm-initial. I had no time yet to investigate it. It worked for me with ubuntu 10.12 at least. I could possible be true too, that I tested some patches |
Ubuntu 10.12 does not exist, 10.10, or 12.10 maybe? |
Sorry my fault, 12.10 I meant. |
I tired some random commits, going back to somewhere in 2012. Everytime the same error occures. |
I think I made a step into the right direction. If I change the Compiler on my host system (not the GCCVERSION in TCMODE) to 4.7 the failing package is icedtea7-native_2.1.3.bb Ill try with icedtea 6 now. Maybe this will work. Reporting soon... |
I have a working build with gcc4.7 hostcompiler AND GCCVERSION set to 4.7. |
Maybe we should consider upgrading the packages to most recent version. I see that openjdk-7 packages are around 5 months old. @woglinde what is you plan with that? How can I contact you? Maybe you can give me a short introsuction how to update the receipt. :)) |
hi, any news on the topic? |
sorry for the silly questions but, how can you rebuild a package from scratch (do_configure...) after changing parameters? |
Hi VVette, If you want to clean the current configuration of your recipe you only need to call 'bitbake -c clean ' I'm able to build the recipie on my machine/configuration:
make sure you have enough resources on your machine. The build requires a lot of memory (and/or swap which makes the build pretty slow)! sometimes it is a good idea to build icedtea7-native before building openjdk (if you have parallel builds): |
GCCVERSION = "4.7%" fits better ;) (this will allow any 4.7 series gcc) |
The problem here is not the resulting compiler in oe, but the host-compiler of your distribution. To work around the failing icedtea7-native edit the openjdk7 recipe and force it to use icedtea6-native too. |
on my hosts, jamvm-initial is the segfaulting binary. how to switch to the hosts jdk? i really wonder about why on one of my boxes the compilation succeedes... |
I'm still investigating/looking for workarounds. I've tried to reproduce this error on a Ubuntu 12.04. and the do_configuration went through. It seems to me that everything > Ubuntu 12.04 has this issue. Can you please try Ubuntu 12.04 to verify this assumption? |
No, I cannot confirm this. I have the same problem with ubuntu 12.04 |
I found a workaround that avoids the usage of jamvm during the initial configuration. It is only used during the initialization phase (do_configure). As a workaround I'm using the java version of my host machine (apt-get install openjdk-7-jdk). In order to do that you need to replace the following lines in the build/tmp/sysroots/x86_64-linux/usr/bin/java-initial script (this can be also done in a bitbake append file of the jamvm-initial recipe) replace the line: jamvm-initial |
Do you already wrote a bbappend file? Ill test it later on today! |
Getting another error now: |
As the error says install libXtst with bitbake libXtst. |
Compiles fine now, but didnt have time for testing my images.Will report then. |
Great! I dont get the segfault on a fresh version of ubuntu 12.04.3 (without any updates) @woglinde: does it make sense to add a fallback in the java-initial that uses the java version of the host pc? What do you think? |
I can confirm that I am also having this issue, I would prefer not to have to munge files in the tmp directory, as it breaks the deterministic nature of a build... log.do_configure http://ix.io/9qO |
Hi Jack, I'm not saying that we should go ahead with this workaround (changing the java-init by hand), I just wanted to know whether jamvm is the root cause or not. So we need to find a real solution for the segfault issue of jamvm. I had a brief look on jamvm and i realized that the meta-java layer is using a pretty old version of jamvm (1.4.5). I'm going to use the current version of jamvm (1.5.4) which might work. I will keep you in touch. |
Would be worth a try! :D There are some other outdated packages I think. Maybe we should analyze and keep them up to date. I am thinking of using this for production in future. So better have no java exploits in my image! ;) |
So I have tried bumping the jamvm version and I start hitting problems with not being able to find classes in classpath: | configure:24760: /mnt/seaRaid/Projects/oe-core.git/beaglebone-ben/tmp-eglibc/sysroots/x86_64-linux/usr/bin/ecj-initial -nowarn -source 1.5 -target 1.5 Object.java If there are any suggestions on how I might fix this I would be open to suggestions. If someone wants me to punt my changes over the wall I can put them up. |
you need to specify the bootclasspath. this can be done in a do_configure_prepand export BOOTCLASSPATH = "${STAGING_DATADIR_NATIVE}/jamvm-initial/classes.zip:${STAGING_DATADIR_NATIVE}/classpath-initial/glibj.zip" |
That seemed to get me a bit further but now the invocation of the compile just fails. config.log http://ix.io/9sk |
could you please provide your changes in a separate fork? Update: (see https://github.com/woglinde/meta-java/blob/master/recipes-core/jamvm/files/java-initial) |
https://github.com/jackmitch/meta-java/tree/updates it's preliminary, and rough so bear that in mind. |
Thanks. Looks pretty similar to my attempts. I have just one suggestions; be careful with mixing jamvm-initial and jamvm-native. Currently both will be installed in the same folder (usr/share/jamvm). I have also commited my changes (https://github.com/toolmmy/meta-java/commit/b2822794952c0348a10213acf82857d99b8b136b) . Bootstrap looks fine, but I'm getting the following error (at least no segfault): http://pastebin.com/EquAkXaa (configure:24760) |
Hm intressting that jamvm 1.5 can be compiled with jikes. I thought it would not work, but I never tried it. The processs was to build slowly up the apis:
PS: I hope I will find some time during christmas holidays to put meta-java back in a reliable state. |
Nice to see a progress here. I hope we can get this in a working state, so that java makes fun again with openembedded! :) |
Since upgrading my build host from openSUSE 12.3 to 13.1 i hit the same problem. So for us this is really a critical issue. |
There is a patch posted to the oe-dev list which relates to meta-java, it touchest classpath but I don't think it will solve the problem. Is maybe worth merging anyway though. https://www.mail-archive.com/openembedded-devel@lists.openembedded.org/msg34182.html |
Hi, I have worked on it over the holidays and will commit something this evening, fornatly cacao 0.98 works after some tweaking and can replace jamvm-initial, which needs more work to get it working again. |
Stuff is pushed, so I am looking forward to close the issue soon. |
Hi woglinde, |
Looks better now and is working for me! |
This fixes a classpath-0.99 build issue on build hosts with newer linux distributions. see woglinde/meta-java#49 Signed-off-by: Steffen Sledz <sledz@dresearch-fe.de>
problem is fixed for now |
can someone point me to woglinde's patch? I am having similar issue now. |
classpath do_configure fails with following error :
configure:24669: ecj-initial -nowarn -source 1.5 -target 1.5 Object.java
Exception occurred while VM initialising.
java/lang/NullPointerException
Thank you for your help on this topic
The text was updated successfully, but these errors were encountered: