generated from emilybache/GildedRose-Refactoring-Kata
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
31 lines (26 loc) · 968 Bytes
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
cmake_minimum_required(VERSION 2.8.4)
project(GildedRose_c99)
enable_testing()
include(ExternalProject)
ExternalProject_Add(unity
GIT_REPOSITORY https://github.com/ThrowTheSwitch/Unity.git
GIT_TAG master
SOURCE_DIR "${CMAKE_CURRENT_BINARY_DIR}/unity-src"
BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/unity-build"
CONFIGURE_COMMAND ""
BUILD_COMMAND ""
INSTALL_COMMAND ""
TEST_COMMAND ""
)
add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/unity-src/src/unity.c
DEPENDS unity
COMMAND "")
add_executable( GildedRose_Unity
GildedRose.c
${CMAKE_CURRENT_BINARY_DIR}/unity-src/src/unity.c
test_unity_gildedrose.c
)
target_include_directories(GildedRose_Unity PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/unity-src/src/)
set_property(TARGET GildedRose_Unity PROPERTY C_STANDARD 99)
add_dependencies(GildedRose_Unity unity)
add_test(NAME GildedRose_Unity COMMAND GildedRose_Unity)