From 6f25714b53e2f94ab23c4b223aebb2c99e1cc010 Mon Sep 17 00:00:00 2001 From: Pino Toscano Date: Mon, 29 May 2006 20:33:55 +0000 Subject: [PATCH] change the way we build qgs and the ghostscript plugin of okular: instead of compiling both separately and relying on the installed qgs for okular, only look for libgs and build both qgs and ghostscript at the same time. svn path=/branches/work/kde4/playground/graphics/cmake/; revision=546363 --- cmake/modules/modules/CMakeLists.txt | 2 +- cmake/modules/modules/FindQGS.cmake | 44 ---------------------------- generators/CMakeLists.txt | 4 +-- generators/ghostview/CMakeLists.txt | 1 + 4 files changed, 4 insertions(+), 47 deletions(-) delete mode 100644 cmake/modules/modules/FindQGS.cmake diff --git a/cmake/modules/modules/CMakeLists.txt b/cmake/modules/modules/CMakeLists.txt index fec0ea732..c49ab29e6 100644 --- a/cmake/modules/modules/CMakeLists.txt +++ b/cmake/modules/modules/CMakeLists.txt @@ -1,4 +1,4 @@ # install the cmake files -install_files(/share/apps/cmake/modules FILES FindQGS.cmake ) +#install_files(/share/apps/cmake/modules FILES FindQGS.cmake ) diff --git a/cmake/modules/modules/FindQGS.cmake b/cmake/modules/modules/FindQGS.cmake deleted file mode 100644 index a6b50d318..000000000 --- a/cmake/modules/modules/FindQGS.cmake +++ /dev/null @@ -1,44 +0,0 @@ -# - Try to find the qgs library -# Once done this will define -# -# QGS_FOUND - system has qgs -# QGS_INCLUDE_DIR - the qgs include directory -# QGS_LIBRARY - Link this to use qgs -# -include(CheckLibraryExists) - -# reset vars -set(QGS_INCLUDE_DIR) -set(QGS_LIBRARY) - -FIND_PATH(QGS_INCLUDE_DIR qgs.h - /usr/local/include - /usr/include - ${GNUWIN32_DIR}/include - ${KDE4_INCLUDE_DIR} -) - -# ${KDE4_INCLUDE_DIR}/../lib IS UBER UGLY but i did not found a better way -find_library(QGS_LIBRARY NAMES qgs - PATHS - /usr/lib - /usr/local/lib - ${GNUWIN32_DIR}/lib - ${KDE4_INCLUDE_DIR}/../lib -) - -if(QGS_INCLUDE_DIR AND QGS_LIBRARY) - set(QGS_FOUND TRUE) -endif(QGS_INCLUDE_DIR AND QGS_LIBRARY) - -if (QGS_FOUND) - if (NOT QGS_FIND_QUIETLY) - message(STATUS "Found qgs: ${QGS_LIBRARY}") - endif (NOT QGS_FIND_QUIETLY) -else (QGS_FOUND) - if (QGS_FIND_REQUIRED) - message(FATAL_ERROR "Could NOT find QGS") - endif (QGS_FIND_REQUIRED) -endif (QGS_FOUND) - -MARK_AS_ADVANCED(QGS_INCLUDE_DIR QGS_LIBRARY) diff --git a/generators/CMakeLists.txt b/generators/CMakeLists.txt index 772138f6c..cf1909d68 100644 --- a/generators/CMakeLists.txt +++ b/generators/CMakeLists.txt @@ -3,9 +3,9 @@ if(POPPLER_FOUND) add_subdirectory(poppler) endif(POPPLER_FOUND) -if(QGS_FOUND) +if(LIBGS_FOUND) add_subdirectory(ghostview) -endif(QGS_FOUND) +endif(LIBGS_FOUND) add_subdirectory( fax ) add_subdirectory( kimgio ) if(CHM_FOUND) diff --git a/generators/ghostview/CMakeLists.txt b/generators/ghostview/CMakeLists.txt index fe4e7b767..f93d452a8 100644 --- a/generators/ghostview/CMakeLists.txt +++ b/generators/ghostview/CMakeLists.txt @@ -3,6 +3,7 @@ add_subdirectory( conf ) include_directories( ${CMAKE_SOURCE_DIR}/okular ${CMAKE_CURRENT_BINARY_DIR}/../.. + ${CMAKE_SOURCE_DIR}/libqgs )