diff options
author | Brent Cook <bcook@openbsd.org> | 2015-07-21 22:21:14 -0500 |
---|---|---|
committer | Brent Cook <bcook@openbsd.org> | 2015-07-21 22:21:14 -0500 |
commit | a9122f74e0b965c7ecb5e8ceb8e3dfb682e14336 (patch) | |
tree | 39fcc3acb9de69b28875d5d9caaaf832a522fa8e /CMakeLists.txt | |
parent | 3614acd62e7dfccbd7c8f928559436775a43a6be (diff) | |
download | portable-a9122f74e0b965c7ecb5e8ceb8e3dfb682e14336.tar.gz portable-a9122f74e0b965c7ecb5e8ceb8e3dfb682e14336.tar.bz2 portable-a9122f74e0b965c7ecb5e8ceb8e3dfb682e14336.zip |
add cmake tests
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 6b5e011..5b55a5a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -1,8 +1,11 @@ | |||
1 | cmake_minimum_required (VERSION 3.2) | 1 | cmake_minimum_required (VERSION 3.2) |
2 | include(CheckFunctionExists) | 2 | include(CheckFunctionExists) |
3 | include(CheckIncludeFiles) | ||
3 | 4 | ||
4 | project (LibreSSL) | 5 | project (LibreSSL) |
5 | 6 | ||
7 | enable_testing() | ||
8 | |||
6 | if(CMAKE_SYSTEM_NAME MATCHES "OpenBSD") | 9 | if(CMAKE_SYSTEM_NAME MATCHES "OpenBSD") |
7 | add_definitions(-DHAVE_ATTRIBUTE__BOUNDED__) | 10 | add_definitions(-DHAVE_ATTRIBUTE__BOUNDED__) |
8 | endif() | 11 | endif() |
@@ -123,7 +126,18 @@ if(HAVE_MEMCMP) | |||
123 | add_definitions(-DHAVE_MEMCMP) | 126 | add_definitions(-DHAVE_MEMCMP) |
124 | endif() | 127 | endif() |
125 | 128 | ||
129 | check_include_files(err.h HAVE_ERR_H) | ||
130 | if(HAVE_ERR_H) | ||
131 | add_definitions(-DHAVE_ERR_H) | ||
132 | endif() | ||
133 | |||
134 | set(OPENSSL_LIBS ssl crypto) | ||
135 | if(CMAKE_HOST_WIN32) | ||
136 | set(OPENSSL_LIBS ${OPENSSL_LIBS} ws2_32) | ||
137 | endif() | ||
138 | |||
126 | add_subdirectory(crypto) | 139 | add_subdirectory(crypto) |
127 | add_subdirectory(ssl) | 140 | add_subdirectory(ssl) |
128 | add_subdirectory(apps) | 141 | add_subdirectory(apps) |
129 | add_subdirectory(tls) | 142 | add_subdirectory(tls) |
143 | add_subdirectory(tests) | ||