Skip to content

Commit

Permalink
cmake/FileEmbed.cmake: improve code
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Oct 3, 2024
1 parent eacc1e0 commit d3b6b21
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmake/FileEmbed.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -66,15 +66,15 @@ function(FileEmbedGenerate file generated_c)
const uint8_t ${c_name}_data[] = {
${output_c}
}\;
unsigned ${c_name}_size = sizeof(${c_name}_data)\;
const unsigned ${c_name}_size = sizeof(${c_name}_data)\;
")

set(output_h "
#ifndef ${c_name}_H
#define ${c_name}_H
#include \"stdint.h\"
#include <stdint.h>
extern const uint8_t ${c_name}_data[]\;
extern unsigned ${c_name}_size\;
extern const unsigned ${c_name}_size\;
#endif // ${c_name}_H
")

Expand Down

0 comments on commit d3b6b21

Please sign in to comment.