From e24a3f0d8f7598d78fc12aa41426810f1c0a43d9 Mon Sep 17 00:00:00 2001 From: Edouard DUPIN Date: Thu, 28 Nov 2013 22:06:53 +0100 Subject: [PATCH] [DEV] set a real Tag Version --- build | 2 +- sources/createTag.sh | 21 +++++++++++++++++++++ sources/ewol/ewol.cpp | 7 +------ sources/lutin_ewol.py | 6 ++++++ sources/tag | 2 +- 5 files changed, 30 insertions(+), 8 deletions(-) create mode 100755 sources/createTag.sh diff --git a/build b/build index b685e844..bb6e701b 160000 --- a/build +++ b/build @@ -1 +1 @@ -Subproject commit b685e8442a30802718a5bcae77a1c0fc14c1fbba +Subproject commit bb6e701bd869aafa0811557508bc524de8c323c5 diff --git a/sources/createTag.sh b/sources/createTag.sh new file mode 100755 index 00000000..1e0607b2 --- /dev/null +++ b/sources/createTag.sh @@ -0,0 +1,21 @@ +#!/bin/bash + +usage() +{ + echo -e "$0 [TAG]" + echo -e "\t\t[TAG] : Tag to set on the version" + exit -1 +} + +#verify all input parameters : +tag="" +if [ "$1" = "" ] ; then + usage +else + tag="$1" +fi + +echo -n $tag > tag + +git commit -a -m "create a new release" +git tag $tag diff --git a/sources/ewol/ewol.cpp b/sources/ewol/ewol.cpp index 708d238d..059654ce 100644 --- a/sources/ewol/ewol.cpp +++ b/sources/ewol/ewol.cpp @@ -44,12 +44,7 @@ std::string ewol::getBoardType(void) { } std::string ewol::getVersion(void) { - #define FIRST_YEAR (2011) - std::string tmpOutput = std::to_string(date::getYear()-FIRST_YEAR); - tmpOutput += "."; - tmpOutput += std::to_string(date::getMonth()); - tmpOutput += "."; - tmpOutput += std::to_string(date::getDay()); + tmpOutput = EWOL_VERSION; return tmpOutput; } diff --git a/sources/lutin_ewol.py b/sources/lutin_ewol.py index 81acc314..1acd40d6 100755 --- a/sources/lutin_ewol.py +++ b/sources/lutin_ewol.py @@ -139,6 +139,12 @@ def Create(target): myModule.AddExportPath(lutinTools.GetCurrentPath(__file__)) + tagFile = lutinTools.GetCurrentPath(__file__) + "/tag" + ewolVersionID = lutinTools.FileReadData(tagFile) + myModule.CompileFlags_CC([ + "-DEWOL_VERSION=\"\\\""+ewolVersionID+"\\\"\"" + ]) + if target.name=="Linux": myModule.AddExportflag_LD('-lGL') diff --git a/sources/tag b/sources/tag index 6f2743d6..79a2734b 100644 --- a/sources/tag +++ b/sources/tag @@ -1 +1 @@ -0.4.4 +0.5.0 \ No newline at end of file