aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorClement Dransart <clement.dransart@awtce.be>2016-06-06 16:02:04 +0200
committerClement Dransart <clement.dransart@awtce.be>2016-06-17 18:26:58 +0200
commit7045490a70d5e3968ca79074c6ab370830a5ccda (patch)
tree01a6b9f73e55d128a5b252661647692b09a17579
parent9d72380c1d50d0c3469b85c3a43fe612b5ee1dd9 (diff)
downloadmeta-ivi-7045490a70d5e3968ca79074c6ab370830a5ccda.tar.gz
meta-ivi-7045490a70d5e3968ca79074c6ab370830a5ccda.tar.bz2
meta-ivi-7045490a70d5e3968ca79074c6ab370830a5ccda.zip
common-api: Fix installation of pkgconfig & cmake files
Use ${libdir} and ${baselib} to ensure correctness of cmake flags. Reuse the INSTALL_LIB_DIR variable for the destination of the pkgconfig file as well as cmake directory. This fixes the build under Yocto for 64-bit targets. Signed-off-by: Clement Dransart <clement.dransart@awtce.be>
-rw-r--r--meta-ivi/recipes-extended/common-api/common-api-c++-dbus/0001-common-api-dbus-runtime-replace-hard-coded-lib-dir-b.patch36
-rw-r--r--meta-ivi/recipes-extended/common-api/common-api-c++-dbus_3.1.5.bb4
-rw-r--r--meta-ivi/recipes-extended/common-api/common-api-c++/0001-common-api-runtime-replace-hard-coded-lib-dir-by-var.patch36
-rw-r--r--meta-ivi/recipes-extended/common-api/common-api-c++_3.1.5.bb4
4 files changed, 80 insertions, 0 deletions
diff --git a/meta-ivi/recipes-extended/common-api/common-api-c++-dbus/0001-common-api-dbus-runtime-replace-hard-coded-lib-dir-b.patch b/meta-ivi/recipes-extended/common-api/common-api-c++-dbus/0001-common-api-dbus-runtime-replace-hard-coded-lib-dir-b.patch
new file mode 100644
index 0000000..e0b64a5
--- /dev/null
+++ b/meta-ivi/recipes-extended/common-api/common-api-c++-dbus/0001-common-api-dbus-runtime-replace-hard-coded-lib-dir-b.patch
@@ -0,0 +1,36 @@
+From 174781bad5f910f30dfc4adcd6de3c49e1d99988 Mon Sep 17 00:00:00 2001
+From: Clement Dransart <clement.dransart@awtce.be>
+Date: Wed, 15 Jun 2016 11:13:22 +0200
+Subject: [common-api-dbus-runtime][PATCH] replace hard-coded lib dir by
+ variable INSTALL_LIB_DIR
+
+Signed-off-by: Clement Dransart <clement.dransart@awtce.be>
+---
+ CMakeLists.txt | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 2750c4e..d651494 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -63,7 +63,7 @@ set(INSTALL_INCLUDE_DIR include/CommonAPI-${COMMONAPI_API_HEADER_VERSION} CACHE
+ if(WIN32 AND NOT CYGWIN)
+ set(DEF_INSTALL_CMAKE_DIR cmake)
+ else()
+- set(DEF_INSTALL_CMAKE_DIR lib/cmake/CommonAPI-DBus-${COMPONENT_VERSION})
++ set(DEF_INSTALL_CMAKE_DIR ${INSTALL_LIB_DIR}/cmake/CommonAPI-DBus-${COMPONENT_VERSION})
+ endif()
+ set(INSTALL_CMAKE_DIR ${DEF_INSTALL_CMAKE_DIR} CACHE PATH "Installation directory for CMake files")
+
+@@ -296,7 +296,7 @@ endif()
+ # create pkg-config file
+ if(NOT WIN32 AND PKG_CONFIG_FOUND)
+ configure_file(CommonAPI-DBus.pc.in ${PROJECT_BINARY_DIR}/CommonAPI-DBus.pc @ONLY)
+- install(FILES ${PROJECT_BINARY_DIR}/CommonAPI-DBus.pc DESTINATION lib/pkgconfig)
++ install(FILES ${PROJECT_BINARY_DIR}/CommonAPI-DBus.pc DESTINATION ${INSTALL_LIB_DIR}/pkgconfig)
+ endif()
+
+ ##############################################################################
+--
+1.9.1
+
diff --git a/meta-ivi/recipes-extended/common-api/common-api-c++-dbus_3.1.5.bb b/meta-ivi/recipes-extended/common-api/common-api-c++-dbus_3.1.5.bb
index 1426d9c..7d6e329 100644
--- a/meta-ivi/recipes-extended/common-api/common-api-c++-dbus_3.1.5.bb
+++ b/meta-ivi/recipes-extended/common-api/common-api-c++-dbus_3.1.5.bb
@@ -15,3 +15,7 @@ CXXFLAGS := "${@oe_filter_out('-fvisibility-inlines-hidden', '${CXXFLAGS}', d)}"
inherit cmake lib_package pkgconfig
FILES_${PN}-dev += "${libdir}/cmake"
+
+FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
+SRC_URI += "file://0001-common-api-dbus-runtime-replace-hard-coded-lib-dir-b.patch"
+EXTRA_OECMAKE = "-DINSTALL_LIB_DIR:PATH=${baselib} -DINSTALL_CMAKE_DIR:PATH=${baselib}/cmake/CommonAPI-DBus"
diff --git a/meta-ivi/recipes-extended/common-api/common-api-c++/0001-common-api-runtime-replace-hard-coded-lib-dir-by-var.patch b/meta-ivi/recipes-extended/common-api/common-api-c++/0001-common-api-runtime-replace-hard-coded-lib-dir-by-var.patch
new file mode 100644
index 0000000..43dc84c
--- /dev/null
+++ b/meta-ivi/recipes-extended/common-api/common-api-c++/0001-common-api-runtime-replace-hard-coded-lib-dir-by-var.patch
@@ -0,0 +1,36 @@
+From aa6c2d8bba7342da3c666b98070419a80b876d3a Mon Sep 17 00:00:00 2001
+From: Clement Dransart <clement.dransart@awtce.be>
+Date: Tue, 7 Jun 2016 15:30:35 +0200
+Subject: [common-api-runtime][PATCH] replace hard-coded lib dir by
+ variable INSTALL_LIB_DIR
+
+Signed-off-by: Clement Dransart <clement.dransart@awtce.be>
+---
+ CMakeLists.txt | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 961674f..764f203 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,7 +56,7 @@ set(INSTALL_INCLUDE_DIR include/CommonAPI-${COMMONAPI_API_HEADER_VERSION} CACHE
+ if(WIN32 AND NOT CYGWIN)
+ set(DEF_INSTALL_CMAKE_DIR cmake)
+ else()
+- set(DEF_INSTALL_CMAKE_DIR lib/cmake/CommonAPI-${COMPONENT_VERSION})
++ set(DEF_INSTALL_CMAKE_DIR ${INSTALL_LIB_DIR}/cmake/CommonAPI-${COMPONENT_VERSION})
+ endif()
+ set(INSTALL_CMAKE_DIR ${DEF_INSTALL_CMAKE_DIR} CACHE PATH "Installation directory for CMake files")
+
+@@ -229,7 +229,7 @@ endif()
+ # create pkg-config file
+ if(NOT WIN32 AND PKG_CONFIG_FOUND)
+ configure_file(CommonAPI.pc.in ${PROJECT_BINARY_DIR}/CommonAPI.pc @ONLY)
+- install(FILES ${PROJECT_BINARY_DIR}/CommonAPI.pc DESTINATION lib/pkgconfig)
++ install(FILES ${PROJECT_BINARY_DIR}/CommonAPI.pc DESTINATION ${INSTALL_LIB_DIR}/pkgconfig)
+ endif()
+
+ ##############################################################################
+--
+1.9.1
+
diff --git a/meta-ivi/recipes-extended/common-api/common-api-c++_3.1.5.bb b/meta-ivi/recipes-extended/common-api/common-api-c++_3.1.5.bb
index 66308d4..8449889 100644
--- a/meta-ivi/recipes-extended/common-api/common-api-c++_3.1.5.bb
+++ b/meta-ivi/recipes-extended/common-api/common-api-c++_3.1.5.bb
@@ -15,3 +15,7 @@ EXTRA_OECMAKE += "-DCMAKE_INSTALL_PREFIX=/usr"
FILES_${PN}-dev += "${libdir}/cmake"
RDEPENDS_${PN} += "dlt-daemon"
+
+FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
+SRC_URI += "file://0001-common-api-runtime-replace-hard-coded-lib-dir-by-var.patch"
+EXTRA_OECMAKE += "-DINSTALL_LIB_DIR:PATH=${baselib} -DINSTALL_CMAKE_DIR:PATH=${baselib}/cmake/CommonAPI"