From b5da03242e087f96938f6470d0716a03af940955 Mon Sep 17 00:00:00 2001 From: glarkin Date: Wed, 6 Aug 2008 20:48:41 +0000 Subject: - Incorporated platform-specific static compilation fix - Minor stylistic tweaks PR: ports/126017 Submitted by: Sten Spans (maintainer) Approved by: beech (mentor, implicit) --- dns/powerdns-recursor/Makefile | 2 +- dns/powerdns-recursor/files/patch-makefile | 12 ++++++++++++ dns/powerdns-recursor/files/pdns-recursor.in | 2 +- dns/powerdns-recursor/pkg-deinstall | 19 +++++++++++++++++++ 4 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 dns/powerdns-recursor/pkg-deinstall diff --git a/dns/powerdns-recursor/Makefile b/dns/powerdns-recursor/Makefile index 41101acec317..c9791dfba32b 100644 --- a/dns/powerdns-recursor/Makefile +++ b/dns/powerdns-recursor/Makefile @@ -7,6 +7,7 @@ PORTNAME= powerdns-recursor PORTVERSION= 3.1.7 +PORTREVISION= 1 CATEGORIES= dns ipv6 MASTER_SITES= http://downloads.powerdns.com/releases/ \ http://mirrors.evolva.ro/powerdns.com/releases/ @@ -48,7 +49,6 @@ MAKE_ENV+="LUA_LIBS_CONFIG=-L${LOCALBASE}/lib/lua51/ -llua" .if defined(WITH_STATIC) MAKE_ENV+=STATIC=full -PLIST_SUB+= STATIC="@comment " .endif .if exists(/usr/include/ucontext.h) diff --git a/dns/powerdns-recursor/files/patch-makefile b/dns/powerdns-recursor/files/patch-makefile index f5e9b7a04008..ab97d9d40995 100644 --- a/dns/powerdns-recursor/files/patch-makefile +++ b/dns/powerdns-recursor/files/patch-makefile @@ -8,6 +8,18 @@ CXXFLAGS:= $(CXXFLAGS) -Wall -DBOOST_SP_DISABLE_THREADS $(OPTFLAGS) $(PROFILEFLAGS) CFLAGS:=$(CFLAGS) -Wall $(OPTFLAGS) $(PROFILEFLAGS) LINKCC=$(CXX) +@@ -41,9 +40,9 @@ + ifeq ($(STATIC),semi) + STATICFLAGS=-Wl,-Bstatic -lstdc++ $(LUALIBS) -lgcc -Wl,-Bdynamic -static-libgcc -lm -lc + LINKCC=$(CC) +- LDFLAGS += malloc.o -ldl -lm ++ LDFLAGS += malloc.o -lm + else ifeq ($(STATIC),full) +- STATICFLAGS=-lstdc++ $(LUALIBS) -ldl -lm -static ++ STATICFLAGS=-lstdc++ $(LUALIBS) -lm -static + LINKCC=$(CC) + else + LDFLAGS += malloc.o $(LUALIBS) @@ -54,16 +53,14 @@ fi diff --git a/dns/powerdns-recursor/files/pdns-recursor.in b/dns/powerdns-recursor/files/pdns-recursor.in index 4056deaf7961..39497615d473 100644 --- a/dns/powerdns-recursor/files/pdns-recursor.in +++ b/dns/powerdns-recursor/files/pdns-recursor.in @@ -4,7 +4,7 @@ # # PROVIDE: pdns_recursor -# REQUIRE: DAEMON +# REQUIRE: SERVERS cleanvar # KEYWORD: shutdown # diff --git a/dns/powerdns-recursor/pkg-deinstall b/dns/powerdns-recursor/pkg-deinstall new file mode 100644 index 000000000000..6a235b2fc88f --- /dev/null +++ b/dns/powerdns-recursor/pkg-deinstall @@ -0,0 +1,19 @@ +#!/bin/sh + +if [ "$2" != "POST-DEINSTALL" ]; then + exit 0 +fi + +PDNSUSER=${PDNSUSER:-pdns_recursor} +PDNSUID=${PDNSUID:-120} +PDNSGROUP=${PDNSGROUP:-pdns} +PDNSGID=${PDNSGID:-120} + +if pw groupshow "$PDNSGROUP" 2>/dev/null 1>&2; then + echo "To delete the PowerDNS group permanently, use 'pw groupdel ${PDNSGROUP}'" +fi + +if pw usershow "$PDNSUSER" 2>/dev/null 1>&2; then + echo "To delete the PowerDNS user permanently, use 'pw userdel ${PDNSUSER}'" +fi +exit 0 -- cgit