Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/owncloud/client.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOlivier Goffart <ogoffart@woboq.com>2014-01-13 17:35:36 +0400
committerOlivier Goffart <ogoffart@woboq.com>2014-01-13 17:39:50 +0400
commitbf7ca60becd05234e27692f8fa469a5880fa07bb (patch)
treeee7c6af0fd8366fc05f4d5d92c41fe5aa6952ab6 /cmake/modules/FindSQLite3.cmake
parentd931e0bcc29756dedac469f235aa15ee73b47bc0 (diff)
Move csync in order to merge it with mirall
Diffstat (limited to 'cmake/modules/FindSQLite3.cmake')
-rw-r--r--cmake/modules/FindSQLite3.cmake58
1 files changed, 58 insertions, 0 deletions
diff --git a/cmake/modules/FindSQLite3.cmake b/cmake/modules/FindSQLite3.cmake
new file mode 100644
index 000000000..e34af6d8a
--- /dev/null
+++ b/cmake/modules/FindSQLite3.cmake
@@ -0,0 +1,58 @@
+# - Try to find SQLite3
+# Once done this will define
+#
+# SQLITE3_FOUND - system has SQLite3
+# SQLITE3_INCLUDE_DIRS - the SQLite3 include directory
+# SQLITE3_LIBRARIES - Link these to use SQLite3
+# SQLITE3_DEFINITIONS - Compiler switches required for using SQLite3
+#
+# Copyright (c) 2009-2013 Andreas Schneider <asn@cryptomilk.org>
+#
+# Redistribution and use is allowed according to the terms of the New
+# BSD license.
+# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
+#
+
+
+if (UNIX)
+ find_package(PkgConfig)
+ if (PKG_CONFIG_FOUND)
+ pkg_check_modules(_SQLITE3 sqlite3)
+ endif (PKG_CONFIG_FOUND)
+endif (UNIX)
+
+find_path(SQLITE3_INCLUDE_DIR
+ NAMES
+ sqlite3.h
+ PATHS
+ ${_SQLITE3_INCLUDEDIR}
+)
+
+find_library(SQLITE3_LIBRARY
+ NAMES
+ sqlite3
+ PATHS
+ ${_SQLITE3_LIBDIR}
+)
+
+set(SQLITE3_INCLUDE_DIRS
+ ${SQLITE3_INCLUDE_DIR}
+)
+
+if (SQLITE3_LIBRARY)
+ set(SQLITE3_LIBRARIES
+ ${SQLITE3_LIBRARIES}
+ ${SQLITE3_LIBRARY}
+ )
+endif (SQLITE3_LIBRARY)
+
+if (SQLite3_FIND_VERSION AND _SQLITE3_VERSION)
+ set(SQLite3_VERSION _SQLITE3_VERSION)
+endif (SQLite3_FIND_VERSION AND _SQLITE3_VERSION)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(SQLite3 DEFAULT_MSG SQLITE3_LIBRARIES SQLITE3_INCLUDE_DIRS)
+
+# show the SQLITE3_INCLUDE_DIRS and SQLITE3_LIBRARIES variables only in the advanced view
+mark_as_advanced(SQLITE3_INCLUDE_DIRS SQLITE3_LIBRARIES)
+