"Fossies" - the Fresh Open Source Software Archive

Member "xpdf-4.02/xpdf/CMakeLists.txt" (25 Sep 2019, 7555 Bytes) of package /linux/misc/xpdf-4.02.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the latest Fossies "Diffs" side-by-side code changes report for "CMakeLists.txt": 4.01.01_vs_4.02.

    1 #========================================================================
    2 #
    3 # xpdf/cmake-xpdf.txt
    4 #
    5 # CMake script for the Xpdf tools.
    6 #
    7 # Copyright 2015 Glyph & Cog, LLC
    8 #
    9 #========================================================================
   10 
   11 include_directories("${PROJECT_SOURCE_DIR}")
   12 include_directories("${PROJECT_BINARY_DIR}")
   13 include_directories("${PROJECT_SOURCE_DIR}/goo")
   14 include_directories("${PROJECT_SOURCE_DIR}/fofi")
   15 include_directories("${PROJECT_SOURCE_DIR}/splash")
   16 if (PNG_FOUND)
   17   include_directories("${PNG_INCLUDE_DIRS}")
   18   add_definitions("${PNG_DEFINITIONS}")
   19 endif ()
   20 if (HAVE_LCMS)
   21   include_directories("${LCMS_INCLUDE_DIR}")
   22   set(COLOR_MANAGER_SOURCE "ColorManager.cc")
   23 else ()
   24   set(COLOR_MANAGER_SOURCE "")
   25 endif ()
   26 
   27 add_library(xpdf_objs OBJECT
   28   AcroForm.cc
   29   Annot.cc
   30   Array.cc
   31   BuiltinFont.cc
   32   BuiltinFontTables.cc
   33   Catalog.cc
   34   CharCodeToUnicode.cc
   35   CMap.cc
   36   ${COLOR_MANAGER_SOURCE}
   37   Decrypt.cc
   38   Dict.cc
   39   Error.cc
   40   FontEncodingTables.cc
   41   Form.cc
   42   Function.cc
   43   Gfx.cc
   44   GfxFont.cc
   45   GfxState.cc
   46   GlobalParams.cc
   47   JArithmeticDecoder.cc
   48   JBIG2Stream.cc
   49   JPXStream.cc
   50   Lexer.cc
   51   Link.cc
   52   NameToCharCode.cc
   53   Object.cc
   54   OptionalContent.cc
   55   Outline.cc
   56   OutputDev.cc
   57   Page.cc
   58   Parser.cc
   59   PDF417Barcode.cc
   60   PDFDoc.cc
   61   PDFDocEncoding.cc
   62   PSTokenizer.cc
   63   SecurityHandler.cc
   64   Stream.cc
   65   TextString.cc
   66   UnicodeMap.cc
   67   UnicodeRemapping.cc
   68   UnicodeTypeTable.cc
   69   UTF8.cc
   70   XFAForm.cc
   71   XRef.cc
   72   Zoox.cc
   73 )
   74 
   75 #--- object files needed by XpdfWidget
   76 
   77 if ((QT4_FOUND OR Qt5Widgets_FOUND)
   78     AND HAVE_SPLASH AND MULTITHREADED AND USE_EXCEPTIONS)
   79 
   80   if (HIGHLIGHTED_REGIONS)
   81     set(HIGHLIGHT_SRC "HighlightFile.cc")
   82   else ()
   83     set(HIGHLIGHT_SRC "")
   84   endif ()
   85 
   86   add_library(xpdf_widget_objs OBJECT
   87     DisplayState.cc
   88     PDFCore.cc
   89     PreScanOutputDev.cc
   90     PSOutputDev.cc
   91     SplashOutputDev.cc
   92     TextOutputDev.cc
   93     TileCache.cc
   94     TileCompositor.cc
   95     TileMap.cc
   96     ${HIGHLIGHT_SRC}
   97   )
   98 endif ()
   99 
  100 #--- pdftops
  101 
  102 if (HAVE_SPLASH)
  103   add_executable(pdftops
  104     $<TARGET_OBJECTS:xpdf_objs>
  105     PreScanOutputDev.cc
  106     PSOutputDev.cc
  107     SplashOutputDev.cc
  108     pdftops.cc
  109   )
  110   target_link_libraries(pdftops goo fofi splash
  111                         ${PAPER_LIBRARY}
  112                         ${FREETYPE_LIBRARY} ${FREETYPE_OTHER_LIBS}
  113                         ${DTYPE_LIBRARY}
  114                         ${LCMS_LIBRARY}
  115                         ${FONTCONFIG_LIBRARY}
  116                         ${CMAKE_THREAD_LIBS_INIT})
  117 else ()
  118   add_executable(pdftops
  119     $<TARGET_OBJECTS:xpdf_objs>
  120     PreScanOutputDev.cc
  121     PSOutputDev.cc
  122     pdftops.cc
  123   )
  124   target_link_libraries(pdftops goo fofi
  125                         ${PAPER_LIBRARY}
  126                         ${LCMS_LIBRARY}
  127                         ${FONTCONFIG_LIBRARY}
  128                         ${CMAKE_THREAD_LIBS_INIT})
  129 endif ()
  130 install(TARGETS pdftops RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  131 install(FILES ${PROJECT_SOURCE_DIR}/doc/pdftops.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  132 
  133 #--- pdftotext
  134 
  135 add_executable(pdftotext
  136   $<TARGET_OBJECTS:xpdf_objs>
  137   TextOutputDev.cc
  138   pdftotext.cc
  139 )
  140 target_link_libraries(pdftotext goo fofi
  141                       ${PAPER_LIBRARY}
  142                       ${LCMS_LIBRARY}
  143                       ${FONTCONFIG_LIBRARY}
  144                       ${CMAKE_THREAD_LIBS_INIT})
  145 install(TARGETS pdftotext RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  146 install(FILES ${PROJECT_SOURCE_DIR}/doc/pdftotext.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  147 
  148 #--- pdftohtml
  149 
  150 if (HAVE_SPLASH AND PNG_FOUND)
  151   add_executable(pdftohtml
  152     $<TARGET_OBJECTS:xpdf_objs>
  153     HTMLGen.cc
  154     SplashOutputDev.cc
  155     TextOutputDev.cc
  156     WebFont.cc
  157     pdftohtml.cc
  158   )
  159   target_link_libraries(pdftohtml goo fofi splash
  160                         ${PAPER_LIBRARY}
  161                         ${FREETYPE_LIBRARY} ${FREETYPE_OTHER_LIBS}
  162                         ${DTYPE_LIBRARY}
  163                         ${LCMS_LIBRARY}
  164                         ${PNG_LIBRARIES}
  165                         ${FONTCONFIG_LIBRARY}
  166                         ${CMAKE_THREAD_LIBS_INIT})
  167   install(TARGETS pdftohtml RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  168   install(FILES ${PROJECT_SOURCE_DIR}/doc/pdftohtml.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  169 endif ()
  170 
  171 #--- pdfinfo
  172 
  173 add_executable(pdfinfo
  174   $<TARGET_OBJECTS:xpdf_objs>
  175   pdfinfo.cc
  176 )
  177 target_link_libraries(pdfinfo goo fofi
  178                       ${PAPER_LIBRARY}
  179                       ${LCMS_LIBRARY}
  180                       ${FONTCONFIG_LIBRARY}
  181                       ${CMAKE_THREAD_LIBS_INIT})
  182 install(TARGETS pdfinfo RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  183 install(FILES ${PROJECT_SOURCE_DIR}/doc/pdfinfo.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  184 
  185 #--- pdffonts
  186 
  187 add_executable(pdffonts
  188   $<TARGET_OBJECTS:xpdf_objs>
  189   pdffonts.cc
  190 )
  191 target_link_libraries(pdffonts goo fofi
  192                       ${PAPER_LIBRARY}
  193                       ${LCMS_LIBRARY}
  194                       ${FONTCONFIG_LIBRARY}
  195                       ${CMAKE_THREAD_LIBS_INIT})
  196 install(TARGETS pdffonts RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  197 install(FILES ${PROJECT_SOURCE_DIR}/doc/pdffonts.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  198 
  199 #--- pdfdetach
  200 
  201 add_executable(pdfdetach
  202   $<TARGET_OBJECTS:xpdf_objs>
  203   pdfdetach.cc
  204 )
  205 target_link_libraries(pdfdetach goo fofi
  206                       ${PAPER_LIBRARY}
  207                       ${LCMS_LIBRARY}
  208                       ${FONTCONFIG_LIBRARY}
  209                       ${CMAKE_THREAD_LIBS_INIT})
  210 install(TARGETS pdfdetach RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  211 install(FILES ${PROJECT_SOURCE_DIR}/doc/pdfdetach.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  212 
  213 #--- pdftoppm
  214 
  215 if (HAVE_SPLASH)
  216   add_executable(pdftoppm
  217     $<TARGET_OBJECTS:xpdf_objs>
  218     SplashOutputDev.cc
  219     pdftoppm.cc
  220   )
  221   target_link_libraries(pdftoppm goo fofi splash
  222                         ${PAPER_LIBRARY}
  223                         ${FREETYPE_LIBRARY} ${FREETYPE_OTHER_LIBS}
  224                         ${DTYPE_LIBRARY}
  225                         ${LCMS_LIBRARY}
  226                         ${FONTCONFIG_LIBRARY}
  227                         ${CMAKE_THREAD_LIBS_INIT})
  228   install(TARGETS pdftoppm RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  229   install(FILES ${PROJECT_SOURCE_DIR}/doc/pdftoppm.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  230 endif ()
  231 
  232 #--- pdftopng
  233 
  234 if (HAVE_SPLASH AND PNG_FOUND)
  235   add_executable(pdftopng
  236     $<TARGET_OBJECTS:xpdf_objs>
  237     SplashOutputDev.cc
  238     pdftopng.cc
  239   )
  240   target_link_libraries(pdftopng goo fofi splash
  241                         ${PAPER_LIBRARY}
  242                         ${FREETYPE_LIBRARY} ${FREETYPE_OTHER_LIBS}
  243                         ${DTYPE_LIBRARY}
  244                         ${LCMS_LIBRARY}
  245                         ${PNG_LIBRARIES}
  246                         ${FONTCONFIG_LIBRARY}
  247                         ${CMAKE_THREAD_LIBS_INIT})
  248   install(TARGETS pdftopng RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  249   install(FILES ${PROJECT_SOURCE_DIR}/doc/pdftopng.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  250 endif ()
  251 
  252 #--- pdfimages
  253 
  254 add_executable(pdfimages
  255   $<TARGET_OBJECTS:xpdf_objs>
  256   ImageOutputDev.cc
  257   pdfimages.cc
  258 )
  259 target_link_libraries(pdfimages goo fofi
  260                       ${PAPER_LIBRARY}
  261                       ${LCMS_LIBRARY}
  262                       ${FONTCONFIG_LIBRARY}
  263                       ${CMAKE_THREAD_LIBS_INIT})
  264 install(TARGETS pdfimages RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
  265 install(FILES ${PROJECT_SOURCE_DIR}/doc/pdfimages.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
  266 
  267 #--- xpdfrc man page
  268 
  269 install(FILES ${PROJECT_SOURCE_DIR}/doc/xpdfrc.5 DESTINATION ${CMAKE_INSTALL_MANDIR}/man5)