File 0001-Allow-install-dir-over-ride.patch of Package libght

From eeba84028fd5425899fa8a9fe60931512a93fcac Mon Sep 17 00:00:00 2001
From: Paul Ramsey <pramsey@opengeo.org>
Date: Thu, 29 Aug 2013 09:43:50 -0700
Subject: [PATCH 1/7] Allow install dir over-ride

---
 CMakeLists.txt     | 9 +++++++++
 src/CMakeLists.txt | 4 ++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6c036c0..d50fc7f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -29,6 +29,15 @@ set (CMAKE_COLOR_MAKEFILE ON)
 # Path to additional CMake modules
 set (CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules ${CMAKE_MODULE_PATH})
 
+
+#------------------------------------------------------------------------------
+# use default install location if not specified
+#------------------------------------------------------------------------------
+
+if (NOT DEFINED LIB_INSTALL_DIR)
+  set (LIB_INSTALL_DIR lib)
+endif()
+
 #------------------------------------------------------------------------------
 # check for headers
 #------------------------------------------------------------------------------
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index b053306..c341d38 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -47,8 +47,8 @@ set_target_properties (libght-static
 target_link_libraries (libght xml2)
 target_link_libraries (libght-static xml2)
 
-install (TARGETS libght DESTINATION lib)
-install (TARGETS libght-static DESTINATION lib)
+install (TARGETS libght DESTINATION ${LIB_INSTALL_DIR})
+install (TARGETS libght-static DESTINATION ${LIB_INSTALL_DIR})
 
 install (FILES "${PROJECT_SOURCE_DIR}/src/ght.h" DESTINATION include)
 
-- 
1.8.4.5
openSUSE Build Service is sponsored by