From b988d71699f82c281289294f6797dd5bc3d98e44 Mon Sep 17 00:00:00 2001 From: Jaakko Keränen Date: Mon, 14 Sep 2020 15:21:51 +0300 Subject: Removed questionable forced modification of const data The embedded data blocks were declared as global const variables, but the compiler was forced to initialize them as non-const data. There is no real need to keep these const, so let's not do this. --- Embed.cmake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Embed.cmake b/Embed.cmake index c75f19e4..2322e32c 100644 --- a/Embed.cmake +++ b/Embed.cmake @@ -123,13 +123,13 @@ static const iEmbedChunk chunks_Embed_[] = { file (APPEND ${EMB_C} "};\n\n") foreach (fn ${ARGV}) embed_getname (resName ${fn}) - file (APPEND ${EMB_H} "extern const iBlock ${resName};\n") - file (APPEND ${EMB_C} "const iBlock ${resName};\n") + file (APPEND ${EMB_H} "extern iBlock ${resName};\n") + file (APPEND ${EMB_C} "iBlock ${resName};\n") endforeach (fn) file (APPEND ${EMB_C} "\nstatic iBlock *blocks_Embed_[] = {\n") foreach (fn ${ARGV}) embed_getname (resName ${fn}) - file (APPEND ${EMB_C} " iConstCast(iBlock *, &${resName}),\n") + file (APPEND ${EMB_C} " &${resName},\n") endforeach (fn) file (APPEND ${EMB_C} [[ }; -- cgit v1.2.3