comparison tests/src/libirccd/dynlib-plugin/CMakeLists.txt @ 611:9fbd1700435b

Tests: reoganize hierarchy
author David Demelier <markand@malikania.fr>
date Fri, 15 Dec 2017 15:37:58 +0100
parents tests/src/dynlib-plugin/CMakeLists.txt@a51b5dd5b761
children 27587ff92a64
comparison
equal deleted inserted replaced
610:22b3cd6f991f 611:9fbd1700435b
1 #
2 # CMakeLists.txt -- CMake build system for irccd
3 #
4 # Copyright (c) 2013-2017 David Demelier <markand@malikania.fr>
5 #
6 # Permission to use, copy, modify, and/or distribute this software for any
7 # purpose with or without fee is hereby granted, provided that the above
8 # copyright notice and this permission notice appear in all copies.
9 #
10 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 #
18
19 find_package(Boost REQUIRED QUIET)
20
21 add_library(test-plugin MODULE test_plugin.cpp)
22 target_link_libraries(test-plugin libirccd Boost::boost)
23 set_target_properties(
24 test-plugin
25 PROPERTIES
26 PREFIX ""
27 RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
28 )
29
30 foreach (c ${CMAKE_CONFIGURATION_TYPES})
31 string(TOUPPER ${c} c)
32 set_target_properties(
33 test-plugin
34 PROPERTIES
35 RUNTIME_OUTPUT_DIRECTORY_${c} ${CMAKE_CURRENT_BINARY_DIR}
36 )
37 endforeach ()
38
39 irccd_define_test(
40 NAME dynlib-plugin
41 SOURCES main.cpp
42 LIBRARIES libirccd libirccd-test
43 )