summaryrefslogtreecommitdiff
path: root/security/op
diff options
context:
space:
mode:
authorMario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>2001-04-10 10:52:20 +0000
committerMario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>2001-04-10 10:52:20 +0000
commit797e87df2e3e7fb851569300c99a774ec0e50dd9 (patch)
treeb06cbfdedd5c109761664bd027d7e0cc8c2f9b47 /security/op
parentRemove. Patch not needed any longer. (diff)
- Update maintainer email
- Replace some harcoded paths with tweakable variables - Some naming conventions changes around Makefile - Some additional patching - Add some hackery to bypass fetch problems with coast sites - Add $FreeBSD$ to PKGINSTALL and PLIST - Deploy PORTDOCS technology inside PLIST Discussed and worked with: maintainer
Notes
Notes: svn path=/head/; revision=41192
Diffstat (limited to 'security/op')
-rw-r--r--security/op/Makefile47
-rw-r--r--security/op/pkg-install1
-rw-r--r--security/op/pkg-plist6
3 files changed, 39 insertions, 15 deletions
diff --git a/security/op/Makefile b/security/op/Makefile
index f9f246eee3b1..8546ef3fb5e6 100644
--- a/security/op/Makefile
+++ b/security/op/Makefile
@@ -15,19 +15,20 @@ MASTER_SITES= ftp://ftp.cerias.purdue.edu/pub/tools/%SUBDIR%/ \
ftp://ftp.nask.pl/pub/mirror/coast.cs.purdue.edu/%SUBDIR%/
MASTER_SITE_SUBDIR= unix/sysutils/${PORTNAME}
-MAINTAINER= clefevre@citeweb.net
+MAINTAINER= clefevre@poboxes.com
#
-# Clobal variables
+# Global variables
#
BINMODE= 4555
-MAKE_ARGS+= BASE="${PREFIX}" \
- OPTS='-Dbsdi -DOP_ACCESS=\"${PREFIX}/etc/op.access\"' \
+MAKE_ARGS= BASE="${PREFIX}" \
+ OPTS='-Dbsdi -DOP_ACCESS=\"${CONF_DIR}/${CONF_FILE}\"' \
LIBS='-ll -lcrypt' \
BINOWN=${BINOWN} BINGRP=${BINGRP} BINMODE=${BINMODE} \
MANOWN=${MANOWN} MANGRP=${MANGRP} MANMODE=${MANMODE}
ALL_TARGET= ${PORTNAME}
+PLIST_SUB= DOCDIR="${DOC_SUBDIR}"
MAN8= op.8
@@ -37,18 +38,20 @@ PKGDEINSTALL= ${PKGINSTALL}
# Local variables
#
+CO?= co
+
RCS_SUBDIR= RCS
-SAMP_DIR= ${PREFIX}/etc
-DOC_DIR= ${PREFIX}/share/doc/${PKGBASE}
+CONF_DIR= ${PREFIX}/etc
+SAMP_DIR= ${CONF_DIR}
+DOC_SUBDIR= share/doc/${PKGBASE}
+DOC_DIR= ${PREFIX}/${DOC_SUBDIR}
CONF_FILE= op.access
SAMP_FILE= ${CONF_FILE}
SAMP_SUFX= .sample
DOC_FILES= README op.paper
-CO?= co
-
#
# Post-extract
#
@@ -62,14 +65,14 @@ checkout-files:
# Post-patch
#
-post-patch: patch-install patch-conf-file
+post-patch: patch-makefile patch-conf-file
-patch-install:
- @${PERL} -pi.fbsd -e 's/(install)/$$1 -c/ if (!/:/);' \
+patch-makefile:
+ @${PERL} -pi.fbsd -e 's|(install)|$$1 -c| if (!/:/);' \
${WRKSRC}/Makefile
patch-conf-file:
- @${PERL} -pi.fbsd -e 's/^/#/ if (!/^#|DEFAULT|MAGIC/);' \
+ @${PERL} -pi.fbsd -e 's|^|#| if (!/^#|DEFAULT|MAGIC/);s|/usr/ucb:||;' \
${WRKSRC}/${CONF_FILE}
#
@@ -94,4 +97,22 @@ install-doc-files:
.endfor
.endif
-.include <bsd.port.mk>
+.include <bsd.port.pre.mk>
+
+# some sketchy hackery
+FETCH_CMD_INTERIOR!= ${ECHO} ${FETCH_CMD} | ${SED} -E -e "s!(.+/)?fetch(.+/|\s+.*)?!!"
+
+# only enable the hack if FETCH_CMD is fetch
+.if ! ${FETCH_CMD_INTERIOR}
+# coast sites dislike $USER@localhost...
+FETCH_ENV= FTP_PASSWORD=${FTP_PASSWORD}
+
+AWK?= awk
+IFCONFIG?= ifconfig
+
+# well, this is a hack to make fetch happy on coast sites, ugh!
+HOSTIPADDR= ${IFCONFIG} | ${AWK} '/inet /{print $$2; exit}'
+FTP_PASSWORD?= ${USER}@`${HOSTIPADDR}`
+.endif
+
+.include <bsd.port.post.mk>
diff --git a/security/op/pkg-install b/security/op/pkg-install
index 4eb014d2d034..7e4789e6398e 100644
--- a/security/op/pkg-install
+++ b/security/op/pkg-install
@@ -1,4 +1,5 @@
#!/bin/sh
+# $FreeBSD$
[ $# != 2 ] && exit 1
PKGNAME=$1
diff --git a/security/op/pkg-plist b/security/op/pkg-plist
index ce36eda65e3f..94ceef2e8fdb 100644
--- a/security/op/pkg-plist
+++ b/security/op/pkg-plist
@@ -1,4 +1,6 @@
+@comment $FreeBSD$
bin/op
etc/op.access.sample
-share/doc/op/README
-share/doc/op/op.paper
+%%PORTDOCS%%%%DOCDIR%%/README
+%%PORTDOCS%%%%DOCDIR%%/op.paper
+%%PORTDOCS%%@dirrm %%DOCDIR%%