Subversion Repositories Scribus

Rev

Rev 16730 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
16730 fschmid 1
IF (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} LESS 2.5)
2
	INCLUDE(UsePkgConfig)
3
	PKGCONFIG(poppler _libPopplerIncDir _libPopplerLinkDir _libPopplerLinkFlags _libPopplerCflags)
4
    SET(PKG_POPPLER_INCLUDE_DIRS ${_libPopplerIncDir})
5
    SET(PKG_POPPLER_LIBRARIES ${_libPopplerLinkDir})
6
 ELSE (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} LESS 2.5)
7
    INCLUDE(FindPkgConfig)
8
    pkg_search_module(POPPLER libpoppler>=0.17.1 poppler>=0.17.1)
9
 ENDIF (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} LESS 2.5)
10
FIND_PATH(POPPLER_INCLUDE_DIR
11
  NAMES poppler-config.h
12
  PATHS ${PKG_POPPLER_INCLUDE_DIRS} ${POPPLER_INCLUDE_DIRS} /usr/local/include /usr/include
13
  PATH_SUFFIXES poppler
14
  NO_DEFAULT_PATH
15
)
16
 
17
FIND_LIBRARY(POPPLER_LIBRARY
18
  NAMES libpoppler poppler
17601 craig 19
  PATHS ${PKG_POPPLER_LIBRARIES} ${POPPLER_LIBRARY_DIRS} /usr/local/lib /usr/lib /usr/lib/x86_64-linux-gnu
16730 fschmid 20
  NO_DEFAULT_PATH
21
)
22
IF (POPPLER_LIBRARY)
23
  IF (POPPLER_INCLUDE_DIR)
24
	SET( FOUND_POPPLER 1 )
25
    SET( POPPLER_LIBRARIES ${POPPLER_LIBRARY} )
26
    SET( POPPLER_INCLUDES ${POPPLER_INCLUDE_DIR})
27
  ENDIF (POPPLER_INCLUDE_DIR)
17601 craig 28
ENDIF (POPPLER_LIBRARY)