summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatúš Kukan <matus.kukan@gmail.com>2013-03-14 17:05:15 +0100
committerMatúš Kukan <matus.kukan@gmail.com>2013-03-14 19:43:24 +0100
commit63a13216e35228f8a703f9f5d5823fc23e03bb2d (patch)
tree82bd94548e32d5c1a3eaf3661251d527d59c7c5c
parentabccbae3d8376d7f8b79d517a758daeac08af003 (diff)
mention cross-compilation for Raspbian possibility in README.cross
Change-Id: I977764882080bd9c57dae2fc7bd473f70a0b4299
-rw-r--r--README.cross65
1 files changed, 63 insertions, 2 deletions
diff --git a/README.cross b/README.cross
index be22b2f5b6ed..b5624b779964 100644
--- a/README.cross
+++ b/README.cross
@@ -1,8 +1,8 @@
Cross-compiling LibreOffice
===========================
-Cross-compilation work has been done, to various degrees, for four
-platforms: Windows, iOS, Android and PowerPC Mac OS X.
+Cross-compilation work has been done, to various degrees, for platforms:
+Windows, iOS, Android, PowerPC Mac OS X, Raspbian.
General
@@ -406,3 +406,64 @@ CC_FOR_BUILD=ccache /Xcode3/usr/bin/gcc-4.0
CXX_FOR_BUILD=ccache /Xcode3/usr/bin/g++-4.0
--build=i386-apple-darwin10.7.0
--host=powerpc-apple-darwin10
+
+
+Raspbian
+--------
+
+It's now possible to cross-compile LibreOffice for Rapsberry Pi running Raspbian.
+You will need Raspbian's pkg-config files and system libraries to build against.
+Available at http://dev-www.libreoffice.org/src/raspbian_rootfs.tar.bz2
+$ wget http://dev-www.libreoffice.org/src/raspbian_rootfs.tar.bz2
+$ tar -axf raspbian_rootfs.tar.bz2
+
+You can build cross-compiler yourself or get the executables here:
+$ git clone git://github.com/raspberrypi/tools
+tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian is known to work.
+
+Then create pkg-config wrapper, something like:
+$ cat > pkg-config-wrapper-host << _EOF
+#!/bin/sh
+
+SYSROOT=<path-to-raspbian_rootfs>
+
+export PKG_CONFIG_DIR=
+export PKG_CONFIG_LIBDIR=\${SYSROOT}/usr/lib/pkgconfig:\${SYSROOT}/usr/lib/arm-linux-gnueabihf/pkgconfig:\${SYSROOT}/usr/share/pkgconfig
+export PKG_CONFIG_SYSROOT_DIR=\${SYSROOT}
+
+exec pkg-config "\$@"
+_EOF
+$ chmod +x pkg-config-wrapper-host
+This does not work with pkg-config 0.23. 0.26 is known to work.
+
+And you are ready to build with autogen.lastrun similar to:
+
+PKG_CONFIG=<path-to-pkg-config-wrapper-host>
+CC=<path-to-arm-linux-gnueabihf-gcc> --sysroot=<path-to-raspbian_rootfs>
+CXX=<path-to-arm-linux-gnueabihf-g++> --sysroot=<path-to-raspbian_rootfs>
+--build=x86_64-unknown-linux-gnu
+--host=arm-unknown-linux-gnueabihf
+--disable-linkoo
+--without-doxygen
+--disable-gnome-vfs
+--enable-python=system
+PYTHON_CFLAGS=-I<path-to-raspbian_rootfs>/usr/include/python2.7
+PYTHON_LIBS=-lpython2.7
+--with-java
+JAVAINC=-I<path-to-raspbian_rootfs>/usr/lib/jvm/java-6-openjdk-armhf/include
+JAVALIB=-L<path-to-raspbian_rootfs>/usr/lib/jvm/java-6-openjdk-armhf/jre/lib/arm
+--with-system-cairo
+--with-system-cppunit
+--with-system-icu
+--with-system-neon
+--with-system-nss
+--with-system-openldap
+--with-system-openssl
+--with-system-redland
+
+Finally, when you are ready to run the binaries in Raspbian,
+you may need to get more system libraries.
+Update your /etc/apt/sources.list as described in
+http://www.raspbian.org/RaspbianRepository and then:
+$ sudo apt-get update
+$ sudo apt-get build-dep libreoffice