Update ispman to 0.5nb1. Fixes some bugs in the ldap2named script.

This commit is contained in:
rh 2000-11-22 10:44:51 +00:00
parent 01aeef90ab
commit cffd0848a0
3 changed files with 50 additions and 3 deletions

View file

@ -1,7 +1,8 @@
# $NetBSD: Makefile,v 1.2 2000/11/11 17:49:27 tron Exp $
# $NetBSD: Makefile,v 1.3 2000/11/22 10:44:51 rh Exp $
#
DISTNAME= ispman-0.5
PKGNAME= ${DISTNAME}nb1
WRKSRC= ${WRKDIR}/ispman
CATEGORIES= net
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=ispman/}
@ -9,7 +10,7 @@ MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=ispman/}
MAINTAINER= rh@netbsd.org
HOMEPAGE= http://www.ispman.org/
DEPENDS+= openldap>=1.2.11:../../databases/openldap
DEPENDS+= pam-ldap>=77:../../security/pam-ldap
DEPENDS+= apache>=1.3.14.1:../../www/apache
DEPENDS+= p5-${DISTNAME}:../../net/p5-ispman
@ -33,6 +34,9 @@ do-build:
.for dir in ispman-utils ispman-web
cd ${WRKSRC}/${dir} && \
${RM} -rf `${FIND} . -name CVS -type d -print` && \
for i in `${FIND} . -name '*.orig' -type f -print` ; do \
${RM} -f $$i ; \
done ; \
for i in `${FIND} . -type f -print` ; do \
${CP} $$i $$i.old && \
${SED} <$$i.old >$$i -e 's:/usr/bin/perl:${PERL5}:g' && \

View file

@ -1,3 +1,4 @@
$NetBSD: patch-sum,v 1.1.1.1 2000/10/21 19:02:32 rh Exp $
$NetBSD: patch-sum,v 1.2 2000/11/22 10:44:52 rh Exp $
MD5 (patch-aa) = cb7aa89f3d0c32c38255eb88d58a8add
MD5 (patch-ab) = 9df7f856f5e24efb08f059ee64ca834a

View file

@ -0,0 +1,42 @@
$NetBSD: patch-ab,v 1.1 2000/11/22 10:44:52 rh Exp $
--- ispman-utils/bin/ldap2named.orig Sat Sep 23 01:24:28 2000
+++ ispman-utils/bin/ldap2named
@@ -31,7 +31,10 @@
if ($soa) {
- print ZONE "@ IN SOA $soa->{'primary'}. $soa->{'rootmail'}. (\n";
+ my $primary = $soa->{'primary'};
+ $primary="$primary\." if (($primary =~ /\./) && ($primary !~ /\.$/));
+ print ZONE "\$TTL $soa->{'minimum'}\n";
+ print ZONE "@ IN SOA $primary $soa->{'rootmail'}. (\n";
for (qw(serial refresh retry expire minimum)) {
print ZONE "\t $soa->{$_} ; $_\n";
}
@@ -45,7 +48,7 @@
print ZONE "\n; NS RECORDS\n";
for (@$nsrecords) {
my ($origion, $host)=split(/\s*,\s*/, $_);
- $host=($host=~/\.$/)?$host: "$host\.";
+ $host="$host\." if (($host =~ /\./) && ($host !~ /\.$/));
print ZONE "$origion IN NS $host\n";
}
@@ -55,7 +58,7 @@
for (@$mxrecords) {
my ($origion, ,$pref, $host)=split(/\s*,\s*/, $_);
- $host=($host=~/\.$/)?$host: "$host\.";
+ $host="$host\." if (($host =~ /\./) && ($host !~ /\.$/));
print ZONE "$origion IN MX $pref $host\n";
}
@@ -72,6 +75,7 @@
my $cnames=$ispman->getRecords($domains->{$domain}, "cnames");
for (@$cnames) {
my ($alias, $host)=split(/\s*,\s*/, $_);
+ $host="$host\." if (($host =~ /\./) && ($host !~ /\.$/));
print ZONE "$alias IN CNAME $host\n";
}