Hi,
I need to compile on Edison mraa (and upm) to work with node.js 0.12.x
To do this I followed mraa github build instructions (https://github.com/intel-iot-devkit/mraa/blob/master/docs/building.md https://github.com/intel-iot-devkit/mraa/blob/master/docs/building.md).
I starded installing a fresh Edison OS 2.1 and run configure_edison.
According to build doc I checked/installed the prerequisites:
http://swig.org/ SWIG 3.0.5: already installed
http://python.org/ python 2.7: already installed
http://cmake.org/ CMake 2.8.8: already installed
# install git
opkg install http://repo.opkg.net/edison/repo/core2-32/ http://repo.opkg.net/edison/repo/core2-32/http://repo.opkg.net/edison/repo/core2-32/git_2.0.1-r0_cor... git_2.0.1-r0_core2-32.ipk
# install node.js 10.2.x (intepreter plus dev)
opkg install http://repo.opkg.net/edison/repo/core2-32/ http://repo.opkg.net/edison/repo/core2-32/http://repo.opkg.net/edison/repo/core2-32/nodejs-npm_0.12.... nodejs-npm_0.12.7-r1_core2-32.ipk
opkg install http://repo.opkg.net/edison/repo/core2-32/ http://repo.opkg.net/edison/repo/core2-32/http://repo.opkg.net/edison/repo/core2-32/nodejs-dev_0.12.... nodejs-dev_0.12.7-r1_core2-32.ipk
Then I cloned mraa from github:
git clone --recursive https://github.com/intel-iot-devkit/mraa.git https://github.com/intel-iot-devkit/mraa.git
And finally I built mraa:
cd mraa/
mkdir build
cd build
cmake ..
make
Compile ends without errors, but when I try to use mraa from a nodejs program (like "Onboard blink" XDK sample) I got the that the mraa version is v0.7.2, ie the version installed in the Edison OS2.1, instead od v.0.9.x that I cloned from github.
It seems I missed something to enable node.js programs to use the mraa version that I just compiled.
Can you please help me? propanu any advise?
I also opened an issue on mraa github (https://github.com/intel-iot-devkit/mraa/issues/393 How compile mraa on Edison · Issue # 393 · intel-iot-devkit/mraa · GitHub)
Thanks
-max
Link Copied
Hi,
look at https://github.com/intel-iot-devkit/mraa/blob/master/docs/building.md https://github.com/intel-iot-devkit/mraa/blob/master/docs/building.md
After that you can install built files (into default path) by running:
sudo make installBR,
xbolshe
Hi,
look at https://github.com/intel-iot-devkit/mraa/blob/master/docs/building.md https://github.com/intel-iot-devkit/mraa/blob/master/docs/building.md
After that you can install built files (into default path) by running:
sudo make installBR,
xbolshe
Hi xbolshe,
I forgot this obvious step, too much Holidays :-)
Thanks
-max
To recap, if someone else need to compile mraa, after installing prerequisite:
cd mraa/
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr ..
make
make install
After this nodejs programs use the latest version of mraa, ie. v0.9.0.
For more complete information about compiler optimizations, see our Optimization Notice.