~ubuntu-branches/ubuntu/maverick/kdegraphics/maverick-proposed

« back to all changes in this revision

Viewing changes to cmake/modules/FindPoppler.cmake

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Thomas
  • Date: 2009-12-02 14:03:43 UTC
  • mfrom: (1.1.35 upstream)
  • Revision ID: james.westby@ubuntu.com-20091202140343-2732gbkj69g89arq
Tags: 4:4.3.80-0ubuntu1
* New upstream beta release:
  - Add build-depend on shared-desktop-ontologies for nepomuk integration
  - Bump .so versions for libkexiv, libkdcraw and libkipi
  - Update various .install files

Show diffs side-by-side

added added

removed removed

Lines of Context:
45
45
endif(_PopplerLinkFlags)
46
46
 
47
47
if (POPPLER_FOUND)
 
48
  INCLUDE(CheckCXXSourceCompiles)
 
49
 
48
50
  set(POPPLER_LIBRARY ${_PopplerLinkFlags})
49
51
 
50
52
  # the cflags for poppler-qt4 can contain more than one include path
78
80
  return 0;
79
81
}
80
82
" HAVE_POPPLER_0_8)
 
83
check_cxx_source_compiles("
 
84
#include <poppler-qt4.h>
 
85
int main()
 
86
{
 
87
  Poppler::Document::RenderHint hint = Poppler::Document::TextHinting;
 
88
  return 0;
 
89
}
 
90
" HAVE_POPPLER_0_12_1)
81
91
  set(CMAKE_REQUIRED_INCLUDES)
82
92
  set(CMAKE_REQUIRED_LIBRARIES)
83
 
  if (HAVE_POPPLER_0_8)
 
93
  if (HAVE_POPPLER_0_12_1)
 
94
    set(popplerVersionMessage "0.12.1")
 
95
  elseif (HAVE_POPPLER_0_8)
84
96
    set(popplerVersionMessage "0.8")
85
97
  elseif (HAVE_POPPLER_0_6)
86
98
    set(popplerVersionMessage "0.6")
87
 
  else (HAVE_POPPLER_0_8)
 
99
  else (HAVE_POPPLER_0_12_1)
88
100
    set(popplerVersionMessage "0.5.4")
89
 
  endif (HAVE_POPPLER_0_8)
 
101
  endif (HAVE_POPPLER_0_12_1)
90
102
  if (NOT Poppler_FIND_QUIETLY)
91
103
    message(STATUS "Found Poppler-Qt4: ${POPPLER_LIBRARY}, (>= ${popplerVersionMessage})")
92
104
  endif (NOT Poppler_FIND_QUIETLY)
102
114
set(POPPLER_LIBRARY ${POPPLER_LIBRARY} CACHE INTERNAL "The Poppler-Qt4 library")
103
115
set(HAVE_POPPLER_0_6 ${HAVE_POPPLER_0_6} CACHE INTERNAL "Whether the version of Poppler-Qt4 is >= 0.6")
104
116
set(HAVE_POPPLER_0_8 ${HAVE_POPPLER_0_8} CACHE INTERNAL "Whether the version of Poppler-Qt4 is >= 0.8")
 
117
set(HAVE_POPPLER_0_12_1 ${HAVE_POPPLER_0_12_1} CACHE INTERNAL "Whether the version of Poppler-Qt4 is >= 0.12.1")
105
118
 
106
119
endif(POPPLER_INCLUDE_DIR AND POPPLER_LIBRARY)