[Liblas-commits] hg: add WITH_STATIC_LASZIP advanced variable

liblas-commits at liblas.org liblas-commits at liblas.org
Fri Jan 21 15:06:20 EST 2011


details:   http://hg.liblas.orghg/rev/c696c43b1032
changeset: 2811:c696c43b1032
user:      Howard Butler <hobu.inc at gmail.com>
date:      Fri Jan 21 14:05:28 2011 -0600
description:
add WITH_STATIC_LASZIP advanced variable
Subject: hg: WITH_STATIC_LASZIP variable

details:   http://hg.liblas.orghg/rev/c9123cb61570
changeset: 2812:c9123cb61570
user:      Howard Butler <hobu.inc at gmail.com>
date:      Fri Jan 21 14:05:58 2011 -0600
description:
WITH_STATIC_LASZIP variable

diffstat:

 CMakeLists.txt     |  5 ++++-
 hobu-config.bat    |  9 +++++----
 src/CMakeLists.txt |  2 ++
 3 files changed, 11 insertions(+), 5 deletions(-)

diffs (55 lines):

diff -r 187599d6d530 -r c9123cb61570 CMakeLists.txt
--- a/CMakeLists.txt	Fri Jan 21 11:46:20 2011 -0600
+++ b/CMakeLists.txt	Fri Jan 21 14:05:58 2011 -0600
@@ -295,7 +295,10 @@
 endif()
 
 # LASZIP support - optional, default=OFF
-set(WITH_LASZIP FALSE CACHE BOOL "Choose if LASZIP support should be built")
+set(WITH_LASZIP FALSE CACHE BOOL "Choose if LASzip support should be built")
+set(WITH_STATIC_LASZIP FALSE CACHE BOOL "Choose of LASzip should be statically linked")
+mark_as_advanced(WITH_STATIC_LASZIP)
+
 if(WITH_LASZIP)
   find_package(LASzip 1.0.0)
 
diff -r 187599d6d530 -r c9123cb61570 hobu-config.bat
--- a/hobu-config.bat	Fri Jan 21 11:46:20 2011 -0600
+++ b/hobu-config.bat	Fri Jan 21 14:05:58 2011 -0600
@@ -9,8 +9,8 @@
 set ORACLE_HOME=%OSGEO4W%
 set LASZIP_ROOT=d:\laszip
 REM set BUILD_TYPE=RelWithDebInfo
-REM set BUILD_TYPE=Debug
-set BUILD_TYPE=Release
+set BUILD_TYPE=Debug
+REM set BUILD_TYPE=Release
 
 set PATH=%OSGEO4W%\apps\gdal-dev\bin;%OSGEO4W%\bin;%PATH%
 
@@ -29,8 +29,9 @@
     -DGDAL_LIBRARY=%OSGEO4W%\apps\gdal-dev\lib\gdal_i.lib ^
     -DORACLE_INCLUDE_DIR=%ORACLE_HOME%\include ^
     -DORACLE_OCI_LIBRARY=%ORACLE_HOME%\lib\oci.lib ^
-    -DLASZIP_INCLUDE_DIR=%OSGEO4W%\include ^
-    -DLASZIP_LIBRARY=%OSGEO4W%\lib\laszip.lib ^
+    -DLASZIP_INCLUDE_DIR=d:\laszip\include ^
+    -DLASZIP_LIBRARY=d:\laszip\bin\Debug\laszip.lib ^
     -DCMAKE_BUILD_TYPE=%BUILD_TYPE% ^
     -DCMAKE_VERBOSE_MAKEFILE=OFF ^
+    -DWITH_STATIC_LASZIP=FALSE ^
     %LIBLAS%
diff -r 187599d6d530 -r c9123cb61570 src/CMakeLists.txt
--- a/src/CMakeLists.txt	Fri Jan 21 11:46:20 2011 -0600
+++ b/src/CMakeLists.txt	Fri Jan 21 14:05:58 2011 -0600
@@ -215,8 +215,10 @@
 
 if(WIN32)
     add_definitions("-DLAS_DLL_EXPORT=1")
+if (NOT WITH_STATIC_LASZIP)
     add_definitions("-DLASZIP_DLL_IMPORT=1")
 endif()
+endif()
 
 add_library(${LIBLAS_LIB_NAME} SHARED ${LIBLAS_SOURCES})
 add_library(${LIBLAS_C_LIB_NAME} SHARED ${LIBLAS_C_SOURCES})


More information about the Liblas-commits mailing list