protobuf: add python support

The compiler generated by Google Protocol Buffers currently includes
support for Python bindings.  However, currently the python files
required to use the generated files are not included on the system.
This fix installs the python header files using python setup-tools
after the compiler is built.

Signed-off-by: Keith Holman <Keith.Holman@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
This commit is contained in:
Keith Holman 2014-08-20 16:46:08 -04:00 committed by Bruce Ashfield
parent 8bbaf80f47
commit 7b424fa19e

View File

@ -13,8 +13,22 @@ PR = "r0"
SRC_URI[md5sum] = "b751f772bdeb2812a2a8e7202bf1dae8"
SRC_URI[sha256sum] = "c55aa3dc538e6fd5eaf732f4eb6b98bdcb7cedb5b91d3b5bdcf29c98c293f58e"
SRC_URI = "http://protobuf.googlecode.com/files/protobuf-${PV}.tar.gz"
PYTHON_SRC_DIR="python"
EXTRA_OECONF += " --with-protoc=echo"
inherit autotools
inherit autotools setuptools
do_compile() {
# Compile protoc compiler
base_do_compile
}
do_install() {
# Install protoc compiler
autotools_do_install
# Install header files
cd "${PYTHON_SRC_DIR}"
distutils_do_install
}
BBCLASSEXTEND = "native nativesdk"