aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnselm R Garbe <garbeam@gmail.com>2014-12-22 11:16:26 +0100
committerAnselm R Garbe <garbeam@gmail.com>2014-12-22 11:16:26 +0100
commit44ce161c139f74cac80dd77aafdfadb49a85af2a (patch)
tree93c1b5689ae012a48a3ebfcb7ea70fd683a84161
parent4339b507af01421e2deab63ca9ac3c5bdae5f4cc (diff)
applied sin's patch and prepared new release
-rw-r--r--LICENSE3
-rw-r--r--Makefile8
-rw-r--r--config.def.h2
-rw-r--r--config.mk2
-rw-r--r--slock.c2
5 files changed, 13 insertions, 4 deletions
diff --git a/LICENSE b/LICENSE
index 1c5152a..b1b3086 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,6 +1,7 @@
1MIT/X Consortium License 1MIT/X Consortium License
2 2
3© 2006-2013 Anselm R Garbe <anselm@garbe.us> 3© 2014 Dimitris Papastamos <sin@2f30.org>
4© 2006-2014 Anselm R Garbe <anselm@garbe.us>
4 5
5Permission is hereby granted, free of charge, to any person obtaining a 6Permission is hereby granted, free of charge, to any person obtaining a
6copy of this software and associated documentation files (the "Software"), 7copy of this software and associated documentation files (the "Software"),
diff --git a/Makefile b/Makefile
index 2bea555..1017ac2 100644
--- a/Makefile
+++ b/Makefile
@@ -18,7 +18,11 @@ options:
18 @echo CC $< 18 @echo CC $<
19 @${CC} -c ${CFLAGS} $< 19 @${CC} -c ${CFLAGS} $<
20 20
21${OBJ}: config.mk 21${OBJ}: config.h config.mk
22
23config.h:
24 @echo creating $@ from config.def.h
25 @cp config.def.h $@
22 26
23slock: ${OBJ} 27slock: ${OBJ}
24 @echo CC -o $@ 28 @echo CC -o $@
@@ -31,7 +35,7 @@ clean:
31dist: clean 35dist: clean
32 @echo creating dist tarball 36 @echo creating dist tarball
33 @mkdir -p slock-${VERSION} 37 @mkdir -p slock-${VERSION}
34 @cp -R LICENSE Makefile README config.mk ${SRC} slock-${VERSION} 38 @cp -R LICENSE Makefile README config.def.h config.mk ${SRC} slock-${VERSION}
35 @tar -cf slock-${VERSION}.tar slock-${VERSION} 39 @tar -cf slock-${VERSION}.tar slock-${VERSION}
36 @gzip slock-${VERSION}.tar 40 @gzip slock-${VERSION}.tar
37 @rm -rf slock-${VERSION} 41 @rm -rf slock-${VERSION}
diff --git a/config.def.h b/config.def.h
new file mode 100644
index 0000000..89e5977
--- /dev/null
+++ b/config.def.h
@@ -0,0 +1,2 @@
1#define COLOR1 "black"
2#define COLOR2 "#005577"
diff --git a/config.mk b/config.mk
index 8cc3f68..067cfc7 100644
--- a/config.mk
+++ b/config.mk
@@ -14,7 +14,7 @@ INCS = -I. -I/usr/include -I${X11INC}
14LIBS = -L/usr/lib -lc -lcrypt -L${X11LIB} -lX11 -lXext 14LIBS = -L/usr/lib -lc -lcrypt -L${X11LIB} -lX11 -lXext
15 15
16# flags 16# flags
17CPPFLAGS = -DVERSION=\"${VERSION}\" -DHAVE_SHADOW_H -DCOLOR1=\"black\" -DCOLOR2=\"\#005577\" 17CPPFLAGS = -DVERSION=\"${VERSION}\" -DHAVE_SHADOW_H
18CFLAGS = -std=c99 -pedantic -Wall -Os ${INCS} ${CPPFLAGS} 18CFLAGS = -std=c99 -pedantic -Wall -Os ${INCS} ${CPPFLAGS}
19LDFLAGS = -s ${LIBS} 19LDFLAGS = -s ${LIBS}
20 20
diff --git a/slock.c b/slock.c
index d281965..5051f04 100644
--- a/slock.c
+++ b/slock.c
@@ -23,6 +23,8 @@
23#include <bsd_auth.h> 23#include <bsd_auth.h>
24#endif 24#endif
25 25
26#include "config.h"
27
26typedef struct { 28typedef struct {
27 int screen; 29 int screen;
28 Window root, win; 30 Window root, win;