forked from stepcode/stepcode
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
86 lines (67 loc) · 3.72 KB
/
CMakeLists.txt
File metadata and controls
86 lines (67 loc) · 3.72 KB
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
include_directories(..)
if(SC_GENERATE_LP_SOURCES)
include_directories("${PERPLEX_ExpScanner_INCLUDE_DIR}" "${LEMON_ExpParser_INCLUDE_DIR}")
endif(SC_GENERATE_LP_SOURCES)
set(EXPRESS_CORE_OBJ
# base
$<TARGET_OBJECTS:objlib_alloc_c>
$<TARGET_OBJECTS:objlib_memory_c>
$<TARGET_OBJECTS:objlib_hash_c>
$<TARGET_OBJECTS:objlib_linklist_c>
# global tables
$<TARGET_OBJECTS:objlib_object_c>
$<TARGET_OBJECTS:objlib_error_c>
# AST creation
$<TARGET_OBJECTS:objlib_factory_c>
$<TARGET_OBJECTS:objlib_stmt_c>
$<TARGET_OBJECTS:objlib_alg_c>
# deprecated
$<TARGET_OBJECTS:objlib_dict_c>
$<TARGET_OBJECTS:objlib_info_c>
)
add_executable(test_expr driver.c test_expr.c $<TARGET_OBJECTS:objlib_expr_c> ${EXPRESS_CORE_OBJ})
add_test(NAME exp_resolve_select_enum_member COMMAND test_expr resolve_select_enum_member)
add_test(NAME exp_resolve_entity_attribute COMMAND test_expr resolve_entity_attribute)
add_executable(test_express driver.c test_express.c $<TARGET_OBJECTS:objlib_express_c> ${EXPRESS_CORE_OBJ})
add_test(NAME express_rename_resolve COMMAND test_express express_rename_resolve)
add_executable(test_resolve driver.c test_resolve.c $<TARGET_OBJECTS:objlib_resolve_c> ${EXPRESS_CORE_OBJ})
add_test(NAME exp_resolve_bad_func_call COMMAND test_resolve exp_resolve_bad_func_call)
add_test(NAME exp_resolve_func_call COMMAND test_resolve exp_resolve_func_call)
add_test(NAME exp_resolve_local_identifier COMMAND test_resolve exp_resolve_local_identifier)
add_test(NAME entity_resolve_subtype_expr_entity COMMAND test_resolve entity_resolve_subtype_expr_entity)
add_test(NAME type_resolve_entity COMMAND test_resolve type_resolve_entity)
add_test(NAME stmt_resolve_pcall_proc COMMAND test_resolve stmt_resolve_pcall_proc)
add_test(NAME scope_resolve_named_types COMMAND test_resolve scope_resolve_named_types)
add_test(NAME entity_resolve_supertypes_entity COMMAND test_resolve entity_resolve_supertypes_entity)
add_executable(test_resolve2 driver.c test_resolve2.c $<TARGET_OBJECTS:objlib_resolve2_c> ${EXPRESS_CORE_OBJ})
add_test(NAME scope_resolve_expr_stmt COMMAND test_resolve2 scope_resolve_expr_stmt)
add_test(NAME scope_resolve_subsupers COMMAND test_resolve2 scope_resolve_subsupers)
add_executable(test_schema driver.c test_schema.c $<TARGET_OBJECTS:objlib_schema_c> ${EXPRESS_CORE_OBJ})
add_test(NAME schema_define_ref COMMAND test_schema schema_define_ref)
add_test(NAME schema_define_use COMMAND test_schema schema_define_use)
add_test(NAME schema_get_entities_ref COMMAND test_schema schema_get_entities_ref)
add_test(NAME var_find COMMAND test_schema var_find)
add_executable(test_scope driver.c test_scope.c $<TARGET_OBJECTS:objlib_scope_c> ${EXPRESS_CORE_OBJ})
add_test(NAME scope_find COMMAND test_scope scope_find)
add_executable(test_type driver.c test_type.c $<TARGET_OBJECTS:objlib_type_c> ${EXPRESS_CORE_OBJ})
add_test(NAME type_create_user_defined_tag COMMAND test_type type_create_user_defined_tag)
add_test(NAME build_check_express
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMAND ${CMAKE_COMMAND} --build .
--target check-express
--config $<CONFIGURATION>
)
add_test(NAME test_plib_parse_err
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMAND $<TARGET_FILE:check-express> "${CMAKE_CURRENT_SOURCE_DIR}/plib_parse_err.exp"
)
set_tests_properties( test_plib_parse_err PROPERTIES DEPENDS "build_check_express;$<TARGET_NAME:check-express>" )
set_tests_properties( test_plib_parse_err build_check_express PROPERTIES LABELS parser )
sc_addexec(print_schemas SOURCES ../fedex.c print_schemas.c LINK_LIBRARIES express)
sc_addexec(print_attrs SOURCES ../fedex.c print_attrs.c LINK_LIBRARIES express)
# Local Variables:
# tab-width: 8
# mode: cmake
# indent-tabs-mode: t
# End:
# ex: shiftwidth=2 tabstop=8