The pgsql include files moved to LOCALBASE/include/postgresql a while ago.
Convert to using pgsql.buildlink3.mk so that it works with both 7.3 and 7.4 (and pkgviews too), and simplify build process a little.
This commit is contained in:
parent
6cff385968
commit
852c60fe0a
4 changed files with 25 additions and 29 deletions
|
@ -1,7 +1,7 @@
|
|||
# $NetBSD: Makefile,v 1.12 2004/12/30 13:23:15 wiz Exp $
|
||||
# $NetBSD: Makefile,v 1.13 2005/01/05 21:15:15 tv Exp $
|
||||
#
|
||||
|
||||
DISTNAME= pkgconflict-0.3.1
|
||||
DISTNAME= pkgconflict-0.4
|
||||
CATEGORIES= pkgtools
|
||||
MASTER_SITES= # empty
|
||||
DISTFILES= # empty
|
||||
|
@ -9,22 +9,29 @@ DISTFILES= # empty
|
|||
MAINTAINER= wennmach@NetBSD.org
|
||||
COMMENT= Scripts to find conflicting packages in pkgsrc
|
||||
|
||||
DEPENDS+= postgresql73>=7.0:../../databases/postgresql73
|
||||
|
||||
WRKSRC= ${WRKDIR}
|
||||
NO_CHECKSUM= yes
|
||||
NO_CONFIGURE= yes
|
||||
PKG_INSTALLATION_TYPES= overwrite pkgviews
|
||||
USE_BUILDLINK3= yes
|
||||
|
||||
.include "../../mk/bsd.prefs.mk"
|
||||
|
||||
CPPFLAGS+= -I${PGSQL_PREFIX}/include/postgresql/server
|
||||
|
||||
post-extract:
|
||||
@for FILE in Makefile dewey_cmp.c pkgconflict pkgdbextract \
|
||||
; do \
|
||||
${SED} -e 's|@PREFIX@|${PREFIX}|' ${FILESDIR}/$$FILE \
|
||||
>${WRKSRC}/$$FILE; \
|
||||
@for f in dewey_cmp.c pkgconflict pkgdbextract; do \
|
||||
${SED} -e 's|@PREFIX@|${PREFIX}|g' ${FILESDIR}/$$f >${WRKSRC}/$$f; \
|
||||
done
|
||||
|
||||
do-install:
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/dewey_cmp.so ${PREFIX}/lib
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/pkgconflict ${PREFIX}/bin
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/pkgdbextract ${PREFIX}/bin
|
||||
do-build:
|
||||
cd ${WRKSRC} && ${COMPILE.c} -fPIC dewey_cmp.c
|
||||
cd ${WRKSRC} && ${LINK.c} -shared -o dewey_cmp.so dewey_cmp.o
|
||||
|
||||
do-install:
|
||||
${INSTALL_LIB} ${WRKSRC}/dewey_cmp.so ${PREFIX}/lib/postgresql/
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/pkgconflict ${PREFIX}/bin/
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/pkgdbextract ${PREFIX}/bin/
|
||||
|
||||
.include "../../mk/pgsql.buildlink3.mk"
|
||||
.include "../../mk/bsd.pkg.mk"
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
@comment $NetBSD: PLIST,v 1.1 2001/10/31 21:31:37 zuntum Exp $
|
||||
lib/dewey_cmp.so
|
||||
@comment $NetBSD: PLIST,v 1.2 2005/01/05 21:15:15 tv Exp $
|
||||
lib/postgresql/dewey_cmp.so
|
||||
bin/pkgconflict
|
||||
bin/pkgdbextract
|
||||
|
|
|
@ -1,11 +0,0 @@
|
|||
# $NetBSD: Makefile,v 1.3 2004/06/27 13:40:20 grant Exp $
|
||||
|
||||
PGINCLUDE=@PREFIX@/include/pgsql
|
||||
|
||||
.c.o:
|
||||
cc -I${PGINCLUDE} -I${PGINCLUDE}/server -fpic -c $<
|
||||
|
||||
all: dewey_cmp.so
|
||||
|
||||
dewey_cmp.so: dewey_cmp.o
|
||||
cc -shared -o dewey_cmp.so dewey_cmp.o
|
|
@ -1,5 +1,5 @@
|
|||
#!/bin/csh -f
|
||||
# $NetBSD: pkgconflict,v 1.2 2001/04/10 14:16:08 wennmach Exp $
|
||||
# $NetBSD: pkgconflict,v 1.3 2005/01/05 21:15:15 tv Exp $
|
||||
#
|
||||
# pkgconflict: A script to find conflicting packages in pkgsrc
|
||||
# Author: Lex Wennmacher <wennmach@netbsd.org>
|
||||
|
@ -33,8 +33,8 @@ if ($status != 0) then
|
|||
exit -1
|
||||
endif
|
||||
|
||||
if (! -x $PREFIX/lib/dewey_cmp.so) then
|
||||
echo pkgconflict: error: no executable $PREFIX/lib/dewey_cmp.so
|
||||
if (! -x $PREFIX/lib/postgresql/dewey_cmp.so) then
|
||||
echo pkgconflict: error: no executable $PREFIX/lib/postgresql/dewey_cmp.so
|
||||
exit -1
|
||||
endif
|
||||
|
||||
|
@ -97,7 +97,7 @@ psql $DATABASE << --EOI--
|
|||
create function
|
||||
pkg_cmp(text, text)
|
||||
returns bool
|
||||
as '$PREFIX/lib/dewey_cmp.so'
|
||||
as '$PREFIX/lib/postgresql/dewey_cmp.so'
|
||||
language 'C';
|
||||
create operator ~~~ (
|
||||
leftarg = text,
|
||||
|
|
Loading…
Reference in a new issue