From 728b5247601caa452ce61deae714a9a951cbe612 Mon Sep 17 00:00:00 2001 From: Ronan Le Martret Date: Wed, 15 Oct 2014 16:06:19 +0200 Subject: [PATCH] Fix cmake /etc path for native build Change-Id: I2fba80fdb1a6800c99d2f4f9e5cc40c3cbd1b992 Signed-off-by: Ronan Le Martret --- recipes-devtools/cmake/cmake-native_%.bbappend | 5 ++-- .../cmake/files/TizenCommon_native.cmake | 31 ++++++++++++++++++++++ 2 files changed, 34 insertions(+), 2 deletions(-) create mode 100644 recipes-devtools/cmake/files/TizenCommon_native.cmake diff --git a/recipes-devtools/cmake/cmake-native_%.bbappend b/recipes-devtools/cmake/cmake-native_%.bbappend index ebec5e8..acc20c1 100644 --- a/recipes-devtools/cmake/cmake-native_%.bbappend +++ b/recipes-devtools/cmake/cmake-native_%.bbappend @@ -1,7 +1,8 @@ FILESEXTRAPATHS_append := "${THISDIR}/files" -SRC_URI += "file://TizenCommon.cmake" +SRC_URI += "file://TizenCommon_native.cmake" do_install_append() { - install -m 644 ${WORKDIR}/TizenCommon.cmake ${D}${datadir}/cmake-${CMAKE_MAJOR_VERSION}/Modules + mv ${WORKDIR}/TizenCommon_native.cmake ${WORKDIR}/TizenCommon.cmake + install -m 644 ${WORKDIR}/TizenCommon.cmake ${D}${datadir}/cmake-${CMAKE_MAJOR_VERSION}/Modules/ } \ No newline at end of file diff --git a/recipes-devtools/cmake/files/TizenCommon_native.cmake b/recipes-devtools/cmake/files/TizenCommon_native.cmake new file mode 100644 index 0000000..7cef5ed --- /dev/null +++ b/recipes-devtools/cmake/files/TizenCommon_native.cmake @@ -0,0 +1,31 @@ +# Copied from libzypp +# Library +IF ( DEFINED LIB ) + SET ( LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/lib" ) +ELSE ( DEFINED LIB ) + IF (CMAKE_SIZEOF_VOID_P MATCHES "8") + SET( LIB_SUFFIX "64" ) + ENDIF(CMAKE_SIZEOF_VOID_P MATCHES "8") + SET ( LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/lib" ) +ENDIF ( DEFINED LIB ) +MESSAGE(STATUS "Libraries will be installed in ${LIB_INSTALL_DIR}" ) + +# system configuration dir (etc) +IF( NOT DEFINED SYSCONFDIR ) + SET( SYSCONFDIR ${SYSCONF_INSTALL_DIR} ) +ENDIF( NOT DEFINED SYSCONFDIR ) +MESSAGE(STATUS "Config files will be installed in ${SYSCONFDIR}" ) + +# usr INSTALL_PREFIX + +IF( DEFINED CMAKE_INSTALL_PREFIX ) + SET( INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX} ) +ELSE( DEFINED CMAKE_INSTALL_PREFIX ) + SET( INSTALL_PREFIX /usr ) +ENDIF( DEFINED CMAKE_INSTALL_PREFIX ) + +# system configuration dir (etc) +IF( NOT DEFINED MANDIR ) + SET( MANDIR ${INSTALL_PREFIX}/share/man ) +ENDIF( NOT DEFINED MANDIR ) +MESSAGE( "** Manual files will be installed in ${MANDIR}" ) -- 2.7.4