summaryrefslogtreecommitdiff
path: root/configure-cell-cross
diff options
context:
space:
mode:
authoreb <eb@221aa14e-8319-0410-a670-987f0aec2ac5>2007-11-10 01:03:04 +0000
committereb <eb@221aa14e-8319-0410-a670-987f0aec2ac5>2007-11-10 01:03:04 +0000
commitbf89a84441f33f17f29ce238d9920f87a4d3b540 (patch)
treeb0e7e61df1d018b7132719bdaedba6012873fbe2 /configure-cell-cross
parent83200c22baaf6d2619035966bf8da1d662d8a9de (diff)
Merged -r6847:6850 from eb/trial-merge into trunk. This changeset
contains the modifications required to cross-compile GNU Radio for the Cell processor. For directions, see CrossCompilingForCell git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@6852 221aa14e-8319-0410-a670-987f0aec2ac5
Diffstat (limited to 'configure-cell-cross')
-rwxr-xr-xconfigure-cell-cross53
1 files changed, 53 insertions, 0 deletions
diff --git a/configure-cell-cross b/configure-cell-cross
new file mode 100755
index 0000000000..48a7c6db4d
--- /dev/null
+++ b/configure-cell-cross
@@ -0,0 +1,53 @@
+#!/bin/bash
+
+#
+# Before trying to use this script, please follow the instructions at
+# http://gnuradio.org/trac/wiki/CrossCompilingForCell
+#
+
+scriptdir=`dirname $0`
+
+prefix=
+for arg in "$@"
+do
+ case $arg in
+ --prefix=*)
+ prefix=${arg#--prefix=}
+ ;;
+ esac
+done
+
+if test x$prefix = x
+then
+ echo "usage: $0 --prefix=PREFIX [configure options...]" 1>&2
+ exit 1
+fi
+
+
+arch=ppu
+cell_root=/mnt/cell-root
+python_version=2.5
+# compiler_includes="-I${cell_root}/usr/include -I${cell_root}/usr/local/include -I${cell_root}/usr/lib/gcc/ppu/4.1.1/include -I${cell_root}/usr/lib/gcc/ppu/4.1.1/include/c++"
+compiler_includes="-I${cell_root}/usr/include"
+
+$scriptdir/configure \
+ CC=${arch}32-gcc \
+ CXX=${arch}32-g++ \
+ AR=${arch}-ar \
+ NM=${arch}-nm \
+ RANLIB=${arch}-ranlib \
+ STRIP=${arch}-strip \
+ F77=false \
+ CPPFLAGS="$compiler_includes" \
+ LDFLAGS="-L${cell_root}/lib -L${cell_root}/usr/lib" \
+ PYTHON_CPPFLAGS=-I${cell_root}/usr/include/python${python_version} \
+ PKG_CONFIG_PATH=${cell_root}/usr/lib/pkgconfig:${cell_root}/usr/local/lib/pkgconfig \
+ --host=powerpc64-unknown-linux-gnu \
+ --prefix=$prefix \
+ --with-pythondir=$prefix/lib/python${python_version}/site-packages
+
+
+# Hack the libtool script so that it doesn't code an --rpath flag into anything
+
+#sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
+#sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool