[QGIS Commit] r8225 - trunk/qgis/cmake
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Sat Mar 15 22:31:35 EDT 2008
Author: timlinux
Date: 2008-03-15 22:31:35 -0400 (Sat, 15 Mar 2008)
New Revision: 8225
Modified:
trunk/qgis/cmake/FindSqlite3.cmake
Log:
Added the possibility to use these libs from non default locations by specifying them in LIB_DIR. Before this change, the presence of the lib in /usr or /usr/local would override command line specified paths
Modified: trunk/qgis/cmake/FindSqlite3.cmake
===================================================================
--- trunk/qgis/cmake/FindSqlite3.cmake 2008-03-15 14:25:44 UTC (rev 8224)
+++ trunk/qgis/cmake/FindSqlite3.cmake 2008-03-16 02:31:35 UTC (rev 8225)
@@ -7,21 +7,27 @@
# SQLITE3_LIBRARY
+# Normally there is no need to specify /usr/... paths because
+# cmake will look there automatically. However the NO_DEFAULT_PATH
+# prevents this behaviour allowing you to use no standard file
+# locations in preference over standard ones. Note in this case
+# you then need to explicitly add /usr and /usr/local prefixes
+# to the search list. This applies both to FIND_PATH and FIND_LIBRARY
FIND_PATH(SQLITE3_INCLUDE_DIR sqlite3.h
+ "$ENV{LIB_DIR}/include/sqlite"
/usr/local/include
/usr/include
- #msvc
- "$ENV{LIB_DIR}/include/sqlite"
#mingw
c:/msys/local/include
+ NO_DEFAULT_PATH
)
FIND_LIBRARY(SQLITE3_LIBRARY NAMES sqlite3 PATHS
+ "$ENV{LIB_DIR}/lib"
/usr/local/lib
/usr/lib
c:/msys/local/lib
- #msvc
- "$ENV{LIB_DIR}/lib"
+ NO_DEFAULT_PATH
)
IF (SQLITE3_INCLUDE_DIR AND SQLITE3_LIBRARY)
More information about the QGIS-commit
mailing list