diff options
author | jeh <jeh@FreeBSD.org> | 2001-03-24 11:09:53 +0000 |
---|---|---|
committer | jeh <jeh@FreeBSD.org> | 2001-03-24 11:09:53 +0000 |
commit | e7dd3f5b5956b78800b934f04d63da717ce37c63 (patch) | |
tree | a48c6e32ad45e151dd11fcc57ff3af8b4bad83e8 /net/isc-dhcp40-server | |
parent | fd8261ab59214754379182255eac0b2722b5bc66 (diff) | |
download | FreeBSD-ports-e7dd3f5b5956b78800b934f04d63da717ce37c63.zip FreeBSD-ports-e7dd3f5b5956b78800b934f04d63da717ce37c63.tar.gz |
Update to version 3.0.b2.23
Submitted by: Cyrille Lefevre <clefevre@poboxes.com> MAINTAINER
Diffstat (limited to 'net/isc-dhcp40-server')
-rw-r--r-- | net/isc-dhcp40-server/Makefile | 3 | ||||
-rw-r--r-- | net/isc-dhcp40-server/distinfo | 2 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-aj | 20 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-client-Makefile.dist | 29 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-clparse.c | 11 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-dhclient-script.8 | 16 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-dhclient.8 | 73 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-dhclient.c | 72 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-freebsd | 122 | ||||
-rw-r--r-- | net/isc-dhcp40-server/files/patch-site.conf | 11 |
10 files changed, 19 insertions, 340 deletions
diff --git a/net/isc-dhcp40-server/Makefile b/net/isc-dhcp40-server/Makefile index cfb74b9..883b69e 100644 --- a/net/isc-dhcp40-server/Makefile +++ b/net/isc-dhcp40-server/Makefile @@ -7,7 +7,7 @@ # PORTNAME= dhcp -PORTVERSION= 3.0.b2.22 +PORTVERSION= 3.0.b2.23 CATEGORIES= net MASTER_SITES= ftp://ftp.isc.org/isc/dhcp/ PKGNAMEPREFIX= isc- @@ -46,6 +46,7 @@ ETC_DIR= ${PREFIX}/etc RCD_DIR= ${PREFIX}/etc/rc.d DOC_DIR= ${PREFIX}/share/doc/${PKGBASE} VARDB_DIR= /var/db +VARRUN_DIR= /var/run STRIP?= strip diff --git a/net/isc-dhcp40-server/distinfo b/net/isc-dhcp40-server/distinfo index 384d4e1..57e44b1 100644 --- a/net/isc-dhcp40-server/distinfo +++ b/net/isc-dhcp40-server/distinfo @@ -1 +1 @@ -MD5 (dhcp-3.0b2pl22.tar.gz) = 9a0155b192a82bd44b38fa6ceae7976e +MD5 (dhcp-3.0b2pl23.tar.gz) = 872a55504bd8dccbef9ac97e89eeda0e diff --git a/net/isc-dhcp40-server/files/patch-aj b/net/isc-dhcp40-server/files/patch-aj deleted file mode 100644 index b8a3562..0000000 --- a/net/isc-dhcp40-server/files/patch-aj +++ /dev/null @@ -1,20 +0,0 @@ ---- includes/dhcpd.h.orig Thu Jan 25 09:25:12 2001 -+++ includes/dhcpd.h Fri Jan 26 06:46:12 2001 -@@ -672,7 +672,7 @@ - u_int32_t requested_lease; /* Requested lease time, if user - doesn't configure one. */ - struct string_list *media; /* Possible network media values. */ -- char *script_name; /* Name of config script. */ -+ const char *script_name; /* Name of config script. */ - char *vendor_space_name; /* Name of config script. */ - enum policy bootp_policy; - /* Ignore, accept or prefer BOOTP -@@ -1864,6 +1864,8 @@ - void set_ip_address PROTO ((struct interface_info *, struct in_addr)); - - /* clparse.c */ -+extern const char *client_script_name; -+ - isc_result_t read_client_conf PROTO ((void)); - void read_client_leases PROTO ((void)); - void parse_client_statement PROTO ((struct parse *, struct interface_info *, diff --git a/net/isc-dhcp40-server/files/patch-client-Makefile.dist b/net/isc-dhcp40-server/files/patch-client-Makefile.dist deleted file mode 100644 index f6ec21d..0000000 --- a/net/isc-dhcp40-server/files/patch-client-Makefile.dist +++ /dev/null @@ -1,29 +0,0 @@ ---- client/Makefile.dist.orig Fri Oct 13 21:03:19 2000 -+++ client/Makefile.dist Fri Jan 26 05:05:24 2001 -@@ -52,8 +52,8 @@ - echo "No client script available."; \ - else \ - $(INSTALL) $(TOP)/client/scripts/$(SCRIPT)\ -- $(DESTDIR)$(ETC)/dhclient-script; \ -- $(CHMOD) 700 $(DESTDIR)$(ETC)/dhclient-script; \ -+ $(DESTDIR)$(CLIENTBINDIR)/dhclient-script; \ -+ $(CHMOD) 700 $(DESTDIR)$(CLIENTBINDIR)/dhclient-script; \ - fi - $(MANINSTALL) $(MANFROM) dhclient.$(MANCAT)8 $(MANTO) \ - $(DESTDIR)$(ADMMANDIR)/dhclient$(ADMMANEXT) -@@ -93,6 +93,7 @@ - - dhclient.man8: dhclient.8 - sed -e "s#ETCDIR#$(ETC)#g" -e "s#DBDIR#$(VARDB)#g" \ -+ -e "s#CLIENTBINDIR#$(CLIENTBINDIR)#g" \ - -e "s#RUNDIR#$(VARRUN)#g" < dhclient.8 >dhclient.man8 - - dhclient-script.cat8: dhclient-script.man8 -@@ -100,6 +101,7 @@ - - dhclient-script.man8: dhclient-script.8 - sed -e "s#ETCDIR#$(ETC)#g" -e "s#DBDIR#$(VARDB)#g" \ -+ -e "s#CLIENTBINDIR#$(CLIENTBINDIR)#g" \ - -e "s#RUNDIR#$(VARRUN)#g" < dhclient-script.8 \ - >dhclient-script.man8 - diff --git a/net/isc-dhcp40-server/files/patch-clparse.c b/net/isc-dhcp40-server/files/patch-clparse.c deleted file mode 100644 index 48c125d..0000000 --- a/net/isc-dhcp40-server/files/patch-clparse.c +++ /dev/null @@ -1,11 +0,0 @@ ---- client/clparse.c.orig Thu Jan 25 09:17:17 2001 -+++ client/clparse.c Fri Jan 26 06:11:01 2001 -@@ -50,7 +50,7 @@ - - static TIME parsed_time; - --char client_script_name [] = "/etc/dhclient-script"; -+const char *client_script_name = CL_DEFAULT_SCRIPT_NAME; - - struct client_config top_level_config; - diff --git a/net/isc-dhcp40-server/files/patch-dhclient-script.8 b/net/isc-dhcp40-server/files/patch-dhclient-script.8 deleted file mode 100644 index 834d328..0000000 --- a/net/isc-dhcp40-server/files/patch-dhclient-script.8 +++ /dev/null @@ -1,16 +0,0 @@ ---- client/dhclient-script.8.orig Tue Mar 30 00:50:50 1999 -+++ client/dhclient-script.8 Fri Jan 26 05:12:57 2001 -@@ -60,11 +60,11 @@ - to change the behaviour of the script. If an error occurs during the - execution of the script, it can set the exit_status variable to a nonzero - value, and --.B ETCDIR/dhclient-script -+.B CLIENTBINDIR/dhclient-script - will exit with that error code immediately after the client script exits. - .PP - After all processing has completed, --.B ETCDIR/dhclient-script -+.B CLIENTBINDIR/dhclient-script - checks for the presence of an executable - .B ETCDIR/dhclient-exit-hooks - script, which if present is invoked using the '.' command. The exit status diff --git a/net/isc-dhcp40-server/files/patch-dhclient.8 b/net/isc-dhcp40-server/files/patch-dhclient.8 deleted file mode 100644 index d92e061..0000000 --- a/net/isc-dhcp40-server/files/patch-dhclient.8 +++ /dev/null @@ -1,73 +0,0 @@ ---- client/dhclient.8.orig Thu Mar 1 23:11:12 2001 -+++ client/dhclient.8 Thu Mar 22 04:04:29 2001 -@@ -34,12 +34,12 @@ - .B -q - ] - [ --.B -c -+.B -1 - ] -+[ - .B -r - ] - [ --[ - .B -lf - .I lease-file - ] -@@ -52,6 +52,10 @@ - .I config-file - ] - [ -+.B -sf -+.I script-file -+] -+[ - .B -s - server - ] -@@ -184,17 +188,25 @@ - .B -r - flag explicitly releases the current lease. - .PP -+The -+.B -1 -+flag cause dhclient to try once to get a lease. If it fails, dhclient exits -+with exit code two. -+.PP - The DHCP client normally gets its configuration information from - .B ETCDIR/dhclient.conf, - its lease database from --.B DBDIR/dhclient.leases --and stores its process ID in a file called -+.B DBDIR/dhclient.leases, -+stores its process ID in a file called - .B RUNDIR/dhclient.pid. -+and configure the network interface using -+.B CLIENTBINDIR/dhclient-script. - To specify different names and/or locations for these files, use the - .B -cf, --.B -lf --and -+.B -lf, - .B -pf -+and -+.B -sf - flags, respectively, followed by the name of the file. This can be - particularly useful if, for example, - .B DBDIR -@@ -216,10 +228,12 @@ - .SH CONFIGURATION - The syntax of the dhclient.conf(8) file is discussed seperately. - .SH FILES -+.B CLIENTBINDIR/dhclient-script, - .B ETCDIR/dhclient.conf, DBDIR/dhclient.leases, RUNDIR/dhclient.pid, --.B DBDIR/dhclient.leases~. -+.B DBDIR/dhclient.leases. - .SH SEE ALSO --dhcpd(8), dhcrelay(8), dhclient.conf(5), dhclient.leases(5) -+dhcpd(8), dhcrelay(8), dhclient-script(8), dhclient.conf(5) and -+dhclient.leases(5). - .SH AUTHOR - .B dhclient(8) - has been written for the Internet Software Consortium diff --git a/net/isc-dhcp40-server/files/patch-dhclient.c b/net/isc-dhcp40-server/files/patch-dhclient.c deleted file mode 100644 index 208c0dc..0000000 --- a/net/isc-dhcp40-server/files/patch-dhclient.c +++ /dev/null @@ -1,72 +0,0 @@ ---- client/dhclient.c.orig Fri Mar 16 00:12:03 2001 -+++ client/dhclient.c Thu Mar 22 14:57:19 2001 -@@ -78,6 +78,7 @@ - u_int16_t remote_port; - int no_daemon; - int save_scripts; -+int onetry; - struct string_list *client_env; - int client_env_count; - -@@ -106,6 +107,7 @@ - int no_dhclient_conf = 0; - int no_dhclient_db = 0; - int no_dhclient_pid = 0; -+ int no_dhclient_script = 0; - char *s; - - #ifdef SYSLOG_4_2 -@@ -161,6 +163,13 @@ - usage (); - path_dhclient_db = argv [i]; - no_dhclient_db = 1; -+ } else if (!strcmp (argv [i], "-sf")) { -+ if (++i == argc) -+ usage (); -+ client_script_name = argv [i]; -+ no_dhclient_script = 1; -+ } else if (!strcmp (argv [i], "-1")) { -+ onetry = 1; - } else if (!strcmp (argv [i], "-q")) { - quiet = 1; - quiet_interface_discovery = 1; -@@ -224,6 +233,9 @@ - if (!no_dhclient_pid && (s = getenv ("PATH_DHCLIENT_PID"))) { - path_dhclient_pid = s; - } -+ if (!no_dhclient_script && (s = getenv ("PATH_DHCLIENT_SCRIPT"))) { -+ client_script_name = s; -+ } - - /* first kill of any currently running client */ - if (release_mode) { -@@ -445,10 +457,12 @@ - log_info (arr); - log_info (url); - -- log_error ("Usage: dhclient [-d] [-D] [-q] [-p <port>] %s", -+ log_error ("Usage: dhclient [-1dDqr] [-p <port>] %s", - "[-s server]"); -- log_fatal (" [-lf lease-file] [-pf pid-file]%s", -- "[-cf config-file] [interface] [-e VAR=val]"); -+ log_error (" [-cf config-file] [-lf lease-file] %s", -+ "[-pf pid-file]"); -+ log_fatal (" [-sf script-file] [interface] %s", -+ "[-e VAR=val]"); - } - - isc_result_t find_class (struct class **c, -@@ -1453,6 +1467,13 @@ - /* No leases were available, or what was available didn't work, so - tell the shell script that we failed to allocate an address, - and try again later. */ -+ if (onetry) { -+ if (!quiet) -+ log_info ("Unable to obtain a lease on first try - %s.", -+ -+ "exiting"); -+ exit(2); -+ } - log_info ("No working leases in persistent database - sleeping."); - script_init (client, "FAIL", (struct string_list *)0); - if (client -> alias) diff --git a/net/isc-dhcp40-server/files/patch-freebsd b/net/isc-dhcp40-server/files/patch-freebsd index e4da6d9..43c86a6 100644 --- a/net/isc-dhcp40-server/files/patch-freebsd +++ b/net/isc-dhcp40-server/files/patch-freebsd @@ -1,18 +1,6 @@ ---- client/scripts/freebsd.orig Fri Mar 16 00:16:49 2001 -+++ client/scripts/freebsd Thu Mar 22 02:42:13 2001 -@@ -1,5 +1,11 @@ - #!/bin/sh - -+if [ -x /usr/bin/logger ]; then -+ LOGGER="/usr/bin/logger -s -p user.notice -t dhclient" -+else -+ LOGGER=echo -+fi -+ - make_resolv_conf() { - echo search $new_domain_name >/etc/resolv.conf - for nameserver in $new_domain_name_servers; do -@@ -10,17 +16,17 @@ +--- client/scripts/freebsd.orig Thu Mar 22 07:59:28 2001 ++++ client/scripts/freebsd Sat Mar 24 04:50:11 2001 +@@ -16,17 +16,17 @@ # Must be used on exit. Invokes the local dhcp client exit hooks, if any. exit_with_hooks() { exit_status=$1 @@ -34,70 +22,21 @@ # allow the local script to abort processing of this state # local script must set exit_status variable to nonzero. if [ $exit_status -ne 0 ]; then -@@ -29,11 +35,10 @@ +@@ -35,11 +35,11 @@ fi if [ x$new_network_number != x ]; then -- echo New Network Number: $new_network_number -+ $LOGGER "New Network Number: $new_network_number" +- $LOGGER New Network Number: $new_network_number ++ $LOGGER "New Network Number: $new_network_number" fi if [ x$new_broadcast_address != x ]; then -- echo New Broadcast Address: $new_broadcast_address +- $LOGGER New Broadcast Address: $new_broadcast_address ++ $LOGGER "New Broadcast Address: $new_broadcast_address" new_broadcast_arg="broadcast $new_broadcast_address" fi if [ x$old_broadcast_address != x ]; then -@@ -77,6 +82,7 @@ - [ x$current_hostname = x$old_host_name ]; then - if [ x$current_hostname = x ] || \ - [ x$new_host_name != x$old_host_name ]; then -+ $LOGGER "New Hostname: $new_host_name" - hostname $new_host_name - fi - fi -@@ -93,24 +99,31 @@ - route delete default $router >/dev/null 2>&1 - done - if [ "$old_static_routes" != "" ]; then -- set $old_static_routes -+ set -- $old_static_routes - while [ $# -gt 1 ]; do - route delete $1 $2 - shift; shift - done - fi -- arp -n -a | sed -n -e 's/^.*(\(.*\)) at .*$/arp -n -d \1/p' |sh -+ arp -n -a | sed -n -e 's/^.*(\(.*\)) at .*$/arp -d \1/p' |sh - fi - if [ x$old_ip_address = x ] || [ x$old_ip_address != x$new_ip_address ] || \ - [ x$reason = xBOUND ] || [ x$reason = xREBOOT ]; then - eval "ifconfig $interface inet $new_ip_address $new_netmask_arg \ - $new_broadcast_arg $medium" -+ $LOGGER "New IP Address($interface): $new_ip_address" -+ $LOGGER "New Subnet Mask($interface): $new_subnet_mask" -+ $LOGGER "New Broadcast Address($interface): $new_broadcast_address" -+ if [ "$new_routers" != "" ]; then -+ $LOGGER "New Routers: $new_routers" -+ fi - route add $new_ip_address 127.1 >/dev/null 2>&1 - for router in $new_routers; do - route add default $router >/dev/null 2>&1 - done - if [ "$new_static_routes" != "" ]; then -- set $new_static_routes -+ $LOGGER "New Static Routes: $new_static_routes" -+ set -- $new_static_routes - while [ $# -gt 1 ]; do - route add $1 $2 - shift; shift -@@ -138,13 +151,13 @@ - route delete default $router >/dev/null 2>&1 - done - if [ "$old_static_routes" != "" ]; then -- set $old_static_routes -+ set -- $old_static_routes - while [ $# -gt 1 ]; do - route delete $1 $2 +@@ -158,7 +158,7 @@ shift; shift done fi @@ -106,46 +45,3 @@ |sh >/dev/null 2>&1 fi if [ x$alias_ip_address != x ]; then -@@ -161,9 +174,13 @@ - fi - eval "ifconfig $interface inet $new_ip_address $new_netmask_arg \ - $new_broadcast_arg $medium" -+ $LOGGER "New IP Address($interface): $new_ip_address" -+ $LOGGER "New Subnet Mask($interface): $new_subnet_mask" -+ $LOGGER "New Broadcast Address($interface): $new_broadcast_address" - sleep 1 - if [ "$new_routers" != "" ]; then -- set $new_routers -+ $LOGGER "New Routers: $new_routers" -+ set -- $new_routers - if ping -q -c 1 $1; then - if [ x$new_ip_address != x$alias_ip_address ] && \ - [ x$alias_ip_address != x ]; then -@@ -174,9 +191,9 @@ - for router in $new_routers; do - route add default $router >/dev/null 2>&1 - done -- set $new_static_routes -+ set -- $new_static_routes - while [ $# -gt 1 ]; do -- route add $0 $1 -+ route add $1 $2 - shift; shift - done - make_resolv_conf -@@ -188,13 +205,13 @@ - route delete default $router >/dev/null 2>&1 - done - if [ "$old_static_routes" != "" ]; then -- set $old_static_routes -+ set -- $old_static_routes - while [ $# -gt 1 ]; do - route delete $1 $2 - shift; shift - done - fi -- arp -n -a | sed -n -e 's/^.*(\(.*\)) at .*$/arp -n -d \1/p' \ -+ arp -n -a | sed -n -e 's/^.*(\(.*\)) at .*$/arp -d \1/p' \ - |sh >/dev/null 2>&1 - exit_with_hooks 1 - fi diff --git a/net/isc-dhcp40-server/files/patch-site.conf b/net/isc-dhcp40-server/files/patch-site.conf index 5efe419..23520fd 100644 --- a/net/isc-dhcp40-server/files/patch-site.conf +++ b/net/isc-dhcp40-server/files/patch-site.conf @@ -1,6 +1,6 @@ --- site.conf.orig Wed Jul 7 17:20:10 1999 -+++ site.conf Fri Jan 26 06:58:15 2001 -@@ -1,2 +1,29 @@ ++++ site.conf Sat Mar 24 04:55:39 2001 +@@ -1,2 +1,32 @@ # Put local site configuration stuff here to override the default # settings in Makefile.conf + @@ -23,10 +23,13 @@ + +DEBUG ?= #none + -+CFLAGS += -DCL_DEFAULT_SCRIPT_NAME=\"$(CLIENTBINDIR)/dhclient-script\" -+ +CFLAGS += -D_PATH_DHCPD_CONF=\"$(ETC)/dhcpd.conf\" +CFLAGS += -D_PATH_DHCPD_DB=\"$(VARDB)/dhcpd.leases\" ++CFLAGS += -D_PATH_DHCPD_PID=\"$(VARRUN)/dhcpd.pid\" ++ ++CFLAGS += -D_PATH_DHCRELAY_PID=\"$(VARRUN)/dhcrelay.pid\" + +CFLAGS += -D_PATH_DHCLIENT_CONF=\"$(ETC)/dhclient.conf\" ++CFLAGS += -D_PATH_DHCLIENT_SCRIPT=\"$(CLIENTBINDIR)/dhclient-script\" +CFLAGS += -D_PATH_DHCLIENT_DB=\"$(VARDB)/dhclient.leases\" ++CFLAGS += -D_PATH_DHCLIENT_PID=\"$(VARDB)/dhclient.pid\" |