From chris@aims.com.au  Sat Dec  1 00:37:40 2001
Return-Path: <chris@aims.com.au>
Received: from postoffice.aims.com.au (eth0.lnk.aims.com.au [203.31.73.253])
	by hub.freebsd.org (Postfix) with ESMTP id 2095C37B416
	for <freebsd-gnats-submit@freebsd.org>; Sat,  1 Dec 2001 00:37:38 -0800 (PST)
Received: from postoffice.aims.com.au (nts-ts1.aims.private [192.168.10.2])
	by postoffice.aims.com.au  with ESMTP id fB18bZ676132
	for <freebsd-gnats-submit@freebsd.org>; Sat, 1 Dec 2001 19:37:36 +1100 (EST)
	(envelope-from chris@aims.com.au)
Received: from ntsts1 by aims.com.au
	with SMTP (MDaemon.v3.5.3.R)
	for <freebsd-gnats-submit@freebsd.org>; Sat, 01 Dec 2001 19:37:14 +1100
Message-Id: <200112010831.fB18VB677780@dbserver2.aims.private>
Date: Sat, 1 Dec 2001 19:37:11 +1100
From: chris@aims.com.au
Reply-To: <chris@aims.com.au>
To: <freebsd-gnats-submit@freebsd.org>
Subject: [MAINTAINER UPDATE] databases/firebird
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         32423
>Category:       ports
>Synopsis:       [MAINTAINER UPDATE] dataases/firebird
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Sat Dec 01 00:40:01 PST 2001
>Closed-Date:    Sun Dec 2 09:53:20 PST 2001
>Last-Modified:  Sun Dec 02 09:53:33 PST 2001
>Originator:     Chris Knight
>Release:        FreeBSD 4.3-RELEASE i386
>Organization:
AIMS Independent Computer Professionals
>Environment:

System: FreeBSD dbserver2.aims.private 4.3-RELEASE FreeBSD 4.3-RELEASE #6: Wed Oct 3 16:13:28 EST 2001
root@dbserver2.aims.private:/usr/src/sys/compile/DBSERVER i386

>Description:

Various updates to the firebird port:
- fix pkg-message display
- move shared libs permissions fix to a more appropriate location
- fix UDF loading problem
- DES crypt used on 4.4 and 5.0 regardless of /etc/auth.conf settings
- shared libraries registered at system startup
- allow package to be installed at FreeBSD install time (inetd run check)

This allows the following PRs to be closed:
ports/31641
ports/30185
ports/25907

>How-To-Repeat:

N/A

>Fix:

Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/databases/firebird/Makefile,v
retrieving revision 1.4
diff -u -r1.4 Makefile
--- Makefile	2001/11/30 01:04:14	1.4
+++ Makefile	2001/12/01 06:12:43
@@ -20,6 +20,8 @@
 WRKSRC=		${WRKDIR}/interbase
 INSTALLS_SHLIB=	yes
 LDCONFIG_DIRS=	%%PREFIX%%/firebird/lib
+MSG_FILE=	${PKGDIR}/pkg-message
+PKGMESSAGE=	${WRKDIR}/pkg-message

 ONLY_FOR_ARCHS=	i386

@@ -28,14 +30,18 @@
 do-extract:
 	@${MKDIR} ${WRKDIR}
 	@(								\
-	cd ${WRKDIR}; tar zxf ${DISTDIR}/interbase0.9-4src.tar.gz;	\
-	cd interbase; tar zxf ${DISTDIR}/firebird-boot-kit.tar.gz;	\
+	cd ${WRKDIR}; ${TAR} -xzf ${DISTDIR}/interbase0.9-4src.tar.gz;	\
+	cd interbase; ${TAR} -xzf ${DISTDIR}/firebird-boot-kit.tar.gz;	\
 	${CP} msgs/msg.gbak misc/msg.gbak				\
 	)

-.if ${OSVERSION} >= 500016
 post-patch:
-	${PERL} -pi -e 's,\-ldescrypt,\-lcrypt,g' ${WRKSRC}/builds/original/prefix.freebsd
+	@${SED} 's|%%PREFIX%%|${PREFIX}|g' ${MSG_FILE} > ${PKGMESSAGE}
+.if ${OSVERSION} >= 500016 || ${OSVERSION} >= 430001
+	@${PERL} -pi -e 's,\-ldescrypt,\-lcrypt,g' \
+		 ${WRKSRC}/builds/original/prefix.freebsd
+.else
+	@${PERL} -pi -e 's,^crypt_set_format.*,,' ${WRKSRC}/jrd/enc.c
 .endif

 do-configure:
