Update to 3.0.1.

PR:		22280
Submitted by:	Christopher J. Michaels <cjm2@altavista.net> (MAINTAINER)

Introduce BSD style Makefile to make the build/installation process clean.

Fix manpage. (/etc -> ${PREFIX}/etc)

Fix ddupcron.sh to match FreeBSD environment.
This commit is contained in:
Akinori MUSHA 2000-11-03 16:21:54 +00:00
parent 2573e51274
commit 079eb6d922
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=34753
16 changed files with 172 additions and 84 deletions

View File

@ -6,45 +6,40 @@
#
PORTNAME= ddup
PORTVERSION= 2.2
PORTVERSION= 3.0.1
CATEGORIES= net
MASTER_SITES= ftp://ddup.sourceforge.net/pub/ddup/
DISTNAME= ddup-2.2Dm
MASTER_SITES= http://www.ddup.org/download/
DISTNAME= ${PORTNAME}-${PORTVERSION}-unix
MAINTAINER= cjm2@altavista.net
MAN1= ddup.1
MANCOMPRESSED= yes
MANCOMPRESSED= maybe
WRKSRC= ${WRKDIR}/ddup-2.2Dm
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
# Uncomment this if you want to enable debugging.
#DEBUG= -g
MAKE_ARGS= DEBUG="${DEBUG}"
post-extract:
cd ${WRKSRC}; ${GUNZIP_CMD} ddup.1.gz
post-patch:
${PERL} -i -pe 's,!!PREFIX!!,${PREFIX},' ${WRKSRC}/ddupcron.sh
${PERL} -i -pe 's,/etc\b,${PREFIX}$$&,' ${WRKSRC}/ddup.1
pre-build:
${ECHO} "char *file_name = \"${PREFIX}/etc/ddup.conf\";" > ${WRKSRC}/options.h
do-build:
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c ddup.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c ddup_functions.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c getopt.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c getopt1.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c parse_config.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c parse_option.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c update.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -o ddup ddup.o ddup_functions.o getopt.o getopt1.o parse_config.o parse_option.o update.o ${LIBS}
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/ddup ${PREFIX}/sbin
${INSTALL_SCRIPT} ${WRKSRC}/testip ${PREFIX}/sbin
${INSTALL_MAN} ${WRKSRC}/ddup.1.gz ${PREFIX}/man/man1
${MKDIR} ${PREFIX}/share/doc/ddup
${INSTALL_MAN} ${WRKSRC}/INSTALL-C ${PREFIX}/share/doc/ddup
${INSTALL_MAN} ${WRKSRC}/README ${PREFIX}/share/doc/ddup
${INSTALL_MAN} ${WRKSRC}/COPYING ${PREFIX}/share/doc/ddup
${CP} ${FILESDIR}/Makefile ${WRKSRC}/
${ECHO} "#define file_name \"${PREFIX}/etc/ddup.conf\"" > ${WRKSRC}/options.h
post-install:
strip ${PREFIX}/sbin/ddup
${CAT} ${PKGMESSAGE}
${INSTALL_SCRIPT} ${WRKSRC}/ddupcron.sh ${PREFIX}/sbin/
.if !defined(NOPORTSDOC)
${MKDIR} ${PREFIX}/share/doc/ddup
${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/ddup/
.endif
@${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>

View File

@ -1 +1 @@
MD5 (ddup-2.2Dm.tar.gz) = 8c4a4bcabca77da7e1ceda12f57a2108
MD5 (ddup-3.0.1-unix.tar.gz) = 6c3ee8158f994de4cbbaf0593fb0226c

17
dns/ddup/files/Makefile Normal file
View File

@ -0,0 +1,17 @@
# $FreeBSD$
PROG= ddup
SRCS= ddup.c \
ddup_functions.c \
getopt.c \
getopt1.c \
parse_config.c \
parse_option.c \
update.c
CFLAGS+= ${DEBUG}
MAN1= ddup.1
BINDIR= ${LOCALBASE}/sbin
MANDIR= ${LOCALBASE}/man/man
.include <bsd.prog.mk>

View File

@ -0,0 +1,29 @@
--- ddupcron.sh.orig Mon Oct 23 02:11:48 2000
+++ ddupcron.sh Thu Nov 2 14:16:39 2000
@@ -2,19 +2,23 @@
# Define the host to be updated as 1st arguement to script
if [ -z $1 ]; then
- echo "Usage: ddupcron.sh hostname"
+ echo "Usage: ddupcron.sh hostname [interface]"
exit
else
HOST=$1
fi
# Define interface to grep address from
-IFACE="eth0"
+if [ -z $2 ]; then
+ IFACE=fxp0
+else
+ IFACE=$2
+fi
IFCHECK=$(/sbin/ifconfig $IFACE|grep ask|awk '{print $2}'|cut -d ':' -f2)
# Define where we should store last IP
IPFILE="/tmp/ddupip"
IPCHECK=$(cat $IPFILE)
# Define path to ddup and ddup arguments (except --host)
-DDUP_PATH="/home/ddup/ddup"
+DDUP_PATH="!!PREFIX!!/sbin/ddup"
DDUP_ARGS="--debug"

View File

@ -1 +1 @@
A DynDNS.org client for UNIX
A DynDNS.org client for UNIX (Now support NIC v2.0)

View File

@ -1,9 +1,19 @@
DD-UP in C by Thomas Gandy (tegandy@enid.com)
---------------------------------------------------------
DD-UP is a program that is used to update a host provided by the Free
DynDNS service of dyndns.org.
DD-UP is a program that is used to update a host
provided by the Free DynDNS service of dyndns.org.
This version supports:
- Dynamic Hostnames
- Static Hostnames
- DynDNS.Org NIC v2.0
WWW: http://ddup.sourceforce.net/
Features in this version include:
- Automatic IP Detection
- Manual IP Specification
- Wildcard hosts
- Backup MX hosts
- Operation through a proxy server
Author: Thomas Gandy <tegandy@enid.com>
WWW: http://www.ddup.org/
EMAIL: cjm2@altavista.net

View File

@ -3,8 +3,3 @@
*** you MUST make your configuration file by typing ***
*** ddup --makeconf ***
********************************************************
********************************************************
*** If you are upgrading or are a first time user ***
*** you MUST make your configuration file by typing ***
*** ddup --makeconf ***
********************************************************

View File

@ -1,6 +1,4 @@
sbin/ddup
sbin/testip
sbin/ddupcron.sh
share/doc/ddup/README
share/doc/ddup/INSTALL-C
share/doc/ddup/COPYING
@dirrm share/doc/ddup

View File

@ -6,45 +6,40 @@
#
PORTNAME= ddup
PORTVERSION= 2.2
PORTVERSION= 3.0.1
CATEGORIES= net
MASTER_SITES= ftp://ddup.sourceforge.net/pub/ddup/
DISTNAME= ddup-2.2Dm
MASTER_SITES= http://www.ddup.org/download/
DISTNAME= ${PORTNAME}-${PORTVERSION}-unix
MAINTAINER= cjm2@altavista.net
MAN1= ddup.1
MANCOMPRESSED= yes
MANCOMPRESSED= maybe
WRKSRC= ${WRKDIR}/ddup-2.2Dm
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
# Uncomment this if you want to enable debugging.
#DEBUG= -g
MAKE_ARGS= DEBUG="${DEBUG}"
post-extract:
cd ${WRKSRC}; ${GUNZIP_CMD} ddup.1.gz
post-patch:
${PERL} -i -pe 's,!!PREFIX!!,${PREFIX},' ${WRKSRC}/ddupcron.sh
${PERL} -i -pe 's,/etc\b,${PREFIX}$$&,' ${WRKSRC}/ddup.1
pre-build:
${ECHO} "char *file_name = \"${PREFIX}/etc/ddup.conf\";" > ${WRKSRC}/options.h
do-build:
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c ddup.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c ddup_functions.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c getopt.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c getopt1.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c parse_config.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c parse_option.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -c update.c
cd ${WRKSRC} && ${CC} ${CFLAGS} ${DEBUG} -o ddup ddup.o ddup_functions.o getopt.o getopt1.o parse_config.o parse_option.o update.o ${LIBS}
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/ddup ${PREFIX}/sbin
${INSTALL_SCRIPT} ${WRKSRC}/testip ${PREFIX}/sbin
${INSTALL_MAN} ${WRKSRC}/ddup.1.gz ${PREFIX}/man/man1
${MKDIR} ${PREFIX}/share/doc/ddup
${INSTALL_MAN} ${WRKSRC}/INSTALL-C ${PREFIX}/share/doc/ddup
${INSTALL_MAN} ${WRKSRC}/README ${PREFIX}/share/doc/ddup
${INSTALL_MAN} ${WRKSRC}/COPYING ${PREFIX}/share/doc/ddup
${CP} ${FILESDIR}/Makefile ${WRKSRC}/
${ECHO} "#define file_name \"${PREFIX}/etc/ddup.conf\"" > ${WRKSRC}/options.h
post-install:
strip ${PREFIX}/sbin/ddup
${CAT} ${PKGMESSAGE}
${INSTALL_SCRIPT} ${WRKSRC}/ddupcron.sh ${PREFIX}/sbin/
.if !defined(NOPORTSDOC)
${MKDIR} ${PREFIX}/share/doc/ddup
${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/ddup/
.endif
@${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>

View File

@ -1 +1 @@
MD5 (ddup-2.2Dm.tar.gz) = 8c4a4bcabca77da7e1ceda12f57a2108
MD5 (ddup-3.0.1-unix.tar.gz) = 6c3ee8158f994de4cbbaf0593fb0226c

17
net/ddup/files/Makefile Normal file
View File

@ -0,0 +1,17 @@
# $FreeBSD$
PROG= ddup
SRCS= ddup.c \
ddup_functions.c \
getopt.c \
getopt1.c \
parse_config.c \
parse_option.c \
update.c
CFLAGS+= ${DEBUG}
MAN1= ddup.1
BINDIR= ${LOCALBASE}/sbin
MANDIR= ${LOCALBASE}/man/man
.include <bsd.prog.mk>

View File

@ -0,0 +1,29 @@
--- ddupcron.sh.orig Mon Oct 23 02:11:48 2000
+++ ddupcron.sh Thu Nov 2 14:16:39 2000
@@ -2,19 +2,23 @@
# Define the host to be updated as 1st arguement to script
if [ -z $1 ]; then
- echo "Usage: ddupcron.sh hostname"
+ echo "Usage: ddupcron.sh hostname [interface]"
exit
else
HOST=$1
fi
# Define interface to grep address from
-IFACE="eth0"
+if [ -z $2 ]; then
+ IFACE=fxp0
+else
+ IFACE=$2
+fi
IFCHECK=$(/sbin/ifconfig $IFACE|grep ask|awk '{print $2}'|cut -d ':' -f2)
# Define where we should store last IP
IPFILE="/tmp/ddupip"
IPCHECK=$(cat $IPFILE)
# Define path to ddup and ddup arguments (except --host)
-DDUP_PATH="/home/ddup/ddup"
+DDUP_PATH="!!PREFIX!!/sbin/ddup"
DDUP_ARGS="--debug"

View File

@ -1 +1 @@
A DynDNS.org client for UNIX
A DynDNS.org client for UNIX (Now support NIC v2.0)

View File

@ -1,9 +1,19 @@
DD-UP in C by Thomas Gandy (tegandy@enid.com)
---------------------------------------------------------
DD-UP is a program that is used to update a host provided by the Free
DynDNS service of dyndns.org.
DD-UP is a program that is used to update a host
provided by the Free DynDNS service of dyndns.org.
This version supports:
- Dynamic Hostnames
- Static Hostnames
- DynDNS.Org NIC v2.0
WWW: http://ddup.sourceforce.net/
Features in this version include:
- Automatic IP Detection
- Manual IP Specification
- Wildcard hosts
- Backup MX hosts
- Operation through a proxy server
Author: Thomas Gandy <tegandy@enid.com>
WWW: http://www.ddup.org/
EMAIL: cjm2@altavista.net

View File

@ -3,8 +3,3 @@
*** you MUST make your configuration file by typing ***
*** ddup --makeconf ***
********************************************************
********************************************************
*** If you are upgrading or are a first time user ***
*** you MUST make your configuration file by typing ***
*** ddup --makeconf ***
********************************************************

View File

@ -1,6 +1,4 @@
sbin/ddup
sbin/testip
sbin/ddupcron.sh
share/doc/ddup/README
share/doc/ddup/INSTALL-C
share/doc/ddup/COPYING
@dirrm share/doc/ddup