Community
cancel
Showing results for 
Search instead for 
Did you mean: 
PMora5
New Contributor I
1,703 Views

mraa failed on Yocto build with split layers

Hello,

I tried to follow this tutorial https://software.intel.com/en-us/blogs/2015/03/04/creating-a-yocto-image-for-the-intel-galileo-board... IoT - Creating a Yocto image for the Intel® Galileo board using split layers | Intel® Software but it crashs when it comes to do_compile MRAA (log below).

| cd /home/pksm/iotdk/newBld/tmp/work/i586-poky-linux/mraa/0.8.0-r0/build/src/java && /home/pksm/iotdk/newBld/tmp/sysroots/quark/usr/lib/jvm/java-8-openjdk/bin/javac *.java -d /home/pksm/iotdk/newBld/tmp/work/i586-poky-linux/mraa/0.8.0-r0/build/src/java

| /bin/sh: 1: /home/pksm/iotdk/newBld/tmp/sysroots/quark/usr/lib/jvm/java-8-openjdk/bin/javac: not found

| make[2]: *** [src/java/libmraajava.so] Error 127

| make[2]: Leaving directory `/home/pksm/iotdk/newBld/tmp/work/i586-poky-linux/mraa/0.8.0-r0/build'

| make[1]: *** [src/java/CMakeFiles/mraajava.dir/all] Error 2

| make[1]: *** Waiting for unfinished jobs....

| make[2]: Leaving directory `/home/pksm/iotdk/newBld/tmp/work/i586-poky-linux/mraa/0.8.0-r0/build'

| /home/pksm/iotdk/newBld/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_progress_report /home/pksm/iotdk/newBld/tmp/work/i586-poky-linux/mraa/0.8.0-r0/build/CMakeFiles 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83

| [ 58%] Built target mraajs

| make[1]: Leaving directory `/home/pksm/iotdk/newBld/tmp/work/i586-poky-linux/mraa/0.8.0-r0/build'

| make: *** [all] Error 2

| ERROR: oe_runmake failed

| WARNING: exit code 1 from a shell command.

| ERROR: Function failed: do_compile (log file is located at /home/pksm/iotdk/newBld/tmp/work/i586-poky-linux/mraa/0.8.0-r0/temp/log.do_compile.28016)

ERROR: Task 669 (/home/pksm/iotdk/meta-intel-iot-middleware/recipes-devtools/mraa/mraa_0.8.0.bb, do_compile) failed with exit code '1'

FYI, I had to add a meta-java layer for openjdk8 and my host machine is Ubuntu 12.04.

Thanks!

0 Kudos
7 Replies
asss
Valued Contributor II
49 Views

Hi,

by default Java compilation is disabled in MRAA.

If you enable Java in MRAA (or any other option), need to add required components like OpenJDK or Oracle's JDK.

Look at MRAA documentation: https://github.com/intel-iot-devkit/mraa/blob/master/docs/building.md# building-java-bindings mraa/building.md at master · intel-iot-devkit/mraa · GitHub

BR,

xbolshe

PMora5
New Contributor I
49 Views

Hi xbolshe,

I did not edit mraa recipe, but still on my very first attempt, I was required to add openjdk8 (that's why the extra meta-java layer).

Can't figure out why

Best,

Paula

idata
Community Manager
49 Views

Hi Paula,

 

 

Do you still need help with this? Or have you been able to build the Galileo image with mraa?

 

 

Also, is there any reason why you need to build mraa on your image? I mean, you should be able to install it from its repo ( http://iotdk.intel.com/repos/).

 

 

-Peter.
PMora5
New Contributor I
49 Views

Hi Peter,

Thank you for asking. Yes, I still need help with this.

I really did not want to add Java to my image, but it seems is a dependency of mraa. Or maybe I'm doing something wrong.

My goal with this image is to embed all the files of my project; facilitating its distribution.

Best,

Paula

idata
Community Manager
49 Views

I found that really strange. I understand what you need to achieve, right now two things come to mind. The first would be for you to build an older version of mraa that doesn't include Java as a workaround, it would have to be version 0.6.2 or lower. Nevertheless, I understand that using such an old version could bring issues. So, the second thing I can think of is that you report this as an issue in https://github.com/intel-iot-devkit/mraa/issues, that way the developers could provide you a suggestion that could be more accurate for this situation.

 

 

-Peter.
PMora5
New Contributor I
49 Views

Thanks Peter for your suggestions. Just one thing...when you tried to build using split layers did you have this problem?

Thanks

idata
Community Manager
49 Views

I did not have this issue when I tried it. Nevertheless, I did it quite a while ago, with a previous version of mraa that might have not included Java. Therefore, I believe the best option would be to get their help.

 

 

-Peter.
Reply