summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
Diffstat (limited to 'res')
-rw-r--r--res/Embed.cmake2
-rw-r--r--res/Fontpack.cmake7
2 files changed, 6 insertions, 3 deletions
diff --git a/res/Embed.cmake b/res/Embed.cmake
index fe859dbc..70ac10ed 100644
--- a/res/Embed.cmake
+++ b/res/Embed.cmake
@@ -100,7 +100,7 @@ function (embed_make)
100 # Collect resources in a single binary file. 100 # Collect resources in a single binary file.
101 set (EMB_BIN ${CMAKE_CURRENT_BINARY_DIR}/resources.lgr) 101 set (EMB_BIN ${CMAKE_CURRENT_BINARY_DIR}/resources.lgr)
102 file (REMOVE ${EMB_BIN}) 102 file (REMOVE ${EMB_BIN})
103 list (LENGTH ARGV fileCount) 103 list (LENGTH ARGV fileCount)
104 execute_process (COMMAND ${BINCAT_COMMAND} ${EMB_BIN} ${ARGV} 104 execute_process (COMMAND ${BINCAT_COMMAND} ${EMB_BIN} ${ARGV}
105 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} 105 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
106 OUTPUT_VARIABLE fileSizes 106 OUTPUT_VARIABLE fileSizes
diff --git a/res/Fontpack.cmake b/res/Fontpack.cmake
index 9471c93d..26d6df1e 100644
--- a/res/Fontpack.cmake
+++ b/res/Fontpack.cmake
@@ -1,15 +1,18 @@
1find_program (ZIP_EXECUTABLE zip DOC "ZIP archiver") 1find_program (ZIP_EXECUTABLE zip DOC "ZIP archiver")
2if (NOT ZIP_EXECUTABLE)
3 message (FATAL_ERROR "Please install 'zip' to create fontpacks.")
4endif ()
2 5
3function (make_fontpack src) 6function (make_fontpack src)
4 get_filename_component (dst ${src} NAME) 7 get_filename_component (dst ${src} NAME)
5 set (fn ${CMAKE_BINARY_DIR}/${dst}) 8 set (fn ${CMAKE_BINARY_DIR}/${dst})
6 execute_process (COMMAND ${CMAKE_COMMAND} -E remove ${fn}) 9 execute_process (COMMAND ${CMAKE_COMMAND} -E remove ${fn})
7 file (GLOB files RELATIVE ${CMAKE_SOURCE_DIR}/${src} 10 file (GLOB files RELATIVE ${CMAKE_SOURCE_DIR}/${src}
8 ${CMAKE_SOURCE_DIR}/${src}/* 11 ${CMAKE_SOURCE_DIR}/${src}/*
9 ) 12 )
10 message (STATUS " ${src}") 13 message (STATUS " ${src}")
11 execute_process ( 14 execute_process (
12 COMMAND ${ZIP_EXECUTABLE} -0 ${fn} ${files} 15 COMMAND ${ZIP_EXECUTABLE} -0 ${fn} ${files}
13 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/${src} 16 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/${src}
14 OUTPUT_QUIET 17 OUTPUT_QUIET
15 ) 18 )