# Patches and instructions for adding python and numpy to GNU Radio for android

**URL:** <https://www.ruby-forum.com/t/patches-and-instructions-for-adding-python-and-numpy-to-gnu-radio-for-android/242259>\
**Category:** GNU Radio\
**Created:** [June 10, 2015, 1:14am UTC](https://www.ruby-forum.com/t/patches-and-instructions-for-adding-python-and-numpy-to-gnu-radio-for-android/242259 "2015-06-10T01:14:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Detlef\_R](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/58f4c7/32.png) [@Detlef\_R](https://www.ruby-forum.com/u/Detlef_R)\
**Post date:** [June 10, 2015, 1:14am UTC](https://www.ruby-forum.com/t/patches-and-instructions-for-adding-python-and-numpy-to-gnu-radio-for-android/242259/1 "2015-06-10T01:14:45Z")

</div>

As previously mentioned, I’ve been working on adding python and numpy to  
the existing GNU Radio android version (GrAnd). I’ve named the  
resulting Frankensteinian creation “GrAndPy”.

The goals of the project (that have been successfully achieved so far)  
were:  
a) build using a solid proper foundation. The existing sl4a/py4a  
projects  
can be (with suitable patches) used to build an ARM python  
executable  
that’s linked -fPIE (which is required for Android 5.0). The  
python  
executable runs as a standard android native-code executable with  
the  
necessary JNI system hooks. All standard Linux functions (in  
particular  
shared libraries) are supported in this environment.  
b) versions of blas, lapack, and numpy cross compiled for arm-android,  
with numpy installed as an ordinary python module  
c) a build of GNU Radio built with the ENABLE\_PYTHON and ENABLE\_SHARED  
options.  
d) No Eclipse, No Java . I hate Java.

I’ve collected all the patches as well as three README files and put  
together  
a repository of all current info. It’s an exercise in building  
projects, but  
the result has been and is worth the effort!! I’ve successfully tested  
a non-  
trivial GR app (OP25) in console mode under android, which would not be  
possible without both python and numpy…

The repo URL is [GitHub - mmhhpp/grandpy: patches & instructions for building python and numpy for GNU Radio for android](https://github.com/mmhhpp/grandpy) . Since there is no  
new code, only patches to get things to build, the only parts of this  
collection that are copyrighted are the README files which are under a  
CC sharing license… One tip not in the docs is that it seems life  
will beharder for you on a 64 bit build host, so use a 32 bit (i686)  
distro even if yourbuild host is on 64-bit hardware.

Comments / feedback welcome!

Best Regards

Max

p.s. I’m currently trying to integrate the above with QT5 (sorry,  
Balint).  
If anyone has experience with GR and QT5 as opposed to 4, please let me  
know…
