Install the .pc file in the arch-dependent folder 61/26661/1
authorManuel Bachmann <manuel.bachmann@open.eurogiciel.org>
Wed, 27 Aug 2014 10:56:49 +0000 (12:56 +0200)
committerManuel Bachmann <manuel.bachmann@open.eurogiciel.org>
Wed, 27 Aug 2014 10:56:49 +0000 (12:56 +0200)
If phoned is built on a non-x86 device, the installation lib
folder may not be "/usr/lib" ("/usr/lib64" e.g.).
Fix that in the CMake build file.

Change-Id: Ie7549396b2d8c339ce11dbb59c8dad1f3e0f48fd
Signed-off-by: Manuel Bachmann <manuel.bachmann@open.eurogiciel.org>
CMakeLists.txt

index 1b8292b..f309d6d 100644 (file)
@@ -7,6 +7,7 @@ SET(CMAKE_INSTALL_PREFIX "/usr")
 # Required platform modules
 # -----------------------------------------------------------------------------
 INCLUDE(FindPkgConfig)
+INCLUDE(GNUInstallDirs)
 
 PKG_CHECK_MODULES(glib REQUIRED glib-2.0)
 PKG_CHECK_MODULES(gio REQUIRED gio-2.0)
@@ -76,7 +77,7 @@ SET(PKGCONFIG_DIR ${CMAKE_SOURCE_DIR}/pkgconfig)
 MACRO(configure_and_install_pkg PKG_FILE)
     CONFIGURE_FILE(${PKGCONFIG_DIR}/${PKG_FILE}.in
                ${PKGCONFIG_DIR}/${PKG_FILE} @ONLY)
-    INSTALL(FILES ${PKGCONFIG_DIR}/${PKG_FILE} DESTINATION lib/pkgconfig)
+    INSTALL(FILES ${PKGCONFIG_DIR}/${PKG_FILE} DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
 ENDMACRO(configure_and_install_pkg)
 
 SET(TARGET_NAME phoned)