mirror of
https://invent.kde.org/graphics/okular
synced 2024-08-27 11:40:07 +00:00
finding poppler under windows
svn path=/trunk/KDE/kdegraphics/cmake/modules/; revision=737148
This commit is contained in:
parent
f1fa4254f3
commit
3fa4b86d6b
|
@ -33,10 +33,22 @@ if(_PopplerLinkFlags)
|
||||||
if(_return_VALUE STREQUAL "0")
|
if(_return_VALUE STREQUAL "0")
|
||||||
set(POPPLER_FOUND TRUE)
|
set(POPPLER_FOUND TRUE)
|
||||||
endif(_return_VALUE STREQUAL "0")
|
endif(_return_VALUE STREQUAL "0")
|
||||||
|
else(_PopplerLinkFlags)
|
||||||
|
# try to find poppler without pkgconfig
|
||||||
|
find_library( LIBPOPPLER poppler )
|
||||||
|
find_library( LIBPOPPLER_QT4 poppler-qt4 )
|
||||||
|
find_path( INCLUDEPOPPLERQT4 qt4/poppler-qt4.h )
|
||||||
|
find_path( INCLUDEPOPPLER poppler-qt4.h PATHS ${INCLUDEPOPPLERQT4}/qt4 )
|
||||||
|
if( LIBPOPPLER_QT4 AND LIBPOPPLER AND INCLUDEPOPPLER )
|
||||||
|
set( POPPLER_FOUND TRUE )
|
||||||
|
endif( LIBPOPPLER_QT4 AND LIBPOPPLER AND INCLUDEPOPPLER )
|
||||||
endif(_PopplerLinkFlags)
|
endif(_PopplerLinkFlags)
|
||||||
|
|
||||||
if (POPPLER_FOUND)
|
if (POPPLER_FOUND)
|
||||||
set(POPPLER_LIBRARY ${_PopplerLinkFlags})
|
set(POPPLER_LIBRARY ${_PopplerLinkFlags})
|
||||||
|
if( LIBPOPPLER AND LIBPOPPLER_QT4 )
|
||||||
|
set( POPPLER_LIBRARY ${LIBPOPPLER} ${LIBPOPPLER_QT4} )
|
||||||
|
endif( LIBPOPPLER AND LIBPOPPLER_QT4 )
|
||||||
|
|
||||||
# the cflags for poppler-qt4 can contain more than one include path
|
# the cflags for poppler-qt4 can contain more than one include path
|
||||||
separate_arguments(_PopplerCflags)
|
separate_arguments(_PopplerCflags)
|
||||||
|
@ -44,6 +56,9 @@ if (POPPLER_FOUND)
|
||||||
string(REGEX REPLACE "-I(.+)" "\\1" _includedir "${_includedir}")
|
string(REGEX REPLACE "-I(.+)" "\\1" _includedir "${_includedir}")
|
||||||
set(POPPLER_INCLUDE_DIR ${POPPLER_INCLUDE_DIR} ${_includedir})
|
set(POPPLER_INCLUDE_DIR ${POPPLER_INCLUDE_DIR} ${_includedir})
|
||||||
endforeach(_includedir)
|
endforeach(_includedir)
|
||||||
|
if( INCLUDEPOPPLER )
|
||||||
|
set( POPPLER_INCLUDE_DIR ${INCLUDEPOPPLER} )
|
||||||
|
endif( INCLUDEPOPPLER )
|
||||||
|
|
||||||
# check whether we're using poppler 0.6
|
# check whether we're using poppler 0.6
|
||||||
set(CMAKE_REQUIRED_INCLUDES ${POPPLER_INCLUDE_DIR} ${QT_INCLUDE_DIR})
|
set(CMAKE_REQUIRED_INCLUDES ${POPPLER_INCLUDE_DIR} ${QT_INCLUDE_DIR})
|
||||||
|
|
Loading…
Reference in a new issue