python: fix disabling the SSL module
[buildroot-gz.git] / package / clapack / 0002-cmake-make-test-build-sensitive-to-BUILD_TESTING.patch
blobeac4164f5df1c2f8e3ca0ef21a403798d96d5456
1 From 834c221936d9c460b44e3a65b6fedfb3193f491b Mon Sep 17 00:00:00 2001
2 From: Samuel Martin <s.martin49@gmail.com>
3 Date: Sat, 11 Jan 2014 21:33:12 +0100
4 Subject: [PATCH 2/6] cmake: make test build sensitive to BUILD_TESTING
6 This patch prevent from wasting time building the tests if it's our
7 wish.
9 The test build takes a significant amount of time, and the binaries
10 are not installed.
12 Signed-off-by: Samuel Martin <s.martin49@gmail.com>
13 ---
14 BLAS/TESTING/CMakeLists.txt | 3 +++
15 CMakeLists.txt | 9 ++++++---
16 TESTING/CMakeLists.txt | 4 ++++
17 3 files changed, 13 insertions(+), 3 deletions(-)
19 diff --git a/BLAS/TESTING/CMakeLists.txt b/BLAS/TESTING/CMakeLists.txt
20 index ec2c587..e7dc0b7 100644
21 --- a/BLAS/TESTING/CMakeLists.txt
22 +++ b/BLAS/TESTING/CMakeLists.txt
23 @@ -25,6 +25,9 @@
24 # make single FRC=FRC
26 #######################################################################
27 +if(NOT BUILD_TESTING)
28 + return()
29 +endif()
31 macro(add_blas_test name src)
32 get_filename_component(baseNAME ${src} NAME_WE)
33 diff --git a/CMakeLists.txt b/CMakeLists.txt
34 index 320ccc6..0a362c0 100644
35 --- a/CMakeLists.txt
36 +++ b/CMakeLists.txt
37 @@ -1,6 +1,5 @@
38 cmake_minimum_required(VERSION 2.6)
39 project(CLAPACK C)
40 -enable_testing()
41 include(CTest)
43 if(WIN32 AND NOT CYGWIN)
44 @@ -11,7 +10,9 @@ else()
45 set(SECOND_SRC ${CLAPACK_SOURCE_DIR}/INSTALL/second.c)
46 set(DSECOND_SRC ${CLAPACK_SOURCE_DIR}/INSTALL/dsecnd.c)
47 endif()
48 -enable_testing()
49 +if(NOT BUILD_TESTING)
50 + enable_testing()
51 +endif()
52 option(USE_BLAS_WRAP "pre-pend f2c_ to each function in blas" OFF)
53 if(NOT USE_BLAS_WRAP)
54 # _zrotg_ seems to be missing in the wrap header
55 @@ -21,7 +22,9 @@ include_directories(${CLAPACK_SOURCE_DIR}/INCLUDE)
56 add_subdirectory(F2CLIBS)
57 add_subdirectory(BLAS)
58 add_subdirectory(SRC)
59 -add_subdirectory(TESTING)
60 +if(NOT BUILD_TESTING)
61 + add_subdirectory(TESTING)
62 +endif()
63 set(CLAPACK_VERSION 3.2.1)
64 set(CPACK_PACKAGE_VERSION_MAJOR 3)
65 set(CPACK_PACKAGE_VERSION_MINOR 2)
66 diff --git a/TESTING/CMakeLists.txt b/TESTING/CMakeLists.txt
67 index d59359d..f6b083a 100644
68 --- a/TESTING/CMakeLists.txt
69 +++ b/TESTING/CMakeLists.txt
70 @@ -1,3 +1,7 @@
71 +if(NOT BUILD_TESTING)
72 + return()
73 +endif()
75 if(MSVC_VERSION)
76 # string(REPLACE "/STACK:10000000" "/STACK:900000000000000000"
77 # CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS}")
78 --
79 1.8.5.3