User Tools

Site Tools


cross-compiler-gentoo

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

cross-compiler-gentoo [2016/07/03 13:52]
didier update ARM toolchain
cross-compiler-gentoo [2016/07/03 19:58] (current)
didier add deps for Python binding on ARM
Line 156: Line 156:
 </​code>​ </​code>​
 It works! :-) It works! :-)
 +
 +==== Prepare librohc dependencies ====
 +
 +=== For tests ===
 +In order to build and run librohc tests, install libpcap and cmocka for the ARM target:<​code>​
 +# ARCH=arm arm-softfloat-linux-gnueabi-emerge -av libpcap cmocka
 +</​code>​
 +
 +=== For Python binding ===
 +In order to build and run the Python module, install Python 3.5 for the host target (Python 3.3 and 3.4 seem not to cross-compile fine at the moment on Gentoo Linux):<​code>​
 +# USE=-ncurses ACCEPT_KEYWORDS=~amd64 emerge -av dev-lang/​python:​3.5
 +# eselect python list --python3
 +# eselect python set --python3 <id of python 3.5>
 +</​code>​
 +
 +In order to build and run the Python module, install Python for the ARM target:<​code>​
 +# # eselect requires ncurses that fails to cross-compile,​ and it is not very useful,
 +# # so let's emerge think it is installed
 +# echo '​app-admin/​eselect-1.4.6'​ >> /​usr/​arm-softfloat-linux-gnueabi/​etc/​portage/​profile/​package.provided
 +# # disable ncurses and readline support for python since ncurses fails to cross-compile
 +# USE="​-ncurses -readline"​ \
 +  ARCH=arm arm-softfloat-linux-gnueabi-emerge -av dev-lang/​python:​3.5
 +# eselect python list --python3
 +# eselect python set --python3 <id of previous python version>
 +</​code>​
 +
 +Then, install the Python'​s future extension:<​code>​
 +# echo '​=dev-python/​future-0.15.2 **' >> /​usr/​arm-softfloat-linux-gnueabi/​etc/​portage/​package.accept_keywords
 +# ARCH=arm PYTHON_TARGETS="​python3_5"​ arm-softfloat-linux-gnueabi-emerge -av1 dev-python/​future
 +</​code>​
  
  
cross-compiler-gentoo.txt · Last modified: 2016/07/03 19:58 by didier