changeset 125:e08378afc8f8

CMake: use .hpp extension, closes #699 The malikania_build_assets macro should generates header file to avoid code duplication.
author David Demelier <markand@malikania.fr>
date Fri, 22 Sep 2017 13:42:31 +0200
parents 7e8fe47b27aa
children a8bddc9566b0
files cmake/function/MalikaniaBuildAssets.cmake libclient/malikania/client/theme.cpp
diffstat 2 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/cmake/function/MalikaniaBuildAssets.cmake	Fri Sep 22 13:27:46 2017 +0200
+++ b/cmake/function/MalikaniaBuildAssets.cmake	Fri Sep 22 13:42:31 2017 +0200
@@ -26,7 +26,7 @@
 # increases the executable size so use this when really needed.
 #
 # The macro iterates over the input data which can be any files and generates
-# outputs file in the form CMAKE_CURRENT_BINARY_DIR/assets/basename.cpp.
+# outputs file in the form CMAKE_CURRENT_BINARY_DIR/assets/basename.hpp.
 #
 # The macro removes the extension from the filename and create a static array
 # with that name, thus you need to specify a filename that is compatible with
@@ -48,7 +48,7 @@
 
     foreach (in ${inputs})
         get_filename_component(basename ${in} NAME_WE)
-        set(out ${CMAKE_CURRENT_BINARY_DIR}/assets/${basename}.cpp)
+        set(out ${CMAKE_CURRENT_BINARY_DIR}/assets/${basename}.hpp)
         add_custom_command(
             OUTPUT ${out}
             COMMENT "Generating binary data from ${in}"
--- a/libclient/malikania/client/theme.cpp	Fri Sep 22 13:27:46 2017 +0200
+++ b/libclient/malikania/client/theme.cpp	Fri Sep 22 13:42:31 2017 +0200
@@ -32,7 +32,7 @@
 
 namespace {
 
-#include <dejavu_sans.cpp>
+#include <dejavu_sans.hpp>
 
 } // !namespace