File: CMakeLists.txt

package info (click to toggle)
svgpp 1.3.0%2Bdfsg1-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid
  • size: 2,488 kB
  • sloc: cpp: 30,520; makefile: 165; python: 73; xml: 48; sh: 36
file content (106 lines) | stat: -rw-r--r-- 2,654 bytes parent folder | download
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
cmake_minimum_required (VERSION 2.8)

project(svgpp_test)

set(GTEST_DIR /usr/src/googletest/googletest)
set(GMOCK_DIR /usr/src/googletest/googlemock)

include_directories(
  ../../include
  ${GTEST_DIR}
  ${GTEST_DIR}/include
  ${GMOCK_DIR}
  ${GMOCK_DIR}/include
  ../../third_party
)

if (MSVC)
  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /bigobj /W4")
endif()

file(GLOB_RECURSE SVGPP_HEADERS RELATIVE  ${CMAKE_CURRENT_SOURCE_DIR}/../../include/svgpp ${CMAKE_CURRENT_SOURCE_DIR}/../../include/svgpp/*.*)

foreach(i ${SVGPP_HEADERS})
  get_filename_component(_dir ${i} PATH)
  set(_pregroup "Headers/${_dir}")
  set(_name "../../include/svgpp/${i}")
  list(APPEND SOURCES
    ${_name}
  )
  string(REPLACE "/" "\\" _group ${_pregroup})
  source_group(${_group} FILES ${_name})
endforeach()

add_executable( ParserGTest
  ${SOURCES}
  basic_shapes_test.cpp 
  color_grammar_test.cpp 
  dictionary_test.cpp
  attribute_traversal_test.cpp 
  css_style_iterator_test.cpp 
	clock_value_grammar_test.cpp
  document_traversal_a_test.cpp  
  #icc_color_grammar_test.cpp
  length_factory_test.cpp 
  list_of_points_test.cpp 
  #path_adapter_test.cpp 
  path_grammar_test.cpp 
  path_markers_adapter_test.cpp 
  polyline_markers_test.cpp 
  preserveAspectRatio_test.cpp 
  #supported_value_parsers_test.cpp 
  transform_grammar_test.cpp 
  transform_strict_grammar_test.cpp 
  urange_grammar_test.cpp 
  #value_parser_test.cpp
  value_parser_length_test.cpp 
  value_parser_paint_ie_test.cpp 
  value_parser_paint_test.cpp 
	value_parser_path_test.cpp 
	value_parser_transform_test.cpp 
  ${GMOCK_DIR}/src/gmock_main.cc 
  ${GMOCK_DIR}/src/gmock-all.cc 
  ${GTEST_DIR}/src/gtest-all.cc 
)

if (UNIX)
  target_link_libraries(ParserGTest
    pthread
  )
endif()

set(CHECK_HEADERS_DIR check_headers)

file(GLOB_RECURSE SVGPP_HEADERS_HPP RELATIVE  ${CMAKE_CURRENT_SOURCE_DIR}/../../include/svgpp ${CMAKE_CURRENT_SOURCE_DIR}/../../include/svgpp/*.hpp)

foreach(i ${SVGPP_HEADERS_HPP})
  if (NOT ${i} MATCHES "policy/xml/.*")
    string(REPLACE "/" "_" _name ${i})
    string(REPLACE "." "_" _file_name ${_name})
    set(_file_name "${CMAKE_BINARY_DIR}/${CHECK_HEADERS_DIR}/check_${_file_name}.cpp")
    #message(${_file_name})
    file(WRITE ${_file_name} "#include <svgpp/${i}>")
    list(APPEND CHECK_HEADERS_SOURCES ${_file_name})
  endif()
endforeach()


add_library(CheckHeadersAutonomy STATIC
  ${CHECK_HEADERS_SOURCES}
)

if (1)
	add_executable(FullParseTest
		full_parse_main.cpp
		full_parse_test.cpp
		full_parse_test2.cpp
		full_parse_test_common.hpp
	)

	if (UNIX)
		target_link_libraries(FullParseTest
			boost_timer
			boost_system
		)
	endif()
endif()