From c77d940d1907fd7d237a07b7146fd7c38ef88cf7 Mon Sep 17 00:00:00 2001 From: Frederic Culot Date: Sun, 26 Dec 2010 09:16:43 +0000 Subject: - Update to 1.2.8.31 PR: ports/153446 Submitted by: Hung-Yi Chen (maintainer) Approved by: sahil@/wen@ (mentors, implicit) --- dns/mydns-ng/Makefile | 5 +- dns/mydns-ng/distinfo | 5 +- dns/mydns-ng/files/patch-Makefile.in | 9 +- dns/mydns-ng/files/patch-config.h.in | 11 +++ dns/mydns-ng/files/patch-contrib_admin.php | 58 ------------ dns/mydns-ng/files/patch-src_mydns-1.2.8_main.c | 100 --------------------- dns/mydns-ng/files/patch-src_mydns-1.2.8_resolve.c | 76 ---------------- .../files/patch-src_mydns-1.2.8_servercomms.c | 16 ---- dns/mydns-ng/pkg-plist | 1 - 9 files changed, 20 insertions(+), 261 deletions(-) create mode 100644 dns/mydns-ng/files/patch-config.h.in delete mode 100644 dns/mydns-ng/files/patch-contrib_admin.php delete mode 100644 dns/mydns-ng/files/patch-src_mydns-1.2.8_main.c delete mode 100644 dns/mydns-ng/files/patch-src_mydns-1.2.8_resolve.c delete mode 100644 dns/mydns-ng/files/patch-src_mydns-1.2.8_servercomms.c (limited to 'dns') diff --git a/dns/mydns-ng/Makefile b/dns/mydns-ng/Makefile index 1d246b5ba597..7304e117adea 100644 --- a/dns/mydns-ng/Makefile +++ b/dns/mydns-ng/Makefile @@ -6,8 +6,7 @@ # PORTNAME= mydns-ng -PORTVERSION= 1.2.8.27 -PORTREVISION= 3 +PORTVERSION= 1.2.8.31 CATEGORIES= dns databases MASTER_SITES= SF/${PORTNAME}/mydns/${PORTVERSION} DISTNAME= mydns-${PORTVERSION} @@ -15,7 +14,7 @@ DISTNAME= mydns-${PORTVERSION} MAINTAINER= gaod@hychen.org COMMENT= A Next Generation DNS Server for sql based DNS services -WRKSRC= ${WRKDIR}/mydns-${PORTVERSION:R} +#WRKSRC= ${WRKDIR}/mydns-${PORTVERSION:R} GNU_CONFIGURE= yes CONFIGURE_ARGS= --with-confdir=${PREFIX}/etc USE_ICONV= yes diff --git a/dns/mydns-ng/distinfo b/dns/mydns-ng/distinfo index aa936c6aa164..1b7881c969a3 100644 --- a/dns/mydns-ng/distinfo +++ b/dns/mydns-ng/distinfo @@ -1,3 +1,2 @@ -MD5 (mydns-1.2.8.27.tar.gz) = d5fb01ec404049c2d3bd319337a30190 -SHA256 (mydns-1.2.8.27.tar.gz) = 9f9a80d2c3b47b91e15daf49aa3442b29e2f2c175ffb98358ccb9103087edc21 -SIZE (mydns-1.2.8.27.tar.gz) = 1055969 +SHA256 (mydns-1.2.8.31.tar.gz) = cb10de11ccd948d3b86296c03c6fb692489945d58b0aaee5d17be083f3263629 +SIZE (mydns-1.2.8.31.tar.gz) = 958701 diff --git a/dns/mydns-ng/files/patch-Makefile.in b/dns/mydns-ng/files/patch-Makefile.in index 7c84aec52585..055a55566202 100644 --- a/dns/mydns-ng/files/patch-Makefile.in +++ b/dns/mydns-ng/files/patch-Makefile.in @@ -1,10 +1,11 @@ ---- Makefile.in.orig 2009-03-22 05:02:50.000000000 +0800 -+++ Makefile.in 2009-03-22 05:02:56.000000000 +0800 -@@ -637,7 +637,6 @@ +--- Makefile.in.orig 2010-12-26 01:55:08.000000000 +0800 ++++ Makefile.in 2010-12-26 01:56:22.000000000 +0800 +@@ -721,7 +721,7 @@ install-data-am: @$(NORMAL_INSTALL) - $(MAKE) $(AM_MAKEFLAGS) install-data-hook - ++ install-dvi: install-dvi-recursive + install-dvi-am: diff --git a/dns/mydns-ng/files/patch-config.h.in b/dns/mydns-ng/files/patch-config.h.in new file mode 100644 index 000000000000..651528aa6f94 --- /dev/null +++ b/dns/mydns-ng/files/patch-config.h.in @@ -0,0 +1,11 @@ +--- config.h.in.orig 2010-12-26 02:19:27.000000000 +0800 ++++ config.h.in 2010-12-26 02:20:07.000000000 +0800 +@@ -225,7 +225,7 @@ + #undef HAVE_NETINET_IN_H + + /* Define to 1 if you have the header file. */ +-#undef HAVE_NET_IF_H ++#define HAVE_NET_IF_H 1 + + /* Define to 1 if you have the `nl_langinfo' function. */ + #undef HAVE_NL_LANGINFO diff --git a/dns/mydns-ng/files/patch-contrib_admin.php b/dns/mydns-ng/files/patch-contrib_admin.php deleted file mode 100644 index b5dceb24994f..000000000000 --- a/dns/mydns-ng/files/patch-contrib_admin.php +++ /dev/null @@ -1,58 +0,0 @@ ---- contrib/admin.php.orig 2009-01-30 12:21:32.000000000 +0000 -+++ contrib/admin.php 2009-05-27 03:13:57.000000000 +0000 -@@ -85,6 +85,15 @@ - */ - $auto_update_ptr = 0; - -+/* -+** This can automatically insert the defaults w/o updating the serial -+** number automatically. Sometimes you want to change entries but not -+** have the nameserver reload and start serving out new data. -+** -bek@monsterous.com -+*/ -+ -+$auto_defaults = 1; -+ - - /* - ** If this option is nonzero, this script will not complain if the -@@ -2052,7 +2061,7 @@ - global $soa_use_active, $soa_use_recursive, $soa_use_xfer, $soa_use_update_acl, $soa_use_also_notify; - global $rr_table_name, $soa_active_types, $soa_recursive_types; - global $default_refresh, $default_retry, $default_expire, $default_minimum_ttl, $default_ttl; -- global $default_ns, $default_mbox; -+ global $default_ns, $default_mbox, $auto_defaults; - global $soa_bgcolor, $zonenotify; - - $delete_confirm = 0; -@@ -2112,6 +2121,18 @@ - } else - $soa = $values = $_POST; - $new_soa = 1; -+ -+ if ($auto_defaults == 1) { -+ $soa['serial'] = date("Ymd01", time()); -+ $soa['refresh'] = $default_refresh; -+ $soa['retry'] = $default_retry; -+ $soa['expire'] = $default_expire; -+ $soa['minimum'] = $default_minimum_ttl; -+ $soa['ttl'] = $default_ttl; -+ $soa['ns'] = trim($default_ns); -+ $soa['mbox'] = trim($default_mbox); -+ $values = $soa; -+ } - } - - /* Set 'values' vars to avoid 'undefined' errors */ -@@ -2166,8 +2187,9 @@ - - -   -- ; Serial (next is ) --   -+ ; Serial (next is ) -+   - - - diff --git a/dns/mydns-ng/files/patch-src_mydns-1.2.8_main.c b/dns/mydns-ng/files/patch-src_mydns-1.2.8_main.c deleted file mode 100644 index 4fb595195526..000000000000 --- a/dns/mydns-ng/files/patch-src_mydns-1.2.8_main.c +++ /dev/null @@ -1,100 +0,0 @@ ---- src/mydns/main.c.orig 2010-01-26 05:17:05.000000000 +0800 -+++ src/mydns/main.c 2010-01-26 05:22:38.000000000 +0800 -@@ -513,11 +513,11 @@ - /* Close any TCP connections and any NOTIFY sockets */ - for (t = TaskP->head; t; t = TaskP->head) { - if (t->protocol == SOCK_STREAM && t->fd >= 0) -- sockclose(t->fd); -+ close(t->fd); - else if (t->protocol == SOCK_DGRAM - && (t->status & (ReqTask|TickTask|RunTask)) - && t->fd >= 0) -- sockclose(t->fd); -+ close(t->fd); - dequeue(t); - } - } -@@ -747,7 +747,7 @@ - if (shutting_down) server->pid = -1; - else { - if (server->listener) dequeue(server->listener); -- sockclose(server->serverfd); -+ close(server->serverfd); - RELEASE(server); - array_store(Servers, n, NULL); - if (n == 0) server = spawn_server(primary_initial_tasks); -@@ -1164,7 +1164,7 @@ - - #if HAVE_POLL - #if DEBUG_ENABLED -- DebugX("enabled", 1, _("Selecting for IO numfds = %d, timeout = %s(%d)"), numfds, -+ DebugX("enabled", 1, _("Polling for IO numfds = %d, timeout = %s(%d)"), numfds, - (timeoutWanted<0)?"no" - :(timeoutWanted==0)?"poll":"yes", timeoutWanted); - #endif -@@ -1175,6 +1175,10 @@ - if (errno == EAGAIN) { /* Could fail here but will log and retry */ - Warn(_("server_loop() received EAGAIN - retrying")); - continue; -+ } else { -+#if DEBUG_ENABLED -+ DebugX("enabled", 1, _("poll(): error %d: %s"), errno, strerror(errno)); -+#endif - } - RELEASE(items); - if (errno == EINVAL) { -@@ -1213,6 +1217,9 @@ - - if (rv < 0) { - if (errno == EINTR) continue; -+#if DEBUG_ENABLED -+ DebugX("enabled", 1, _("select(): error %d: %s"), errno, strerror(errno)); -+#endif - if (errno == EBADF) { - /* As we do not get told which FD failed here then purge and try again */ - purge_bad_tasks(); -@@ -1408,6 +1415,9 @@ - Warn(_("server_loop() received EAGAIN - retrying")); - continue; - } -+#if DEBUG_ENABLED -+ DebugX("enabled", 1, _("server_loop(): poll() errro %d: %s"), errno, strerror(errno)); -+#endif - RELEASE(items); - if (errno == EINVAL) { - Err(_("server_loop() received EINVAL consistency failure in call to poll/select")); -@@ -1445,6 +1455,9 @@ - - if (rv < 0) { - if (errno == EINTR) continue; -+#if DEBUG_ENABLED -+ DebugX("enabled", 1, _("server_loop(): select() errro %d: %s"), errno, strerror(errno)); -+#endif - if (errno == EBADF) { - /* As we do not get told which FD failed here then purge and try again */ - purge_bad_tasks(); -@@ -1466,9 +1479,6 @@ - if (FD_ISSET(fd, &efd)) { - item->revents |= POLLERR; - } --#if DEBUG_ENABLED -- DebugX("enabled", 1, _("Item fd = %d, events = %x, revents = %x"), fd, item->events, item->revents); --#endif - } - } - -@@ -1476,6 +1486,14 @@ - #error You must have either poll (preferred) or select to compile this code - #endif - #endif -+#if DEBUG_ENABLED -+ /* Debug socket states */ -+ for (i = 0; i < numfds; i++) { -+ struct pollfd *item = &items[i]; -+ int fd = item->fd; -+ DebugX("enabled", 1, _("Item fd = %d, events = %x, revents = %x"), fd, item->events, item->revents); -+ } -+#endif - gettick(); - - if (shutting_down) { break; } diff --git a/dns/mydns-ng/files/patch-src_mydns-1.2.8_resolve.c b/dns/mydns-ng/files/patch-src_mydns-1.2.8_resolve.c deleted file mode 100644 index 1d09653a5139..000000000000 --- a/dns/mydns-ng/files/patch-src_mydns-1.2.8_resolve.c +++ /dev/null @@ -1,76 +0,0 @@ ---- src/mydns/resolve.c.orig 2010-01-26 05:23:29.000000000 +0800 -+++ src/mydns/resolve.c 2010-01-26 05:25:46.000000000 +0800 -@@ -292,6 +292,7 @@ - register MYDNS_RR *rr = NULL; - taskexec_t rv = 0; - int recurs = wildcard_recursion; -+ char *savelabel = label; - - #if DEBUG_ENABLED && DEBUG_RESOLVE - DebugX("resolve", 1, _("%s: resolve_label(%s, %s, %s, %s, %d)"), desctask(t), -@@ -312,6 +313,34 @@ - return (rv); - } - -+ /* No exact match */ -+ /* Check for NS delegation */ -+ while (*label) { -+ if ((rr = find_rr(t, soa, DNS_QTYPE_NS, label))) { -+ char *newfqdn; -+ if (LASTCHAR(label) == '.') { -+ newfqdn = STRDUP(label); -+ } else { -+ ASPRINTF(&newfqdn, "%s.%s", label, soa->origin); -+ } -+ rv = process_rr(t, AUTHORITY, qtype, newfqdn, soa, label, rr, level); -+ mydns_rr_free(rr); -+ RELEASE(newfqdn); -+ add_authority_ns(t, section, soa, label); -+#if DEBUG_ENABLED && DEBUG_RESOLVE -+ DebugX("resolve", 1, _("%s: resolve_label(%s) returning results %s"), desctask(t), -+ fqdn, task_exec_name(rv)); -+#endif -+ return (rv); -+ } -+ label = strchr(label, '.'); -+ if (!label) break; -+ label++; -+ } -+ /* No NS delegation. */ -+ /* Restore label, it may have been modified above */ -+ label = savelabel; -+ - /* - * No exact match. - * If `label' isn't empty, replace the first part of the label with `*' -@@ -420,30 +449,6 @@ - } - - NOWILDCARDMATCH: -- /* STILL no match - check for NS records for child delegation */ -- while (*label) { -- if ((rr = find_rr(t, soa, DNS_QTYPE_NS, label))) { -- char *newfqdn; -- if (LASTCHAR(label) == '.') { -- newfqdn = STRDUP(label); -- } else { -- ASPRINTF(&newfqdn, "%s.%s", label, soa->origin); -- } -- rv = process_rr(t, AUTHORITY, qtype, newfqdn, soa, label, rr, level); -- mydns_rr_free(rr); -- RELEASE(newfqdn); -- add_authority_ns(t, section, soa, label); --#if DEBUG_ENABLED && DEBUG_RESOLVE -- DebugX("resolve", 1, _("%s: resolve_label(%s) returning results %s"), desctask(t), -- fqdn, task_exec_name(rv)); --#endif -- return (rv); -- } -- label = strchr(label, '.'); -- if (!label) break; -- label++; -- } -- - return (TASK_EXECUTED); - } - /*--- resolve_label() ---------------------------------------------------------------------------*/ diff --git a/dns/mydns-ng/files/patch-src_mydns-1.2.8_servercomms.c b/dns/mydns-ng/files/patch-src_mydns-1.2.8_servercomms.c deleted file mode 100644 index dc96f34a3edb..000000000000 --- a/dns/mydns-ng/files/patch-src_mydns-1.2.8_servercomms.c +++ /dev/null @@ -1,16 +0,0 @@ ---- src/mydns/servercomms.c.orig 2010-01-26 05:26:08.000000000 +0800 -+++ src/mydns/servercomms.c 2010-01-26 05:26:45.000000000 +0800 -@@ -406,7 +406,12 @@ - DebugX("servercomms", 1, _("%s: Server comms tick - master has not pinged for %d seconds"), desctask(t), - lastseen); - #endif -- named_shutdown(0); -+ if (abs(lastseen) > 10*KEEPALIVE) { -+ Notice(_("Possible clock jump: master has not pinged for %d seconds"), lastseen); -+ } else { -+ Notice(_("Client shutdown: %s: master has not pinged for %d seconds"), desctask(t), lastseen); -+ named_shutdown(0); -+ } - } - - return TASK_CONTINUE; diff --git a/dns/mydns-ng/pkg-plist b/dns/mydns-ng/pkg-plist index e3a9885b5c5f..5f37d6844fd9 100644 --- a/dns/mydns-ng/pkg-plist +++ b/dns/mydns-ng/pkg-plist @@ -17,7 +17,6 @@ sbin/mydns %%PORTDOCS%%%%DOCSDIR%%/contrib/README %%PORTDOCS%%%%DOCSDIR%%/contrib/admin.php %%PORTDOCS%%%%DOCSDIR%%/contrib/create_domain.pl -%%PORTDOCS%%%%DOCSDIR%%/contrib/fix_rr_serial.pl %%PORTDOCS%%%%DOCSDIR%%/contrib/stats.php %%NLS%%share/locale/es/LC_MESSAGES/mydns.mo %%NLS%%share/locale/fr/LC_MESSAGES/mydns.mo -- cgit v1.2.3