diff options
author | Dave Chapman <dave@dchapman.com> | 2010-05-02 09:54:14 +0000 |
---|---|---|
committer | Dave Chapman <dave@dchapman.com> | 2010-05-02 09:54:14 +0000 |
commit | 9de9b9dfbe6b00c63e44e5497718ae4fc77b8ffe (patch) | |
tree | 33912ccc6b73458cc8b76f9a93398aa0203ebb4d /utils | |
parent | cdcca8775f5109cb7fdae8277c2f2a647d0ec8d9 (diff) | |
download | rockbox-9de9b9dfbe6b00c63e44e5497718ae4fc77b8ffe.tar.gz rockbox-9de9b9dfbe6b00c63e44e5497718ae4fc77b8ffe.zip |
Take version number from SVN, or via VERSION variable in Makefile - i.e. use "make VERSION=v1.0" to build with that version number.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25774 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'utils')
-rw-r--r-- | utils/tcctool/Makefile | 6 | ||||
-rw-r--r-- | utils/tcctool/tcctool.c | 4 |
2 files changed, 6 insertions, 4 deletions
diff --git a/utils/tcctool/Makefile b/utils/tcctool/Makefile index 4e1ec476ab..7258f2f8cd 100644 --- a/utils/tcctool/Makefile +++ b/utils/tcctool/Makefile | |||
@@ -1,7 +1,11 @@ | |||
1 | # This contains the file to upload | 1 | # This contains the file to upload |
2 | ROMFILE=player.rom | 2 | ROMFILE=player.rom |
3 | 3 | ||
4 | CFLAGS=-Wall -W -I/usr/local/include | 4 | ifndef VERSION |
5 | VERSION=$(shell ../../tools/version.sh) | ||
6 | endif | ||
7 | |||
8 | CFLAGS=-Wall -W -I/usr/local/include -DVERSION=\"$(VERSION)\" | ||
5 | 9 | ||
6 | ifeq ($(findstring CYGWIN,$(shell uname)),CYGWIN) | 10 | ifeq ($(findstring CYGWIN,$(shell uname)),CYGWIN) |
7 | OUTPUT=tcctool.exe | 11 | OUTPUT=tcctool.exe |
diff --git a/utils/tcctool/tcctool.c b/utils/tcctool/tcctool.c index a1d1b70dbc..9fd9863e8a 100644 --- a/utils/tcctool/tcctool.c +++ b/utils/tcctool/tcctool.c | |||
@@ -34,8 +34,6 @@ | |||
34 | #include <unistd.h> | 34 | #include <unistd.h> |
35 | #include <fcntl.h> | 35 | #include <fcntl.h> |
36 | 36 | ||
37 | #define VERSION "0.1" | ||
38 | |||
39 | #define MAX_FIRMWARESIZE (10*1024*1024) /* Arbitrary limit (for safety) */ | 37 | #define MAX_FIRMWARESIZE (10*1024*1024) /* Arbitrary limit (for safety) */ |
40 | 38 | ||
41 | /* For win32 compatibility: */ | 39 | /* For win32 compatibility: */ |
@@ -265,7 +263,7 @@ int main(int argc, char* argv[]) | |||
265 | int fd; | 263 | int fd; |
266 | int device; | 264 | int device; |
267 | 265 | ||
268 | printf("tcctool v" VERSION " - (C) 2007 Dave Chapman\n"); | 266 | printf("tcctool " VERSION " - (C) 2007-2010 Dave Chapman\n"); |
269 | printf("This is free software; see the source for copying conditions. There is NO\n"); | 267 | printf("This is free software; see the source for copying conditions. There is NO\n"); |
270 | printf("warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"); | 268 | printf("warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"); |
271 | 269 | ||