NetBSD Problem Report #6758
Received: (qmail 5023 invoked from network); 7 Jan 1999 17:15:09 -0000
Message-Id: <19990107171233.3663810@proven.weird.com>
Date: Thu, 7 Jan 1999 12:12:33 -0500 (EST)
From: woods@proven.weird.com
Reply-To: woods@weird.com
To: gnats-bugs@gnats.netbsd.org
Subject: PostgreSQL (6.4.2) package install doesn't work very well
X-Send-Pr-Version: 3.95
>Number: 6758
>Category: pkg
>Synopsis: PostgreSQL (6.4.2) package install doesn't work very well
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: gnats-admin
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Jan 07 09:20:00 +0000 1999
>Closed-Date: Tue Jan 26 12:53:24 +0000 1999
>Last-Modified: Tue Jan 26 12:54:06 +0000 1999
>Originator: Greg A. Woods
>Release: pkgsrc sup Wed Jan 6 08:05:41 EST 1999
>Organization:
Planix, Inc.; Toronto, Ontario; Canada
>Environment:
System: NetBSD proven 1.3I NetBSD 1.3I (GENERIC) #1: Thu Dec 3 16:23:20 EST 1998 root@woffi.planix.com:/local1/netbsd/netbsd-current/src/sys/arch/i386/compile/GENERIC i386
>Description:
The PostgreSQL package fails to detect TK, fails to install
manual pages, and the PLIST mentions one file that's not
installed.
The warning about editing /etc/ld.so.conf is displayed long
before installation ends and will scroll off even a 45 line
window.
Re-installation will break because "mkdir" errors are not
ignored as they always should be.
>How-To-Repeat:
cd /usr/pkgsrc/databases/postgresql
make install
>Fix:
apply the following patch:
Index: pkgsrc/databases/postgresql/Makefile
===================================================================
RCS file: /cvs/NetBSD/pkgsrc/databases/postgresql/Makefile,v
retrieving revision 1.1.1.13
diff -c -r1.1.1.13 pkgsrc/databases/postgresql/Makefile
*** pkgsrc/databases/postgresql/Makefile 1999/01/07 04:57:22 1.1.1.13
--- pkgsrc/databases/postgresql/Makefile 1999/01/07 17:02:16
***************
*** 33,44 ****
CONFIGURE_ARGS= --prefix=${PREFIX}/${PGUSER} \
--enable-locale \
--with-tcl \
! --with-tclconfig=${PREFIX}/lib/tcl8.0 \
--with-includes=${PREFIX}/include \
--with-libs=${PREFIX}/lib \
--with-template=`${ECHO} ${OPSYS} | ${TR} '[A-Z]' '[a-z]'`
CONFIGURE_ENV+= CPPFLAGS="-I${PREFIX}/include/tcl8.0 -I${PREFIX}/include/tk8.0"
.include "../../mk/bsd.prefs.mk"
pre-extract:
--- 33,46 ----
CONFIGURE_ARGS= --prefix=${PREFIX}/${PGUSER} \
--enable-locale \
--with-tcl \
! --with-tclconfig="${PREFIX}/lib/tcl8.0 ${PREFIX}/lib/tk8.0 " \
--with-includes=${PREFIX}/include \
--with-libs=${PREFIX}/lib \
--with-template=`${ECHO} ${OPSYS} | ${TR} '[A-Z]' '[a-z]'`
CONFIGURE_ENV+= CPPFLAGS="-I${PREFIX}/include/tcl8.0 -I${PREFIX}/include/tk8.0"
+ INSTALL_TARGET= install install-man
+
.include "../../mk/bsd.prefs.mk"
pre-extract:
***************
*** 70,76 ****
.if defined(PACKAGE_BUILDING)
${RM} -rf ${PREFIX}/${PGUSER}
.endif
! @${MKDIR} ${PREFIX}/${PGUSER}
@${SETENV} ${MAKE_ENV} addnerd -h ${PREFIX} -g ${PGGROUP} ${PGUSER}
@${SED} -e 's|@PGUSER@|${PGUSER}|g' ${PKGDIR}/PLIST > ${PLIST_SRC}
--- 72,78 ----
.if defined(PACKAGE_BUILDING)
${RM} -rf ${PREFIX}/${PGUSER}
.endif
! -@${MKDIR} ${PREFIX}/${PGUSER}
@${SETENV} ${MAKE_ENV} addnerd -h ${PREFIX} -g ${PGGROUP} ${PGUSER}
@${SED} -e 's|@PGUSER@|${PGUSER}|g' ${PKGDIR}/PLIST > ${PLIST_SRC}
***************
*** 99,112 ****
fi
@/usr/sbin/chown -R ${PGUSER}:${PGGROUP} ${PREFIX}/${PGUSER}
@${ECHO} 'Initializing PostgreSQL Databases - this may take a few minutes...'
- @case `${GREP} -c '^${PREFIX}/${PGUSER}/lib$$' /etc/ld.so.conf` in \
- 0) \
- ${ECHO} "************** WARNING ********************"; \
- ${ECHO} "Please add ${PREFIX}/${PGUSER}/lib to /etc/ld.so.conf";\
- ${ECHO} "so that this package is usable after any reboot"; \
- ${ECHO} "************** WARNING ********************"; \
- ;; \
- esac
${LDCONFIG} ${PREFIX}/${PGUSER}/lib || ${TRUE}
@${ECHO} '${SETENV} PATH=${PREFIX}/${PGUSER}/bin:$$PATH ${PREFIX}/${PGUSER}/bin/initdb --pglib=${PREFIX}/${PGUSER}/lib --pgdata=${PREFIX}/${PGUSER}/data' | su -l ${PGUSER}
@${SED} -e "s=!!PREFIX!!=${PREFIX}=g" -e "s=!!PGUSER!!=${PGUSER}=g" \
--- 101,106 ----
***************
*** 116,122 ****
@${INSTALL} -c -o ${PGUSER} -g ${PGGROUP} -m 444 \
${FILESDIR}/post-install-notes ${PREFIX}/${PGUSER}
.if !defined(NOPORTDOCS)
! ${MKDIR} ${PREFIX}/share/doc/pgsql
${CP} -R ${WRKDIR}/${DISTNAME}/doc/* ${PREFIX}/share/doc/pgsql
${RM} -rf ${PREFIX}/share/doc/pgsql/src/CVS \
${PREFIX}/share/doc/pgsql/src/graphics/CVS \
--- 110,116 ----
@${INSTALL} -c -o ${PGUSER} -g ${PGGROUP} -m 444 \
${FILESDIR}/post-install-notes ${PREFIX}/${PGUSER}
.if !defined(NOPORTDOCS)
! -${MKDIR} ${PREFIX}/share/doc/pgsql
${CP} -R ${WRKDIR}/${DISTNAME}/doc/* ${PREFIX}/share/doc/pgsql
${RM} -rf ${PREFIX}/share/doc/pgsql/src/CVS \
${PREFIX}/share/doc/pgsql/src/graphics/CVS \
***************
*** 127,131 ****
--- 121,133 ----
.if !defined(BATCH)
@${CAT} ${FILESDIR}/post-install-notes
.endif
+ @case `${GREP} -c '^${PREFIX}/${PGUSER}/lib$$' /etc/ld.so.conf` in \
+ 0) \
+ ${ECHO} "************** WARNING ********************"; \
+ ${ECHO} "Please add ${PREFIX}/${PGUSER}/lib to /etc/ld.so.conf";\
+ ${ECHO} "so that this package is usable after any reboot"; \
+ ${ECHO} "************** WARNING ********************"; \
+ ;; \
+ esac
.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/databases/postgresql/pkg/PLIST
===================================================================
RCS file: /cvs/NetBSD/pkgsrc/databases/postgresql/pkg/PLIST,v
retrieving revision 1.1.1.6
diff -c -r1.1.1.6 pkgsrc/databases/postgresql/pkg/PLIST
*** pkgsrc/databases/postgresql/pkg/PLIST 1999/01/07 04:57:25 1.1.1.6
--- pkgsrc/databases/postgresql/pkg/PLIST 1999/01/07 17:03:20
***************
*** 204,210 ****
@PGUSER@/lib/libpgtcl.so.2
@PGUSER@/lib/libpgtcl.so
@PGUSER@/lib/plpgsql.so
- @PGUSER@/lib/pltcl.so
@PGUSER@/bin/postgres
@PGUSER@/bin/postmaster
@PGUSER@/bin/ecpg
--- 204,209 ----
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback
State-Changed-By: frueauf
State-Changed-When: Thu Jan 7 12:28:42 PST 1999
State-Changed-Why:
Hello!
While I may consider some of your changes, can you please verify that
your files were uptodate? Especially
patch-aa:
$NetBSD: patch-aa,v 1.1 1999/01/04 13:05:01 frueauf Exp $
patch-ab:
$NetBSD: patch-ab,v 1.5 1999/01/04 13:05:01 frueauf Exp $
patch-ac:
$NetBSD: patch-ac,v 1.3 1999/01/04 13:05:01 frueauf Exp $
patch-ad:
$NetBSD: patch-ad,v 1.4 1999/01/04 13:05:01 frueauf Exp $
patch-ae:
$NetBSD: patch-ae,v 1.4 1999/01/04 13:05:02 frueauf Exp $
With those either tk should be found, man pages be installed and PLIST
should be sane. I will evaluate your patch after I am sure that your
files were uptodate - but then I would not understand the lossage, as
it all works for me.
Greets
Thorsten
From: woods@most.weird.com (Greg A. Woods)
To: frueauf@netbsd.org
Cc: gnats-bugs@gnats.netbsd.org (NetBSD GNATS submissions and followups),
gnats-admin@netbsd.org
Subject: Re: pkg/6758
Date: Thu, 7 Jan 1999 17:21:53 -0500 (EST)
[ On , January 7, 1999 at 20:33:06 (-0000), frueauf@netbsd.org wrote: ]
> Subject: Re: pkg/6758
>
> While I may consider some of your changes, can you please verify that
> your files were uptodate? Especially
Oh, DAMN! Sorry! CVS has really embarassed me.
I'd been relying on what I thought was the newly "fixed" behaviour of
resurrecting files. Now I find it doesn't work in 1.10.4.1. Grrr...
(Of course I can always blame the somewhat silly practice of keeping
patches in separate files for this screw up.... ;-)
I only had patch-aa and patch-ab (which were up-to-date). The others
were missing because they had been resurrected since my last sup.
> With those either tk should be found, man pages be installed and PLIST
> should be sane. I will evaluate your patch after I am sure that your
> files were uptodate - but then I would not understand the lossage, as
> it all works for me.
Well, I've read through those patches (i.e. patch-a{c,d,e}), and I see
how they would fix the problem, but they are, in my opinion, the wrong
way to do so.
Clearly tclsh should be there -- it's referenced in many places, not
just the original PostgreSQL configuration tools.
I think that from my reading of the PostgreSQL configuration scripts
that it's clear the best way to configure tcl+tk is to pass both
directories into "--with-tclconfig" as I suggested. This also avoids
the "tclsh8.0" vs. "tclsh" issue in the first place. Besides, I'm not
sure how safe it is to assume that "tk8.0" is adjacent to "tcl8.0",
though it's probably OK to do so for pkgsrc (it's certainly not a change
I would accept as generic if I were the PostgreSQL maintainers).
I think that the best way to fix the "install-man" problem is the way I
suggested with "INSTALL_TARGET" setting in the Makefile. Doing this
through a patch is a hack and much more difficult to maintain (and also
seems contrary to the intent of a package using an "install-man" target).
Lastly I think that patching "configure" (instead of just configure.in)
is a bad idea, especially since autoconf is in the pkgsrc tree and can
be used to regenerate "configure" if indeed configure.in really really
has to be patched. Besides, my suggested change to the pkgsrc Makefile
eliminates the need for those additional changes to the configure stuff.
Oh, and even with those patch files in place, the "pltcl.so" file is not
built or installed. I suspect the reason it's not built is that
TCL_SHARED_BUILD is turned off in NetBSD's pkgsrc/lang/tcl80 (because we
use libtool, according to the comment in the Makefile).
BTW, why doesn't PostreSQL depend on perl and build the perl interface?
(not that I want either the perl or tcl interfaces -- I just want the
python one, and maybe one for guile and/or STk!)
--
Greg A. Woods
+1 416 218-0098 VE3TCP <gwoods@acm.org> <robohack!woods>
Planix, Inc. <woods@planix.com>; Secrets of the Weird <woods@weird.com>
From: Thorsten Frueauf <frueauf@ira.uka.de>
To: gnats-bugs@gnats.netbsd.org
Cc: frueauf@netbsd.org, gnats-admin@netbsd.org
Subject: Re: pkg/6758
Date: Fri, 8 Jan 1999 12:25:54 +0100 (MET)
Hello!
> Oh, DAMN! Sorry! CVS has really embarassed me.
Ok, at least I am happy that I did not commit a totally unworkable package :)
I do my best to test things before I commit them, so total lossage
would really surprise me :)
> Clearly tclsh should be there -- it's referenced in many places, not
> just the original PostgreSQL configuration tools.
I leave that to someone more sophisticated with tcl/tk - I can also see
arguments against that link. So far we always did the right thing
for our packages, and the postgresql package does find tclsh8.0.
> though it's probably OK to do so for pkgsrc (it's certainly not a change
> I would accept as generic if I were the PostgreSQL maintainers).
Sure, I would not feedback that patch to the postgresql ppl. Its just
for pkgsrc - at least thats why we have our patch dir :-)
> I think that the best way to fix the "install-man" problem is the way I
> suggested with "INSTALL_TARGET" setting in the Makefile. Doing this
> through a patch is a hack and much more difficult to maintain (and also
> seems contrary to the intent of a package using an "install-man" target).
I did commit that change.
> Lastly I think that patching "configure" (instead of just configure.in)
> is a bad idea, especially since autoconf is in the pkgsrc tree and can
> be used to regenerate "configure" if indeed configure.in really really
> has to be patched. Besides, my suggested change to the pkgsrc Makefile
> eliminates the need for those additional changes to the configure stuff.
Well, I don't want to add yet another dependency. I provided patches
for configure.in and configure for better maintainace, of course
I used autoconf to make the new configure. So far I need to patch
configure to make it find our tclsh8.0 (see arguments above).
> Oh, and even with those patch files in place, the "pltcl.so" file is not
> built or installed. I suspect the reason it's not built is that
> TCL_SHARED_BUILD is turned off in NetBSD's pkgsrc/lang/tcl80 (because we
> use libtool, according to the comment in the Makefile).
I wrote a mail to tech-pkg about this. Once I know why this is the
case I will adjust PLIST. I happened to have an older version of
our pkgsrc tcl80 package installed where this option was set
(from pre-libtoolisation times). Lets see if someone replies.
> BTW, why doesn't PostreSQL depend on perl and build the perl interface?
Well, I did adopt the former version where it was switched off already.
Maybe to prevent the package to get into monster-depends.
Greets
Thorsten
State-Changed-From-To: feedback->closed
State-Changed-By: frueauf
State-Changed-When: Tue Jan 26 04:53:24 PST 1999
State-Changed-Why:
All parts of this pr should now be resolved.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.