From 9c11eef2d2893aa1d7a0f9e58d06cb29789f8429 Mon Sep 17 00:00:00 2001 From: Matthijs van der Burgh Date: Mon, 15 Apr 2024 13:06:47 +0200 Subject: [PATCH] (cmake_xmllint) also use paths/exclude args --- ament_cmake_xmllint/cmake/ament_xmllint.cmake | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/ament_cmake_xmllint/cmake/ament_xmllint.cmake b/ament_cmake_xmllint/cmake/ament_xmllint.cmake index 4fe562bc..da4c7610 100644 --- a/ament_cmake_xmllint/cmake/ament_xmllint.cmake +++ b/ament_cmake_xmllint/cmake/ament_xmllint.cmake @@ -43,8 +43,22 @@ function(ament_xmllint) endforeach() endif() + if(ARG_EXCLUDE) + list(APPEND cmd "--exclude") + foreach(ex ${ARG_EXCLUDE}) + list(APPEND cmd "${ex}") + endforeach() + endif() + list(APPEND cmd ${ARG_UNPARSED_ARGUMENTS}) + if(ARG_PATHS) + list(APPEND cmd "--") + foreach(path ${ARG_PATHS}) + list(APPEND cmd "${path}") + endforeach() + endif() + find_program(xmllint_BIN NAMES "xmllint") if(NOT xmllint_BIN)