blob: d6c435ac33cee3b0ca224fa9475696493b191852 [file] [log] [blame]
Josh Haberman42496922018-08-24 12:27:21 -07001
2add_custom_command(
Arfrever Frehtes Taifersar Arahesis42686622022-03-08 00:00:00 +00003 OUTPUT ${protobuf_SOURCE_DIR}/conformance/conformance.pb.cc
4 DEPENDS ${protobuf_PROTOC_EXE} ${protobuf_SOURCE_DIR}/conformance/conformance.proto
5 COMMAND ${protobuf_PROTOC_EXE} ${protobuf_SOURCE_DIR}/conformance/conformance.proto
6 --proto_path=${protobuf_SOURCE_DIR}/conformance
7 --cpp_out=${protobuf_SOURCE_DIR}/conformance
Josh Haberman42496922018-08-24 12:27:21 -07008)
9
10add_custom_command(
Arfrever Frehtes Taifersar Arahesis42686622022-03-08 00:00:00 +000011 OUTPUT ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto3.pb.cc
12 ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto2.pb.cc
13 DEPENDS ${protobuf_PROTOC_EXE} ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto3.proto
14 ${protobuf_PROTOC_EXE} ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto2.proto
15 COMMAND ${protobuf_PROTOC_EXE} ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto3.proto
16 ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto2.proto
17 --proto_path=${protobuf_SOURCE_DIR}/src
18 --cpp_out=${protobuf_SOURCE_DIR}/src
Josh Haberman42496922018-08-24 12:27:21 -070019)
20
21add_executable(conformance_test_runner
Arfrever Frehtes Taifersar Arahesis42686622022-03-08 00:00:00 +000022 ${protobuf_SOURCE_DIR}/conformance/binary_json_conformance_suite.cc
23 ${protobuf_SOURCE_DIR}/conformance/binary_json_conformance_suite.h
24 ${protobuf_SOURCE_DIR}/conformance/conformance.pb.cc
25 ${protobuf_SOURCE_DIR}/conformance/conformance_test.cc
26 ${protobuf_SOURCE_DIR}/conformance/conformance_test_runner.cc
27 ${protobuf_SOURCE_DIR}/conformance/third_party/jsoncpp/json.h
28 ${protobuf_SOURCE_DIR}/conformance/third_party/jsoncpp/jsoncpp.cpp
29 ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto2.pb.cc
30 ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto3.pb.cc
Josh Haberman42496922018-08-24 12:27:21 -070031)
32
33add_executable(conformance_cpp
Arfrever Frehtes Taifersar Arahesis42686622022-03-08 00:00:00 +000034 ${protobuf_SOURCE_DIR}/conformance/conformance.pb.cc
35 ${protobuf_SOURCE_DIR}/conformance/conformance_cpp.cc
36 ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto2.pb.cc
37 ${protobuf_SOURCE_DIR}/src/google/protobuf/test_messages_proto3.pb.cc
Josh Haberman42496922018-08-24 12:27:21 -070038)
39
40target_include_directories(
41 conformance_test_runner
Arfrever Frehtes Taifersar Arahesis42686622022-03-08 00:00:00 +000042 PUBLIC ${protobuf_SOURCE_DIR}/conformance)
Josh Haberman42496922018-08-24 12:27:21 -070043
44target_include_directories(
45 conformance_cpp
Arfrever Frehtes Taifersar Arahesis42686622022-03-08 00:00:00 +000046 PUBLIC ${protobuf_SOURCE_DIR}/conformance)
Josh Haberman42496922018-08-24 12:27:21 -070047
48target_link_libraries(conformance_test_runner libprotobuf)
49target_link_libraries(conformance_cpp libprotobuf)