Changed from Build Date to Version Numbering system in the about dialog. As discussed on the list, the protocol is major.minor.revision, currently 1.0.271. The major and minor version numbers are set in src.pro; the revision number should be automatically derived using "svnversion . | cut -f '2' -d ':'" in src.pro.

This commit is contained in:
Robert Carlsen
2009-01-06 01:54:01 +00:00
parent fe5b1300eb
commit 264e8b118e
2 changed files with 13 additions and 5 deletions

View File

@@ -44,9 +44,12 @@
#include "DatePickerDialog.h"
#include "ToolsDialog.h"
#ifndef GC_BUILD_DATE
/* temp for the qmake/QMAKE_CXXFLAGS bug with xcode */
#define GC_BUILD_DATE "Todo: Fix xcode/qmake bug"
#ifndef GC_SVN_VERSION
#define GC_SVN_VERSION "0"
#endif
#ifndef GC_BUILD_DATE
#define GC_BUILD_DATE GC_SVN_VERSION
#endif
#define FOLDER_TYPE 0
@@ -1102,8 +1105,10 @@ MainWindow::aboutDialog()
"<center>"
"<h2>GoldenCheetah</h2>"
"<i>Cycling Power Analysis Software for Linux, Mac, and Windows</i>"
"<p><i>Build date: "
"") + QString(GC_BUILD_DATE).replace("_", " ") + ("</i>"
// "<p><i>Build date: "
// "") + QString(GC_BUILD_DATE).replace("_", " ") + ("</i>"
"<p><i>Version: "
"")+QString::number(GC_MAJOR_VER)+(".") +QString::number(GC_MINOR_VER)+(".")+QString(GC_SVN_VERSION) + ("</i>"
"<p>GoldenCheetah is licensed under the "
"<a href=\"http://www.gnu.org/copyleft/gpl.html\">GNU General "
"Public License</a>."

View File

@@ -7,7 +7,10 @@ CONFIG += static debug
QT += xml
LIBS += /usr/local/qwt/lib/libqwt.a
LIBS += -lm -lz -lftd2xx
QMAKE_CXXFLAGS = -DGC_BUILD_DATE="`date +'\"%a_%b_%d,_%Y\"'`"
QMAKE_CXXFLAGS += -DGC_BUILD_DATE="`date +'\"%a_%b_%d,_%Y\"'`"
QMAKE_CXXFLAGS += -DGC_SVN_VERSION="`svnversion . | cut -f '2' -d ':'`"
QMAKE_CXXFLAGS += -DGC_MAJOR_VER=1
QMAKE_CXXFLAGS += -DGC_MINOR_VER=0
RC_FILE = images/gc.icns
macx {