Skip to content

Instantly share code, notes, and snippets.

@trondeau
Last active November 20, 2015 21:15
Show Gist options
  • Save trondeau/6ccf4a4c06a4e88d6060 to your computer and use it in GitHub Desktop.
Save trondeau/6ccf4a4c06a4e88d6060 to your computer and use it in GitHub Desktop.
Notes on Compiling Thrift with OE SDR
Ran ./bootstrap before setting OE environment
- Looking for some Perl support (File/Find.pm) not in the nativesdk
-- it is in the target sysroot
**********************************************************************
**********************************************************************
Patched files to turn off test support in C:
diff --git a/lib/c_glib/Makefile.am b/lib/c_glib/Makefile.am
index 153d14b..c229fd3 100755
--- a/lib/c_glib/Makefile.am
+++ b/lib/c_glib/Makefile.am
@@ -17,7 +17,7 @@
# under the License.
#
AUTOMAKE_OPTIONS = serial-tests
-SUBDIRS = . test
+SUBDIRS = . #test
pkgconfigdir = $(libdir)/pkgconfig
**********************************************************************
**********************************************************************
Turned off Python3 support; it was finding host's python3 binary:
diff --git a/configure.ac b/configure.ac
index 37f19c9..7b532ee 100755
--- a/configure.ac
+++ b/configure.ac
@@ -288,12 +288,12 @@ AM_CONDITIONAL(WITH_PYTHON, [test "$have_python" = "yes"])
# Find "python3" executable.
# It's distro specific and far from ideal but needed to cross test py2-3 at once.
-if test "x$have_python" = "xyes"; then
- AC_PATH_PROG([PYTHON3], [python3])
- if test "x$PYTHON3" != "x" && test "x$PYTHON3" != "x:" ; then
- have_py3="yes"
- fi
-fi
+#if test "x$have_python" = "xyes"; then
+# AC_PATH_PROG([PYTHON3], [python3])
+# if test "x$PYTHON3" != "x" && test "x$PYTHON3" != "x:" ; then
+# have_py3="yes"
+# fi
+#fi
AM_CONDITIONAL(WITH_PY3, [test "$have_py3" = "yes"])
AX_THRIFT_LIB(perl, [Perl], yes)
**********************************************************************
**********************************************************************
./configure --prefix=/usr --host=armv7a-none-linux --without-libevent --without-zlib --with-sysroot=/opt/oecore-e310/sysroots/armv7ahf-vfp-neon-oe-linux-gnueabi --with-cpp --with-python --disable-tests --disable-tutorial --disable-coverage --disable-boostthreads --without-php --without-nodejs --without-java --enable-shared
make
make install DESTDIR=/oecore/sysroot/armdir
In another checkout of thrift (last I checked, it didn't support VPATH builds), we need to build the native (x86) support:
./configure --prefix=/usr --without-libevent --without-zlib --with-cpp --with-python --disable-tests --disable-tutorial --disable-coverage --disable-boostthreads --without-php --without-nodejs --without-java --enable-shared
make
make install DESTDIR=/oecore/sysroot/x86dir
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment