summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlbert Astals Cid <aacid@kde.org>2022-12-04 03:22:52 +0100
committerAlbert Astals Cid <aacid@kde.org>2022-12-04 03:35:47 +0100
commit9bd49f486ed8442943a08cfee42136a5575c6a1b (patch)
treee6a3b3efa2ec734b6eb55df5a4e67993fa3e1f1e
parent821784a6f08adfbb5211d665389acc275e035e84 (diff)
cmake: Add CAIRO_INCLUDE_DIRS to the appropriate targets
-rw-r--r--glib/CMakeLists.txt1
-rw-r--r--test/CMakeLists.txt3
-rw-r--r--utils/CMakeLists.txt1
3 files changed, 5 insertions, 0 deletions
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})