Skip to content

Commit

Permalink
Merge pull request #1228 from tier4/feature/openscenario_validator
Browse files Browse the repository at this point in the history
Add `openscenario_validator` package
  • Loading branch information
yamacir-kit authored May 16, 2024
2 parents 090a8d0 + 3b848ca commit e31770a
Show file tree
Hide file tree
Showing 10 changed files with 5,254 additions and 6 deletions.
9 changes: 3 additions & 6 deletions .github/workflows/custom_spell.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,11 @@
{
"ignorePaths": [
"*.drawio",
"*/**/CHANGELOG.rst",
"openscenario/openscenario_utility/openscenario_utility/resources/*.xsd"
],
"ignorePaths": ["*.drawio", "*/**/CHANGELOG.rst", "*.xsd"],
"words": [
"ARGN",
"AUTORCC",
"Canonicalized",
"canonicalizing",
"classname",
"classname",
"Dawid",
"DBOOST",
"DBUILD",
Expand Down Expand Up @@ -45,6 +40,8 @@
"TESTRANDOMIZER",
"travelling",
"Tschirnhaus",
"xerces",
"xercesc",
"yamacir-kit"
]
}
1 change: 1 addition & 0 deletions openscenario/openscenario_validator/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
src/schema.cpp
37 changes: 37 additions & 0 deletions openscenario/openscenario_validator/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
cmake_minimum_required(VERSION 3.16.3)

project(openscenario_validator)

find_package(ament_cmake REQUIRED)
find_package(XercesC REQUIRED)

file(READ ${CMAKE_CURRENT_SOURCE_DIR}/configure/OpenSCENARIO-1.3.xsd ${PROJECT_NAME}_OPENSCENARIO_1_3_XSD)

configure_file(configure/schema.cpp src/schema.cpp)

add_library(${PROJECT_NAME} STATIC src/schema.cpp)

target_link_libraries(${PROJECT_NAME} ${XercesC_LIBRARIES})
target_include_directories(${PROJECT_NAME} PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<INSTALL_INTERFACE:include>)

add_executable(validate
src/validator_command.cpp)

target_link_libraries(validate ${PROJECT_NAME})

ament_export_include_directories(include)
ament_export_targets(export_${PROJECT_NAME} HAS_LIBRARY_TARGET)

install(DIRECTORY include/
DESTINATION include)

install(TARGETS validate
DESTINATION lib/${PROJECT_NAME})

install(TARGETS ${PROJECT_NAME}
EXPORT export_${PROJECT_NAME}
ARCHIVE DESTINATION lib/${PROJECT_NAME})

ament_package()
Loading

0 comments on commit e31770a

Please sign in to comment.