aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Bach <pascal.bach@siemens.com>2017-04-27 14:30:41 +0200
committerMartin Jansa <Martin.Jansa@gmail.com>2017-05-04 09:18:33 +0200
commit17f6775a14fa1b6831c79708bed51991e9c13b0d (patch)
treefa7a7c58d69256af5afdc252647f795aa5ee338a
parent3927abca048ef8e7d6979b5b359968d78ccbecb1 (diff)
downloadmeta-openembedded-contrib-17f6775a14fa1b6831c79708bed51991e9c13b0d.tar.gz
meta-openembedded-contrib-17f6775a14fa1b6831c79708bed51991e9c13b0d.tar.bz2
meta-openembedded-contrib-17f6775a14fa1b6831c79708bed51991e9c13b0d.zip
thrift: refactor recipe
- use release tarball instead of git - move libevent, python and glib into PACKAGECONFIG - add NOTICE file to copyright check - split into multiple packages - libthrift for libaries - thrift-compiler for compiler - thrift pulls in everything as before Signed-off-by: Pascal Bach <pascal.bach@siemens.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
-rw-r--r--meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb47
1 files changed, 40 insertions, 7 deletions
diff --git a/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb b/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb
index 905e5618d5..9baeed1692 100644
--- a/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb
+++ b/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb
@@ -3,18 +3,19 @@ DESCRIPTION = "A software framework, for scalable cross-language services devel
HOMEPAGE = "https://thrift.apache.org/"
LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=e4ed21f679b2aafef26eac82ab0c2cbf"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e4ed21f679b2aafef26eac82ab0c2cbf \
+ file://NOTICE;md5=115f49498b66b494b0472658f2bfe80b"
-DEPENDS = "thrift-native boost python libevent flex-native bison-native \
- glib-2.0 openssl"
+DEPENDS = "thrift-native boost flex-native bison-native openssl"
-SRC_URI = "git://git-wip-us.apache.org/repos/asf/thrift.git;protocol=https \
+SRC_URI = "http://mirror.switch.ch/mirror/apache/dist/thrift/${PV}/${BPN}-${PV}.tar.gz \
file://0001-Forcibly-disable-check-for-Qt5.patch \
file://0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch \
file://0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch \
"
-SRCREV = "61b8a29b0704ccd81b520f2300f5d1bb261fea3e"
-S = "${WORKDIR}/git"
+
+SRC_URI[md5sum] = "88d667a8ae870d5adeca8cb7d6795442"
+SRC_URI[sha256sum] = "b0740a070ac09adde04d43e852ce4c320564a292f26521c46b78e0641564969e"
BBCLASSEXTEND = "native nativesdk"
@@ -25,12 +26,44 @@ export STAGING_LIBDIR
export BUILD_SYS
export HOST_SYS
-EXTRA_OECMAKE = "-DWITH_QT4=OFF -DWITH_QT5=OFF -DBUILD_JAVA=OFF"
+EXTRA_OECMAKE = " \
+ -DBUILD_LIBRARIES=ON \
+ -DBUILD_COMPILER=ON \
+ -DBUILD_TESTING=OFF \
+ -DBUILD_EXAMPLES=OFF \
+ -DBUILD_TUTORIALS=OFF \
+ -DWITH_CPP=ON \
+ -DWITH_JAVA=OFF \
+ -DWITH_STATIC_LIB=ON \
+ -DWITH_SHARED_LIB=ON \
+ -DWITH_OPENSSL=ON \
+ -DWITH_QT4=OFF \
+ -DWITH_QT5=OFF \
+"
+
EXTRA_OECMAKE_append_class-native = "\
-DBUILD_TESTING=OFF -DBUILD_EXAMPLES=OFF -DWITH_CPP=OFF"
EXTRA_OECMAKE_append_class-nativesdk = "\
-DBUILD_TESTING=OFF -DBUILD_EXAMPLES=OFF -DWITH_PYTHON=OFF"
+PACKAGECONFIG ??= "libevent glib python"
+PACKAGECONFIG[libevent] = "-DWITH_LIBEVENT=ON,-DWITH_LIBEVENT=OFF,libevent,"
+PACKAGECONFIG[python] = "-DWITH_PYTHON=ON,-DWITH_PYTHON=OFF,python,"
+PACKAGECONFIG[glib] = "-DWITH_C_GLIB=ON,-DWITH_C_GLIB=OFF,glib-2.0 ,"
+
do_install_append () {
ln -sf thrift ${D}/${bindir}/thrift-compiler
}
+
+LEAD_SONAME = "libthrift.so.${PV}"
+
+# thrift packages
+PACKAGE_BEFORE_PN = "${PN}-compiler lib${BPN}"
+FILES_lib${BPN} = "${libdir}/*.so.*"
+FILES_${PN}-compiler = "${bindir}/*"
+
+# The thrift packages just pulls in some default dependencies but is otherwise empty
+RRECOMMENDS_${PN} = "${PN}-compiler lib${BPN}"
+ALLOW_EMPTY_${PN} = "1"
+RRECOMMENDS_${PN}_class-native = ""
+RRECOMMENDS_${PN}_class-nativesdk = ""