@@ -49,6 +55,10 @@

 do-build:
 	@(								\
+	 ${ECHO} '#!/bin/sh'; ${ECHO}					\
+	'[ -d ${LDCONFIG_RUNLIST} ] && ${LDCONFIG} -m ${LDCONFIG_RUNLIST}'; \
+	) > ${WRKDIR}/000.${PORTNAME}.sh
+	@(								\
 	cd ${WRKDIR}/interbase;						\
 	INTERBASE=${WRKDIR}/interbase/interbase; export INTERBASE;	\
 	REFDBPATH=${WRKDIR}/refDatabases; export REFDBPATH;		\
@@ -62,11 +72,10 @@
 	${RM} ${PREFIX}/firebird/install;				\
 	${RM} ${PREFIX}/firebird/lib/libgds.so.1.0;			\
 	${LN} -fs gds.so ${PREFIX}/firebird/lib/libgds.so.1;		\
-	${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${PREFIX}/firebird/lib	\
-	${CHMOD} -R g-w ${PREFIX}/firebird/lib				\
 	cd ${PREFIX}/firebird/examples;					\
-	tar zxf ${DISTDIR}/interbase0.9-4-v5examples.tar.gz;		\
-	${CP} ${FILESDIR}/RELNOTES ${PREFIX}/firebird/			\
+	${TAR} -xzf ${DISTDIR}/interbase0.9-4-v5examples.tar.gz;	\
+	${CP} ${FILESDIR}/RELNOTES ${PREFIX}/firebird/;			\
+	${INSTALL_SCRIPT} ${WRKDIR}/000.${PORTNAME}.sh ${PREFIX}/etc/rc.d/ \
 	)

 .include <bsd.port.post.mk>
Index: pkg-descr
===================================================================
RCS file: /home/ncvs/ports/databases/firebird/pkg-descr,v
retrieving revision 1.1
diff -u -r1.1 pkg-descr
--- pkg-descr	2001/03/10 20:32:33	1.1
+++ pkg-descr	2001/12/01 01:27:41
@@ -13,6 +13,7 @@
 http://www.ibphoenix.com/
 http://www.interbase2000.org/
 http://www.interbase.com/
+http://www.firebirdsql.org/

 and of course the firebird page itself:
 WWW: http://sourceforge.net/projects/firebird/
Index: pkg-install
===================================================================
RCS file: /home/ncvs/ports/databases/firebird/pkg-install,v
retrieving revision 1.2
diff -u -r1.2 pkg-install
--- pkg-install	2001/11/29 18:00:12	1.2
+++ pkg-install	2001/12/01 05:48:56
@@ -73,10 +73,6 @@
 elif [ "$2" = "POST-INSTALL" ]; then
 chown -R firebird:firebird $PKG_PREFIX/firebird

-# make lib ldconfig-compatible
-chown -R root:wheel $PKG_PREFIX/firebird/lib
-chmod -R g-w $PKG_PREFIX/firebird/lib
-
 # Turn everybody to read only.
 chmod -R o=r $PKG_PREFIX/firebird

@@ -92,7 +88,13 @@
      fi
   done

+# make lib ldconfig-compatible
+chown -R root:wheel $PKG_PREFIX/firebird/lib
+chmod -R g-w $PKG_PREFIX/firebird/lib

+# Fix UDF load problem
+cd $PKG_PREFIX/firebird/lib
+ln -sf ib_util.so libib_util.so

 cd $PKG_PREFIX/firebird/bin

@@ -143,7 +145,15 @@
 cat >>/etc/inetd.conf <<EOF
 gds_db	stream	tcp	nowait	firebird	/usr/interbase/bin/gds_inet_server  gds_inet_server
 EOF
-kill -HUP `cat /var/run/inetd.pid`
-kill -HUP `cat /var/run/inetd.pid`
+if [ -f /var/run/inetd.pid ]; then
+	kill -HUP `cat /var/run/inetd.pid`
+fi
+
+# shared lib startup script
+if [ -d $PKG_PREFIX/etc/rc.d ]; then
+	(
+	echo "#!/bin/sh"; echo "[ -d $PKG_PREFIX/firebird/lib ] && /sbin/ldconfig -m $PKG_PREFIX/firebird/lib"
+	) > $PKG_PREFIX/etc/rc.d/000.firebird.sh
+fi

 fi
Index: pkg-plist
===================================================================
RCS file: /home/ncvs/ports/databases/firebird/pkg-plist,v
retrieving revision 1.1
diff -u -r1.1 pkg-plist
--- pkg-plist	2001/03/10 20:32:33	1.1
+++ pkg-plist	2001/12/01 04:32:02
@@ -1,3 +1,4 @@
+etc/rc.d/000.firebird.sh
 firebird/intl/gdsintl
 firebird/examples/v5/ib_udf.sql
 firebird/examples/v5/README
@@ -65,6 +66,7 @@
 firebird/lib/libgds.so.1
 firebird/lib/libgds_pyxis.a
 firebird/lib/libgds.a
+firebird/lib/libib_util.so
 firebird/lib/gds_pyxis.a
 firebird/help/help.gbak
 firebird/help/help.gdb
Index: files/RELNOTES
===================================================================
RCS file: /home/ncvs/ports/databases/firebird/files/RELNOTES,v
retrieving revision 1.1
diff -u -r1.1 RELNOTES
--- files/RELNOTES	2001/03/10 20:32:33	1.1
+++ files/RELNOTES	2001/12/01 01:16:58
@@ -73,6 +73,7 @@
 	http://sourceforge.net/projects/firebird/
 	http://www.ibphoenix.com/
 	http://www.interbase2000.org/
+	http://www.firebirdsql.org/

 Geoff Speicher
 <geoff@sea-incorporated.com>
Index: files/patch-ad
===================================================================
RCS file: patch-ad
diff -N patch-ad
--- /dev/null	Sat Dec  1 19:00:00 2001
+++ patch-ad	Sat Dec  1 12:26:17 2001
@@ -0,0 +1,13 @@
+--- jrd/enc.c.orig	Fri Aug  4 06:50:03 2000
++++ jrd/enc.c	Sun Nov 18 19:17:19 2001
+@@ -31,6 +31,10 @@
+  *
+  **************************************/
+
++#ifdef FREEBSD
++crypt_set_format("des");
++#endif
++
+ return CRYPT_FUNC( string, salt);
+ }
+ #endif
Index: scripts/post-install
===================================================================
RCS file: /home/ncvs/ports/databases/firebird/scripts/post-install,v
retrieving revision 1.1
diff -u -r1.1 post-install
--- scripts/post-install	2001/03/10 20:32:33	1.1
+++ scripts/post-install	2001/12/01 04:17:25
@@ -17,8 +17,14 @@
      fi
   done

