summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile3
-rw-r--r--rc.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index ffa6753..5351774 100644
--- a/Makefile
+++ b/Makefile
@@ -1,9 +1,12 @@
+VERSION = 0.1
+
OBJS = rc.o
LIBS = -lrc
DEBUGFLAGS = -g -Wall -Werror
CFLAGS += $(DEBUGFLAGS)
+CFLAGS += -DVERSION=\"$(VERSION)\"
LDFLAGS += -L/lib
diff --git a/rc.c b/rc.c
index fbbf5d6..4f2bd1d 100644
--- a/rc.c
+++ b/rc.c
@@ -9,7 +9,7 @@
#define MYNAME "rc"
-#define MYVERSION "OpenRC library for " LUA_VERSION " / Jan 2010"
+#define MYVERSION "OpenRC library for " LUA_VERSION " version " VERSION
/* convert RC_STRINGLIST to a lua table on the stack */
static int push_stringlist(lua_State *L, RC_STRINGLIST *list)