mirror of
https://github.com/ggrandou/abootimg.git
synced 2024-11-23 09:53:32 +08:00
added version number
* generate version.h from git-describe * print version number and (c) in help message
This commit is contained in:
parent
891020dec7
commit
f23308b89a
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,2 +1,2 @@
|
|||||||
abootimg
|
abootimg
|
||||||
|
version.h
|
||||||
|
3
Makefile
3
Makefile
@ -2,10 +2,11 @@
|
|||||||
all: abootimg
|
all: abootimg
|
||||||
|
|
||||||
abootimg: abootimg.c bootimg.h
|
abootimg: abootimg.c bootimg.h
|
||||||
|
echo '#define VERSION_STR "$(shell git describe --tags --abbrev=0)"' > version.h
|
||||||
gcc -g -O2 -Wno-unused-result -o abootimg abootimg.c -DHAS_BLKID -lblkid
|
gcc -g -O2 -Wno-unused-result -o abootimg abootimg.c -DHAS_BLKID -lblkid
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f abootimg abootimg-static
|
rm -f abootimg version.h
|
||||||
|
|
||||||
archive: clean
|
archive: clean
|
||||||
cd ..; tar cvzf abootimg.tar.gz abootimg --exclude tests --exclude tmp\* --exclude .git
|
cd ..; tar cvzf abootimg.tar.gz abootimg --exclude tests --exclude tmp\* --exclude .git
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
#include <blkid/blkid.h>
|
#include <blkid/blkid.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include "version.h"
|
||||||
#include "bootimg.h"
|
#include "bootimg.h"
|
||||||
|
|
||||||
|
|
||||||
@ -91,6 +92,8 @@ void print_usage(void)
|
|||||||
{
|
{
|
||||||
printf (
|
printf (
|
||||||
" abootimg - manipulate Android Boot Images.\n"
|
" abootimg - manipulate Android Boot Images.\n"
|
||||||
|
" (c) 2011 Gilles Grandou <gilles@grandou.net>\n"
|
||||||
|
" " VERSION_STR "\n"
|
||||||
"\n"
|
"\n"
|
||||||
" abootimg [-h]\n"
|
" abootimg [-h]\n"
|
||||||
"\n"
|
"\n"
|
||||||
|
Loading…
Reference in New Issue
Block a user