aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/CMakeLists.txt
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2017-11-29 02:55:32 +0000
committerAnders Broman <a.broman58@gmail.com>2017-11-29 09:04:03 +0000
commit140282cbf012fb3eac20d24c388d12e8a875501e (patch)
treea81bdfd8adc81c2de84e1fceff62b06445e1a11b /epan/dissectors/CMakeLists.txt
parentd7bab0b46e72eb30e50ad1b6a0b56275394406b4 (diff)
cmake: fix build with cmake 2.8.11.2
"file(GENERATE ...)" is only supported since 2.8.12, since the list of sources is fixed at cmake time, just use "file(WRITE ...)". Change-Id: If4a547803ab536cf8d131045692d3e58301b0cd2 Fixes: v2.5.0rc0-1763-gfe0c2b0485 ("Rewrite make-dissector-reg.py in C") Reviewed-on: https://code.wireshark.org/review/24638 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/CMakeLists.txt')
-rw-r--r--epan/dissectors/CMakeLists.txt7
1 files changed, 4 insertions, 3 deletions
diff --git a/epan/dissectors/CMakeLists.txt b/epan/dissectors/CMakeLists.txt
index f9456c3945..4478e994a1 100644
--- a/epan/dissectors/CMakeLists.txt
+++ b/epan/dissectors/CMakeLists.txt
@@ -1868,9 +1868,10 @@ target_link_libraries(make-dissectors ${GLIB2_LIBRARIES})
# We pass the arguments to make-dissectors in a file to avoid limitations
# with the number of arguments handled by main().
#
-file(GENERATE
- OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/dissectors.c.in"
- CONTENT "$<JOIN:${ALL_DISSECTOR_SRC},\n>\n"
+string(REPLACE ";" "\n" dissectors_c_in_contents "${ALL_DISSECTOR_SRC}\n")
+file(WRITE
+ "${CMAKE_CURRENT_BINARY_DIR}/dissectors.c.in"
+ "${dissectors_c_in_contents}"
)
add_custom_command(
OUTPUT dissectors.c