cmake/debian/patches/FindBoost_add_-lpthread_#563479.diff

24 lines
947 B
Diff
Raw Normal View History

Subject: Add -lpthread when using Boost::Thread.
Author: Kai Wasserbäch <debian@carbon-project.org>
Origin: vendor
Last-Update: 2011-01-16
2011-01-16 18:46:16 +01:00
Bug: http://cmake.org/Bug/view.php?id=10692
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=563479
2011-01-16 18:46:16 +01:00
Forwarded: http://cmake.org/Bug/file_download.php?file_id=3629&type=bug
---
Modules/FindBoost.cmake | 3 +++
1 file changed, 3 insertions(+)
--- a/Modules/FindBoost.cmake
+++ b/Modules/FindBoost.cmake
@@ -1121,6 +1121,9 @@ else(_boost_IN_CACHE)
message (STATUS " ${COMPONENT}")
endif(NOT Boost_FIND_QUIETLY)
set(Boost_LIBRARIES ${Boost_LIBRARIES} ${Boost_${UPPERCOMPONENT}_LIBRARY})
+ if(${UPPERCOMPONENT} STREQUAL "THREAD" AND UNIX)
+ set(Boost_LIBRARIES ${Boost_LIBRARIES} pthread)
+ endif(${UPPERCOMPONENT} STREQUAL "THREAD" AND UNIX)
endif( Boost_${UPPERCOMPONENT}_FOUND )
endforeach(COMPONENT)
else()