Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
dlib
Commits
5e0cc695
Commit
5e0cc695
authored
Aug 23, 2016
by
Davis King
Browse files
Improved how the unit tests build all/source.cpp
parent
3ca48028
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
14 deletions
+8
-14
dlib/CMakeLists.txt
dlib/CMakeLists.txt
+5
-0
dlib/test/CMakeLists.txt
dlib/test/CMakeLists.txt
+3
-1
dlib/test/all_source/CMakeLists.txt
dlib/test/all_source/CMakeLists.txt
+0
-13
No files found.
dlib/CMakeLists.txt
View file @
5e0cc695
...
@@ -568,6 +568,11 @@ if (NOT TARGET dlib)
...
@@ -568,6 +568,11 @@ if (NOT TARGET dlib)
endif
()
##### end of if NOT DLIB_ISO_CPP_ONLY ##########################################################
endif
()
##### end of if NOT DLIB_ISO_CPP_ONLY ##########################################################
# Allow the unit tests to ask us to compile the all/source.cpp file just to make sure it compiles.
if
(
DLIB_TEST_COMPILE_ALL_SOURCE_CPP
)
ADD_LIBRARY
(
dlib_all_source_cpp STATIC all/source.cpp
)
endif
()
# Install the library
# Install the library
if
(
NOT DLIB_IN_PROJECT_BUILD
)
if
(
NOT DLIB_IN_PROJECT_BUILD
)
set
(
LIB_INSTALL_DIR lib CACHE STRING
"Install location of libraries (e.g. lib32 or lib64 for multilib installations)"
)
set
(
LIB_INSTALL_DIR lib CACHE STRING
"Install location of libraries (e.g. lib32 or lib64 for multilib installations)"
)
...
...
dlib/test/CMakeLists.txt
View file @
5e0cc695
...
@@ -9,6 +9,9 @@ cmake_minimum_required(VERSION 2.8.4)
...
@@ -9,6 +9,9 @@ cmake_minimum_required(VERSION 2.8.4)
set
(
target_name dtest
)
set
(
target_name dtest
)
PROJECT
(
${
target_name
}
)
PROJECT
(
${
target_name
}
)
# compile the dlib/all/source.cpp file into its own object just to make sure it compiles
set
(
DLIB_TEST_COMPILE_ALL_SOURCE_CPP ON
)
include
(
../cmake
)
include
(
../cmake
)
# This variable contains a list of all the tests we are building
# This variable contains a list of all the tests we are building
...
@@ -177,7 +180,6 @@ TARGET_LINK_LIBRARIES(${target_name} dlib )
...
@@ -177,7 +180,6 @@ TARGET_LINK_LIBRARIES(${target_name} dlib )
if
(
NOT DLIB_NO_GUI_SUPPORT
)
if
(
NOT DLIB_NO_GUI_SUPPORT
)
add_subdirectory
(
gui
)
add_subdirectory
(
gui
)
add_subdirectory
(
examples
)
add_subdirectory
(
examples
)
add_subdirectory
(
all_source
)
endif
()
endif
()
dlib/test/all_source/CMakeLists.txt
deleted
100644 → 0
View file @
3ca48028
#
# This is a CMake makefile. You can find the cmake utility and
# information about it at http://www.cmake.org
#
cmake_minimum_required
(
VERSION 2.8.4
)
set
(
target_name test_all_source_builds
)
PROJECT
(
${
target_name
}
)
include
(
../../cmake_utils/use_cpp_11.cmake
)
ADD_LIBRARY
(
${
target_name
}
STATIC ../../all/source.cpp
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment