File: WtFindPostgresql.txt

package info (click to toggle)
witty 3.1.2-3
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 45,512 kB
  • ctags: 35,832
  • sloc: cpp: 69,469; ansic: 66,945; xml: 4,383; sh: 594; perl: 108; makefile: 106
file content (37 lines) | stat: -rw-r--r-- 789 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# This file defines:
# - POSTGRES_LIBRARIES
# - POSTGRES_INCLUDE_DIRS
# - POSTGRES_FOUND
#

FIND_LIBRARY(POSTGRES_LIBRARIES
  NAMES
    pq libpq
  PATHS
    /usr/lib
    /usr/local/lib
    /opt/local/lib	
    ${POSTGRES_ROOT}/lib
    ${USERLIB_ROOT}/lib
)

FIND_PATH(POSTGRES_INCLUDE libpq-fe.h
    /usr/include
    /usr/include/postgresql
    /usr/local/include
    /usr/local/include/postgresql
    /opt/local/include	
    /opt/local/include/postgresql
    ${POSTGRES_ROOT}/include
    ${POSTGRES_ROOT}/postgresql/include
    ${USERLIB_ROOT}/include
    ${USERLIB_ROOT}/postgresql/include
)

SET(POSTGRES_FOUND FALSE)

IF(POSTGRES_LIBRARIES AND POSTGRES_INCLUDE)
  SET(POSTGRES_FOUND TRUE)
  SET(POSTGRES_INCLUDE_DIRS ${POSTGRES_INCLUDE})
ENDIF(POSTGRES_LIBRARIES AND POSTGRES_INCLUDE)