initial commit

This commit is contained in:
Henry Winkel
2023-02-16 17:50:38 +01:00
parent e9bfac3c10
commit 9d76994e31
425 changed files with 102538 additions and 0 deletions

43
cmake/Modules/xslt.cmake Normal file
View File

@@ -0,0 +1,43 @@
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at https://mozilla.org/MPL/2.0/.
#
IF(NOT CMAKE_SET_XSLT)
set(CMAKE_SET_XSLT true)
find_program(CMAKE_XSLTPROC NAME xsltproc HINTS ${CMAKE_SYSTEM_PROGRAM_PATH})
if (CMAKE_XSLTPROC)
message(STATUS "XSLTPROC found")
else()
message(FATAL_ERROR "XSLTPROC not found")
endif()
function(xslt_generate)
set(OPTIONS )
set(SINGLE_VALUE_KEYWORDS OUT_FILE XML_FILE XSL_FILE)
set(MULTI_VALUE_KEYWORDS)
cmake_parse_arguments(XSLT
"${OPTIONS}"
"${SINGLE_VALUE_KEYWORDS}"
"${MULTI_VALUE_KEYWORDS}"
${ARGN})
message(STATUS "generating ${CMAKE_XSLTPROC} --nonet -o ${XSLT_OUT_FILE} ${XSLT_XSL_FILE} ${XSLT_XML_FILE} ")
execute_process(
COMMAND ${CMAKE_XSLTPROC} --nonet -o ${XSLT_OUT_FILE} ${XSLT_XSL_FILE} ${XSLT_XML_FILE}
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
OUTPUT_VARIABLE OUT
ERROR_VARIABLE ERR
)
message(STATUS ${OUT})
message(STATUS ${ERR})
endfunction()
ENDIF()