+# make lib ldconfig-compatible
+chown -R root:wheel $PREFIX/firebird/lib
+chmod -R g-w $PREFIX/firebird/lib
+
+# Fix UDF load problem
+cd $PREFIX/firebird/lib
+ln -sf ib_util.so libib_util.so

-
 cd $PREFIX/firebird/bin

 # all users can run everything.
@@ -58,7 +64,9 @@

 # add the gds service and restart inetd
 sh $SCRIPTDIR/addservice
-kill -HUP `cat /var/run/inetd.pid`
+if [ -f /var/run/inetd.pid ]; then
+	kill -HUP `cat /var/run/inetd.pid`
+fi

 sed "s|%%PREFIX%%|$PREFIX|" $SCRIPTDIR/../pkg-message


>Release-Note:
>Audit-Trail:

From: "Chris Knight" <chris@aims.com.au>
To: <freebsd-gnats-submit@FreeBSD.org>, <chris@aims.com.au>
Cc:  
Subject: Re: ports/32423: [MAINTAINER UPDATE] dataases/firebird
Date: Sat, 1 Dec 2001 19:51:27 +1100

 Howdy,
 
 Could the person that commits this please set PORTEPOCH to 1 in the
 Makefile? Thanks.
 
 Regards,
 Chris Knight
 Systems Administrator
 AIMS Independent Computer Professionals
 Tel: +61 3 6334 6664  Fax: +61 3 6331 7032  Mob: +61 419 528 795
 Web: http://www.aims.com.au
 
 
State-Changed-From-To: open->closed 
State-Changed-By: demon 
State-Changed-When: Sun Dec 2 09:53:20 PST 2001 
State-Changed-Why:  
Patch committed, thanks! 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=32423 
>Unformatted:
