# - find Sqlite 3
# SQLITE3_INCLUDE_DIR - Where to find Sqlite 3 header files (directory)
# SQLITE3_LIBRARIES - Sqlite 3 libraries
# SQLITE3_LIBRARY_RELEASE - Where the release library is
# SQLITE3_LIBRARY_DEBUG - Where the debug library is
# SQLITE3_FOUND - Set to TRUE if we found everything (library, includes and executable)
# Copyright (c) 2010 Pau Garcia i Quiles, <pgquiles@elpauer.org>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
#
# Generated by CModuler, a CMake Module Generator - http://gitorious.org/cmoduler

FIND_PATH( SQLITE3_INCLUDE_DIR sqlite3.h  )

FIND_LIBRARY( SQLITE3_LIBRARIES NAMES sqlite3 libsqlite3 HINTS /usr/lib /usr/local/lib /usr/lib/sqlite3 /usr/local/lib/sqlite3 )

IF( SQLITE3_LIBRARIES AND SQLITE3_INCLUDE_DIR )
        SET( SQLITE3_FOUND TRUE )
ENDIF( SQLITE3_LIBRARIES AND SQLITE3_INCLUDE_DIR )

IF( SQLITE3_FOUND )
        MESSAGE( STATUS "Found Sqlite3 header file in ${SQLITE3_INCLUDE_DIR}")
        MESSAGE( STATUS "Found Sqlite3 libraries: ${SQLITE3_LIBRARIES}")
ELSE(SQLITE3_FOUND)
        MESSAGE( FATAL_ERROR "Could not find Sqlite3" )
ENDIF(SQLITE3_FOUND)

