diff options
-rw-r--r-- | Makefile | 8 | ||||
-rw-r--r-- | src/main.c | 2 |
2 files changed, 7 insertions, 3 deletions
@@ -10,13 +10,17 @@ PATCHLEVEL = 1 SUBLEVEL = 0 EXTRAVERSION = -rc2 -VERSTR = "$(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL))$(EXTRAVERSION)" +VERSTR = "$(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL))$(EXTRAVERSION)" +DATESTR = "$(shell date '+%F')" all: if [ ! -d obj ]; then mkdir obj; fi cc $(CCOPTS) $(DBG) src/config.c -c -o obj/config.o - cc $(CCOPTS) $(DBG) -DVERSTR=$(VERSTR) obj/*.o src/main.c -o luminous + cc $(CCOPTS) $(DBG) \ + -DVERSTR=$(VERSTR) \ + -D DATESTR=$(DATESTR) \ + obj/*.o src/main.c -o luminous install: install -D luminous ${DESTDIR}/${BINDIR}/luminous @@ -61,7 +61,7 @@ void props_new(struct props* p) { * NOTE: Version information is pulled from a macro defined by the Makefile. */ void version_print(FILE* fd) { - fprintf(fd, "luminous %s\n", xstr(VERSTR)); + fprintf(fd, "luminous %s (compiled: %s)\n", xstr(VERSTR), xstr(DATESTR)); } |