[poppler] glib/CMakeLists.txt test/CMakeLists.txt utils/CMakeLists.txt

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Sun Dec 4 02:36:10 UTC 2022


 glib/CMakeLists.txt  |    1 +
 test/CMakeLists.txt  |    3 +++
 utils/CMakeLists.txt |    1 +
 3 files changed, 5 insertions(+)

New commits:
commit 9bd49f486ed8442943a08cfee42136a5575c6a1b
Author: Albert Astals Cid <aacid at kde.org>
Date:   Sun Dec 4 03:22:52 2022 +0100

    cmake: Add CAIRO_INCLUDE_DIRS to the appropriate targets

diff --git a/glib/CMakeLists.txt b/glib/CMakeLists.txt
index e28d43ab..52e8687a 100644
--- a/glib/CMakeLists.txt
+++ b/glib/CMakeLists.txt
@@ -96,6 +96,7 @@ if(MINGW AND BUILD_SHARED_LIBS)
     set_target_properties(poppler-glib PROPERTIES SUFFIX "-${POPPLER_GLIB_SOVERSION}${CMAKE_SHARED_LIBRARY_SUFFIX}")
 endif()
 target_link_libraries(poppler-glib poppler PkgConfig::GLIB2 ${CAIRO_LIBRARIES} Freetype::Freetype)
+target_include_directories(poppler-glib SYSTEM PRIVATE ${CAIRO_INCLUDE_DIRS})
 install(TARGETS poppler-glib RUNTIME DESTINATION bin LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
 
 install(FILES
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 6243c56d..8334d0f5 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -23,6 +23,7 @@ if (GTK_FOUND)
   )
   poppler_add_test(gtk-test BUILD_GTK_TESTS ${gtk_splash_test_SRCS})
   target_link_libraries(gtk-test ${CAIRO_LIBRARIES} poppler-glib PkgConfig::GTK3)
+  target_include_directories(gtk-test SYSTEM PRIVATE ${CAIRO_INCLUDE_DIRS})
 
   if (HAVE_CAIRO)
 
@@ -34,6 +35,7 @@ if (GTK_FOUND)
     )
     poppler_add_test(pdf-inspector BUILD_GTK_TESTS ${pdf_inspector_SRCS})
     target_link_libraries(pdf-inspector ${CAIRO_LIBRARIES} Freetype::Freetype ${common_libs} PkgConfig::GTK3 poppler)
+    target_include_directories(pdf-inspector SYSTEM PRIVATE ${CAIRO_INCLUDE_DIRS})
     target_compile_definitions(pdf-inspector PRIVATE -DSRC_DIR="${CMAKE_CURRENT_SOURCE_DIR}")
   endif ()
 
@@ -62,6 +64,7 @@ if (HAVE_CAIRO)
       )
     add_executable(cairo-thread-test ${cairo_thread_test_SRCS})
     target_link_libraries(cairo-thread-test ${CAIRO_LIBRARIES} Freetype::Freetype Threads::Threads poppler)
+    target_include_directories(cairo-thread-test SYSTEM PRIVATE ${CAIRO_INCLUDE_DIRS})
   endif ()
 endif ()
 
diff --git a/utils/CMakeLists.txt b/utils/CMakeLists.txt
index 34696e93..314c848c 100644
--- a/utils/CMakeLists.txt
+++ b/utils/CMakeLists.txt
@@ -39,6 +39,7 @@ if (HAVE_CAIRO)
   add_definitions(${CAIRO_CFLAGS})
   add_executable(pdftocairo ${pdftocairo_SOURCES})
   target_link_libraries(pdftocairo ${CAIRO_LIBRARIES} Freetype::Freetype ${common_libs})
+  target_include_directories(pdftocairo SYSTEM PRIVATE ${CAIRO_INCLUDE_DIRS})
   if(LCMS2_FOUND)
     target_link_libraries(pdftocairo ${LCMS2_LIBRARIES})
     target_include_directories(pdftocairo SYSTEM PRIVATE ${LCMS2_INCLUDE_DIR})


More information about the poppler mailing list