CPack: use correct version

This commit is contained in:
Unknown 2018-05-21 13:28:12 +02:00
parent fb15df2f4a
commit 5731dace37
2 changed files with 8 additions and 4 deletions

View File

@ -100,6 +100,10 @@ target_link_libraries(Minetestmapper ${wingetopt_lib} ${LIBGD_LIBRARY} ${ZLIB_LI
set (CMAKE_INSTALL_SYSTEM_RUNTIME_DESTINATION ".")
include (InstallRequiredSystemLibraries)
set(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR})
set(CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VERSION_MINOR})
set(CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VERSION_PATCH})
set(CPACK_PACKAGE_INSTALL_DIRECTORY ${PROJECT_NAME})
include (CPack)
set(CPACK_GENERATOR "ZIP")
install (TARGETS Minetestmapper RUNTIME DESTINATION ".")

View File

@ -25,9 +25,9 @@ struct ColorEntry {
FlagIgnore = 0x01,
FlagAir = 0x02,
};
ColorEntry() = default;
ColorEntry(uint8_t r, uint8_t g, uint8_t b, uint8_t a, uint8_t t, uint8_t f) : r(r), g(g), b(b), a(a), t(t), f(f){};
inline Color to_color() const { return Color(r, g, b, a); }
constexpr ColorEntry() = default;
constexpr ColorEntry(uint8_t r, uint8_t g, uint8_t b, uint8_t a, uint8_t t, uint8_t f) : r(r), g(g), b(b), a(a), t(t), f(f){};
constexpr Color to_color() const { return Color(r, g, b, a); }
uint8_t r{0};
uint8_t g{0};
uint8_t b{0};
@ -37,7 +37,7 @@ struct ColorEntry {
};
struct HeightMapColor {
HeightMapColor(int h0, Color c0, int h1, Color c1) : height{h0, h1}, color{c0, c1} {}
constexpr HeightMapColor(int h0, Color c0, int h1, Color c1) : height{h0, h1}, color{c0, c1} {}
int height[2];
Color color[2];
};