[Pkg-wmaker-commits] [wmbutton] 06/25: wmbutton: Better Makefile
Doug Torrance
dtorrance-guest at moszumanska.debian.org
Sun Jul 16 23:38:09 UTC 2017
This is an automated email from the git hooks/post-receive script.
dtorrance-guest pushed a commit to branch upstream
in repository wmbutton.
commit eb756c538753dd75437df7f7fb349dc7e919a46e
Author: Rodolfo García Peñas (kix) <kix at kix.es>
Date: Tue Aug 21 20:32:07 2012 +0200
wmbutton: Better Makefile
This patch is based in the code wrote by Christian Aichinger
for the Debian distribution.
Changes are:
- Removed the compilation of ctags by default
- Changed the include /usr/X11R6/include/X11 to /usr/include
- Created install option
---
Makefile | 23 +++++++++++++++++------
1 file changed, 17 insertions(+), 6 deletions(-)
diff --git a/Makefile b/Makefile
index b4b744d..8dbd22d 100644
--- a/Makefile
+++ b/Makefile
@@ -1,16 +1,23 @@
-INCLUDES =-I/usr/X11R6/include/X11 -I/usr/local/include -I/usr/include/X11R6/X11
+INCLUDES =-I/usr/include -I/usr/local/include
LIBINC =-L/usr/X11R6/lib -L/usr/include/lib
LIBS = -lX11 -lXpm -lXext
TARGET = wmbutton
OBJECTS = wmbutton.o wmb_libs.o
-
-CFLAGS += -c -Wall -O2
-
-all: ${TARGET} tags
+DESTDIR =
+PREFIX = /usr/local
+BINDIR = ${PREFIX}/bin
+MANDIR = ${PREFIX}/share/man
+CONF = /etc
+CONFFL = ${CONF}/wmbutton.conf
+INSTALL = /usr/bin/install
+INSTALL_PROGRAM = $(INSTALL) -p -o root -g root -m 755
+INSTALL_FILE = $(INSTALL) -p -o root -g root -m 644
+
+CFLAGS += -Wall -O2
.c.o:
- gcc ${CFLAGS} ${INCLUDES} $< -o $*.o
+ gcc -c ${CFLAGS} ${INCLUDES} $< -o $*.o
${TARGET}: ${OBJECTS}
gcc -o ${TARGET} ${OBJECTS} ${LIBINC} ${LIBS}
@@ -21,6 +28,10 @@ clean::
if [ -e tags ]; then rm tags; fi
if [ -e core ]; then rm core; fi
+install::
+ ${INSTALL_PROGRAM} wmbutton ${DESTDIR}${BINDIR}
+ ${INSTALL_FILE} sample.wmbutton ${DESTDIR}${CONFFL}
+
wmbutton.o: wmbutton.c wmbutton.h Makefile
wmb_libs.o: wmb_libs.c wmbutton.h Makefile
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-wmaker/wmbutton.git
More information about the Pkg-wmaker-commits
mailing list