From 9f858525341c513a3d4d0febe49150ea93f3cb6b Mon Sep 17 00:00:00 2001 From: Denis Arnaud Date: Wed, 25 Jan 2012 23:51:38 +0100 Subject: [PATCH] 1. Extracted the (Petr Machata's) patch on long double C++ source from the CMake-ifying patch into a dedicated one. 2. Integrated the CMake-related part of the long double patch into the CMake-ifying patch. --- boost-1.48.0-cmakeify-full.patch | 28 +++++++++++++--------------- boost-1.48.0-long-double-1.patch | 32 ++++++++++++-------------------- 2 files changed, 25 insertions(+), 35 deletions(-) diff --git a/boost-1.48.0-cmakeify-full.patch b/boost-1.48.0-cmakeify-full.patch index eca40d6..1875d14 100644 --- a/boost-1.48.0-cmakeify-full.patch +++ b/boost-1.48.0-cmakeify-full.patch @@ -5740,18 +5740,15 @@ index 0000000..84080d5 +) + + -diff --git a/libs/math/config/has_long_double_support.cpp b/libs/math/config/has_long_double_support.cpp -index d314cf3..9022408 100644 ---- a/libs/math/config/has_long_double_support.cpp -+++ b/libs/math/config/has_long_double_support.cpp -@@ -8,3 +8,7 @@ - #ifdef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS - #error "long double support is not supported by Boost.Math on this Plaform: the long double version of the TR1 library will not be built." - #endif -+ -+int main(int argc, char *argv[]) { -+ return 0; -+} +diff --git a/libs/math/config/CMakeLists.txt b/libs/math/config/CMakeLists.txt +new file mode 100644 +index 0000000..80921b3 +--- /dev/null ++++ b/libs/math/config/CMakeLists.txt +@@ -0,0 +1,3 @@ ++project(has_long_double_support CXX) ++add_executable(has_long_double_support has_long_double_support.cpp) ++include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../../../) diff --git a/libs/math/module.cmake b/libs/math/module.cmake new file mode 100644 index 0000000..e222098 @@ -5762,10 +5759,10 @@ index 0000000..e222098 \ No newline at end of file diff --git a/libs/math/src/tr1/CMakeLists.txt b/libs/math/src/tr1/CMakeLists.txt new file mode 100644 -index 0000000..865062a +index 0000000..e5400bc --- /dev/null +++ b/libs/math/src/tr1/CMakeLists.txt -@@ -0,0 +1,84 @@ +@@ -0,0 +1,85 @@ +boost_add_library(math_tr1 + + assoc_laguerre.cpp assoc_legendre.cpp beta.cpp @@ -5819,7 +5816,8 @@ index 0000000..865062a + +try_compile(HAS_LONG_DOUBLE_SUPPORT + ${CMAKE_CURRENT_SOURCE_DIR}/../../config/ -+ ${CMAKE_CURRENT_SOURCE_DIR}/../../config/has_long_double_support.cpp) ++ ${CMAKE_CURRENT_SOURCE_DIR}/../../config/ ++ has_long_double_support) + +IF (HAS_LONG_DOUBLE_SUPPORT) + boost_add_library(math_tr1l diff --git a/boost-1.48.0-long-double-1.patch b/boost-1.48.0-long-double-1.patch index ffb1d0f..2574539 100644 --- a/boost-1.48.0-long-double-1.patch +++ b/boost-1.48.0-long-double-1.patch @@ -1,20 +1,12 @@ -diff -urpN boost_1_48_0/libs/math/config/CMakeLists.txt boost_1_48_0.pm/libs/math/config/CMakeLists.txt ---- boost_1_48_0/libs/math/config/CMakeLists.txt 1969-12-31 19:00:00.000000000 -0500 -+++ boost_1_48_0.pm/libs/math/config/CMakeLists.txt 2012-01-25 06:13:29.000000000 -0500 -@@ -0,0 +1,3 @@ -+project(has_long_double_support CXX) -+add_executable(has_long_double_support has_long_double_support.cpp) -+include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../../../) -diff -urpN boost_1_48_0/libs/math/src/tr1/CMakeLists.txt boost_1_48_0.pm/libs/math/src/tr1/CMakeLists.txt ---- boost_1_48_0/libs/math/src/tr1/CMakeLists.txt 2012-01-25 07:32:50.000000000 -0500 -+++ boost_1_48_0.pm/libs/math/src/tr1/CMakeLists.txt 2012-01-25 07:29:01.000000000 -0500 -@@ -51,7 +51,8 @@ boost_add_library(math_c99f - - try_compile(HAS_LONG_DOUBLE_SUPPORT - ${CMAKE_CURRENT_SOURCE_DIR}/../../config/ -- ${CMAKE_CURRENT_SOURCE_DIR}/../../config/has_long_double_support.cpp) -+ ${CMAKE_CURRENT_SOURCE_DIR}/../../config/ -+ has_long_double_support) - - IF (HAS_LONG_DOUBLE_SUPPORT) - boost_add_library(math_tr1l +diff --git a/libs/math/config/has_long_double_support.cpp b/libs/math/config/has_long_double_support.cpp +index d314cf3..9022408 100644 +--- a/libs/math/config/has_long_double_support.cpp ++++ b/libs/math/config/has_long_double_support.cpp +@@ -8,3 +8,7 @@ + #ifdef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS + #error "long double support is not supported by Boost.Math on this Plaform: the long double version of the TR1 library will not be built." + #endif ++ ++int main(int argc, char *argv[]) { ++ return 0; ++}