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

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Feb 16 22:56:06 UTC 2022


 CMakeLists.txt       |   10 ----------
 glib/CMakeLists.txt  |    3 ---
 test/CMakeLists.txt  |    4 ----
 utils/CMakeLists.txt |    3 ---
 4 files changed, 20 deletions(-)

New commits:
commit ee937d16bbc9f8375fd670b10477d813b1a832ed
Author: Albert Astals Cid <aacid at kde.org>
Date:   Wed Feb 16 23:47:29 2022 +0100

    We don't use pthreads anymore, cleanup cmake stuff around it
    
    Well, there's some pthread code still in pdftoppm but it's "test"
    related, and should just be ported to C++11 threads

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4fcf7e83..c92e7fd1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -19,13 +19,6 @@ set(CMAKE_TRY_COMPILE_CONFIGURATION "${_CMAKE_BUILD_TYPE_UPPER}")
 
 include(MacroOptionalFindPackage)
 find_package(PkgConfig)
-if (WIN32)
-  message("-- Using win32 threads")
-else()
-  set(CMAKE_THREAD_PREFER_PTHREAD TRUE)
-  set(THREADS_PREFER_PTHREAD_FLAG TRUE)
-  find_package(Threads)
-endif()
 include(TestBigEndian)
 test_big_endian(WORDS_BIGENDIAN)
 include(CheckFileOffsetBits)
@@ -592,9 +585,6 @@ if(MINGW AND BUILD_SHARED_LIBS)
     set_target_properties(poppler PROPERTIES SUFFIX "-${POPPLER_SOVERSION}${CMAKE_SHARED_LIBRARY_SUFFIX}")
 endif()
 target_link_libraries(poppler LINK_PRIVATE ${poppler_LIBS})
-if(CMAKE_USE_PTHREADS_INIT)
-   target_link_libraries(poppler LINK_PRIVATE Threads::Threads)
-endif()
 install(TARGETS poppler RUNTIME DESTINATION bin LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
 
 if(ENABLE_UNSTABLE_API_ABI_HEADERS)
diff --git a/glib/CMakeLists.txt b/glib/CMakeLists.txt
index 8c122de0..a9d47342 100644
--- a/glib/CMakeLists.txt
+++ b/glib/CMakeLists.txt
@@ -96,9 +96,6 @@ 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)
-if(CMAKE_USE_PTHREADS_INIT)
-   target_link_libraries(poppler-glib Threads::Threads)
-endif()
 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 d6f32443..9de32ec5 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -40,10 +40,6 @@ 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} ${GTK3_LIBRARIES} poppler)
     target_compile_definitions(pdf-inspector PRIVATE -DSRC_DIR="${CMAKE_CURRENT_SOURCE_DIR}")
-    if(CMAKE_USE_PTHREADS_INIT)
-       target_link_libraries(pdf-inspector Threads::Threads)
-    endif()
-
   endif ()
 
 endif ()
diff --git a/utils/CMakeLists.txt b/utils/CMakeLists.txt
index 3789005b..747fb1e5 100644
--- a/utils/CMakeLists.txt
+++ b/utils/CMakeLists.txt
@@ -38,9 +38,6 @@ if (HAVE_CAIRO)
   add_definitions(${CAIRO_CFLAGS})
   add_executable(pdftocairo ${pdftocairo_SOURCES})
   target_link_libraries(pdftocairo ${CAIRO_LIBRARIES} Freetype::Freetype ${common_libs})
-  if(CMAKE_USE_PTHREADS_INIT)
-    target_link_libraries(pdftocairo Threads::Threads)
-  endif()
   if(LCMS2_FOUND)
     target_link_libraries(pdftocairo ${LCMS2_LIBRARIES})
   endif()


More information about the poppler mailing list