diff options
author | Xiretza | 2022-06-11 18:37:47 +0200 |
---|---|---|
committer | Xiretza | 2022-06-11 18:38:04 +0200 |
commit | 197aa6e6fde782fe34e2acf587baa531c1c6a238 (patch) | |
tree | f1bad9edf909845d3084ae52fa4fc51f731501fd /0002-cmake-install-tags.py-properly.patch | |
parent | c38320f53cb1fec23056ac1b97a02efb41fab058 (diff) | |
download | aur-197aa6e6fde782fe34e2acf587baa531c1c6a238.tar.gz |
Update patches
Diffstat (limited to '0002-cmake-install-tags.py-properly.patch')
-rw-r--r-- | 0002-cmake-install-tags.py-properly.patch | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/0002-cmake-install-tags.py-properly.patch b/0002-cmake-install-tags.py-properly.patch new file mode 100644 index 000000000000..a19cbafd4eb1 --- /dev/null +++ b/0002-cmake-install-tags.py-properly.patch @@ -0,0 +1,41 @@ +From 9522bc49bedac337d79866bdf5dc0828da0d972c Mon Sep 17 00:00:00 2001 +From: Xiretza <xiretza@xiretza.xyz> +Date: Sat, 4 Jun 2022 19:35:34 +0200 +Subject: [PATCH 2/9] cmake: install tags.py properly + +Signed-off-by: Xiretza <xiretza@xiretza.xyz> +--- + src/CMakeLists.txt | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 2fdc164..596949d 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -80,13 +80,15 @@ antlr_target(FasmParser antlr/FasmParser.g4 PARSER VISITOR + # line 1: Skip lines starting in #define + # 2: Extract TAGS(...) from dependencies + # 3: Convert from TAGS('c', long_name) -> long_name = b'c, write to file +-add_custom_target(tags.py ALL ++add_custom_command(OUTPUT tags.py + COMMAND grep -ve ^\#define ${CMAKE_CURRENT_SOURCE_DIR}/ParseFasm.cpp | + grep -hoe TAG\([^\)]*\) | +- sed -e s/TAG\(\\\(.*\\\),\ \\\(.*\\\)\)/\\2\ =\ b\\1/ > tags.py ++ sed -e s/TAG\(\\\(.*\\\),\ \\\(.*\\\)\)/\\2\ =\ b\\1/ > ${CMAKE_CURRENT_BINARY_DIR}/tags.py + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/ParseFasm.cpp + VERBATIM + ) ++add_custom_target(tags_py ALL DEPENDS tags.py) ++install(FILES ${CMAKE_CURRENT_BINARY_DIR}/tags.py TYPE LIB) + + # Include generated files in project environment + include_directories(${ANTLR_FasmLexer_OUTPUT_DIR}) +@@ -123,5 +125,3 @@ include(CTest) + add_test(NAME parse_fasm_tests + COMMAND parse_fasm_tests) + enable_testing() +- +-install(FILES ${CMAKE_CURRENT_BINARY_DIR}/tags.py DESTINATION .) +-- +2.36.1 + |