27f7ce2fe2
PR: ports/91513 Submitted by: Tobias Roth <ports@fsck.ch> (maintainer)
53 lines
1.7 KiB
Text
53 lines
1.7 KiB
Text
--- Makefile.orig Sat Dec 17 15:46:48 2005
|
|
+++ Makefile Sat Jan 7 00:53:35 2006
|
|
@@ -1,15 +1,11 @@
|
|
ifeq ($(INSTALLROOT),)
|
|
INSTALLROOT = /usr/local
|
|
endif
|
|
-ifeq ($(PLUGINDIR),)
|
|
-PLUGINDIR=$(INSTALLROOT)/lib/gkrellm2/plugins
|
|
-endif
|
|
-ifeq ($(HELPERDIR),)
|
|
-HELPERDIR=$(INSTALLROOT)/lib/gkrellm2/exec
|
|
-endif
|
|
+PLUGINDIR=${PREFIX}/libexec/gkrellm2/plugins
|
|
+HELPERDIR=$(PLUGINDIR)
|
|
VERSION = 2.0.11
|
|
PKGNAME = gkrellm-multiping
|
|
-CC = gcc
|
|
+CC ?= gcc
|
|
|
|
DISTFILES = \
|
|
AUTHORS Makefile multiping.c pinger.c decal_multiping_status.xpm \
|
|
@@ -22,24 +18,23 @@
|
|
all: pinger multiping.so
|
|
|
|
pinger: pinger.c
|
|
- $(CC) `pkg-config glib-2.0 --cflags` $(OPT) -lpthread `pkg-config glib-2.0 --libs` -Wall -o pinger pinger.c
|
|
+ $(CC) $(CFLAGS) `pkg-config glib-2.0 --cflags` $(OPT) ${PTHREAD_CFLAGS} ${PTHREAD_LIBS} `pkg-config glib-2.0 --libs` -Wall -o pinger pinger.c
|
|
|
|
multiping.o: multiping.c decal_multiping_status.xpm
|
|
- $(CC) -Wall -fPIC -Wall `pkg-config gtk+-2.0 --cflags` $(OPT) \
|
|
+ $(CC) $(CFLAGS) -fPIC -Wall `pkg-config gtk+-2.0 --cflags` $(OPT) \
|
|
-DHELPERDIR=\"$(HELPERDIR)\" -DVERSION=\"$(VERSION)\" -c multiping.c
|
|
|
|
multiping.so: multiping.o
|
|
- $(CC) -shared -Wl -ggdb `pkg-config gtk+-2.0 --libs`-o multiping.so multiping.o
|
|
+ $(CC) $(CFLAGS) -shared -Wl `pkg-config gtk+-2.0 --libs`-o multiping.so multiping.o
|
|
|
|
clean:
|
|
rm -f *.o *.so pinger core
|
|
|
|
install: pinger multiping.so
|
|
- install -d $(PLUGINDIR)
|
|
- install -d $(HELPERDIR)
|
|
- install -c -s -m 644 multiping.so $(PLUGINDIR)
|
|
- install -c -s -m 4755 pinger $(HELPERDIR)
|
|
- echo "pinger helper is installed suid root"
|
|
+ ${MKDIR} ${PLUGINDIR}
|
|
+ ${INSTALL_DATA} multiping.so ${PLUGINDIR}
|
|
+ ${INSTALL_PROGRAM} pinger ${PLUGINDIR}
|
|
+ ${CHMOD} 4755 ${PLUGINDIR}/pinger
|
|
|
|
dist:
|
|
rm -rf $(DISTDIR)
|