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.
This commit is contained in:
Denis Arnaud 2012-01-25 23:51:38 +01:00
parent 1a7f14244d
commit 9f85852534
2 changed files with 25 additions and 35 deletions

View File

@ -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

View File

@ -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;
+}