protobuf: respect autotools build/source split

Tweak the ptest build rule to look for artifacts in the build directory
instead of source, since build and source are split on the latest oe-core.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
This commit is contained in:
Bruce Ashfield 2014-08-22 15:40:23 -04:00
parent d6ae4fc295
commit a2fab33ace

View File

@ -34,12 +34,14 @@ do_compile_ptest() {
# Modify makefile to use the cross-compiler # Modify makefile to use the cross-compiler
sed -e "s|c++|${CXX}|g" -i "${S}/${TEST_SRC_DIR}/Makefile" sed -e "s|c++|${CXX}|g" -i "${S}/${TEST_SRC_DIR}/Makefile"
mkdir -p "${B}/${TEST_SRC_DIR}"
# Add the location of the cross-compiled header and library files # Add the location of the cross-compiled header and library files
# which haven't been installed yet. # which haven't been installed yet.
cp "${S}/protobuf.pc" "${S}/${TEST_SRC_DIR}/protobuf.pc" cp "${B}/protobuf.pc" "${B}/${TEST_SRC_DIR}/protobuf.pc"
sed -e 's|Cflags:|Cflags: -I${S}/src|' -i "${S}/${TEST_SRC_DIR}/protobuf.pc" sed -e 's|Cflags:|Cflags: -I${S}/src|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
sed -e 's|Libs:|Libs: -L${S}/src/.libs|' -i "${S}/${TEST_SRC_DIR}/protobuf.pc" sed -e 's|Libs:|Libs: -L${B}/src/.libs|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
export PKG_CONFIG_PATH="${S}/${TEST_SRC_DIR}" export PKG_CONFIG_PATH="${B}/${TEST_SRC_DIR}"
# Save the pkgcfg sysroot variable, and update it to nothing so # Save the pkgcfg sysroot variable, and update it to nothing so
# that it doesn't append the sysroot to the beginning of paths. # that it doesn't append the sysroot to the beginning of paths.