2004-02-11 12:41:43 +01:00
|
|
|
# $NetBSD: Makefile,v 1.95 2004/02/11 11:41:43 grant Exp $
|
1998-08-28 14:25:35 +02:00
|
|
|
|
2002-12-20 19:15:52 +01:00
|
|
|
# Notes to package maintainers:
|
2002-12-12 02:50:47 +01:00
|
|
|
#
|
2002-12-20 19:15:52 +01:00
|
|
|
# To update this package, import from src/usr.sbin/pkg_install.
|
2002-12-12 02:50:47 +01:00
|
|
|
#
|
2002-12-20 19:15:52 +01:00
|
|
|
# Updating this package does not automatically necessitate bumping
|
|
|
|
# PKGTOOLS_REQD in bsd.pkg.mk. Do so if and only if there is a critical
|
|
|
|
# change in the pkg_* tools that pkgsrc relies on for proper operation.
|
2002-12-12 02:50:47 +01:00
|
|
|
|
2002-12-20 19:15:52 +01:00
|
|
|
DISTNAME= pkg_install-${VERSION}
|
1998-08-28 14:25:35 +02:00
|
|
|
CATEGORIES= pkgtools
|
2002-12-20 19:15:52 +01:00
|
|
|
MASTER_SITES= # empty
|
|
|
|
DISTFILES= # empty
|
1998-08-28 14:25:35 +02:00
|
|
|
|
2003-07-18 00:50:55 +02:00
|
|
|
MAINTAINER= tech-pkg@NetBSD.org
|
2003-09-11 09:14:42 +02:00
|
|
|
HOMEPAGE= http://www.pkgsrc.org/
|
2003-12-22 01:23:35 +01:00
|
|
|
COMMENT= Package management and administration tools for pkgsrc
|
1998-08-28 14:25:35 +02:00
|
|
|
|
2002-12-20 19:15:52 +01:00
|
|
|
GNU_CONFIGURE= # defined
|
|
|
|
CONFIGURE_ARGS+= --with-pkgdbdir=${PKG_DBDIR}
|
2003-09-23 09:44:48 +02:00
|
|
|
CONFIGURE_ARGS+= --with-ftp=${FETCH_CMD}
|
|
|
|
CONFIGURE_ARGS+= --with-mtree=${MTREE}
|
|
|
|
CONFIGURE_ARGS+= --with-pax=${PAX}
|
|
|
|
CONFIGURE_ARGS+= --with-tar=${TAR}
|
2002-12-20 19:15:52 +01:00
|
|
|
|
2003-01-09 14:13:04 +01:00
|
|
|
NO_PKGTOOLS_REQD_CHECK= # defined
|
2003-09-13 06:08:12 +02:00
|
|
|
NO_BUILDLINK= # defined
|
2002-12-20 19:15:52 +01:00
|
|
|
NO_CHECKSUM= # defined
|
|
|
|
NO_MTREE= # defined
|
|
|
|
NO_PKG_REGISTER= # defined
|
|
|
|
NO_PACKAGE= Deinstallation is not permitted
|
2003-09-25 14:43:36 +02:00
|
|
|
NO_TOOLS= # defined
|
2003-01-10 13:01:43 +01:00
|
|
|
PKG_PRESERVE= # defined
|
1998-08-28 14:25:35 +02:00
|
|
|
|
2003-10-11 09:29:29 +02:00
|
|
|
PLIST_SUBST+= MANDIR=${MANDIR}
|
|
|
|
PLIST_SUBST+= PKG_TOOLS_BIN=${PKG_TOOLS_BIN}
|
|
|
|
|
2003-09-13 06:08:12 +02:00
|
|
|
LIBNBCOMPAT_FILESDIR= ${.CURDIR}/../../pkgtools/libnbcompat/files
|
|
|
|
LIBNBCOMPAT_SRCDIR= ${WRKDIR}/libnbcompat
|
|
|
|
|
|
|
|
CFLAGS+= -I${LIBNBCOMPAT_SRCDIR}
|
|
|
|
LDFLAGS+= -L${LIBNBCOMPAT_SRCDIR}
|
|
|
|
LIBS+= -lnbcompat
|
|
|
|
|
2004-02-11 12:41:43 +01:00
|
|
|
MAKE_ENV+= MACHINE_ARCH="${MACHINE_ARCH}"
|
|
|
|
MAKE_ENV+= OPSYS="${OPSYS}"
|
2004-01-15 02:40:13 +01:00
|
|
|
|
2001-02-25 04:42:16 +01:00
|
|
|
PKG_DBDIR?= /var/db/pkg
|
2003-09-01 18:27:07 +02:00
|
|
|
PKG_INFO= PKG_DBDIR=${PKG_DBDIR} ${PKG_INFO_CMD}
|
2004-02-09 23:04:12 +01:00
|
|
|
PKG_ADMIN= PKG_DBDIR=${PKG_DBDIR} ${PKG_ADMIN_CMD}
|
1998-08-28 14:25:35 +02:00
|
|
|
|
2004-02-09 05:52:10 +01:00
|
|
|
.include "../../mk/bsd.prefs.mk"
|
|
|
|
|
|
|
|
VERSION!= ${AWK} -F '"' '/PKGTOOLS_VERSION/ {print $$2}' \
|
|
|
|
${FILESDIR}/lib/version.h
|
|
|
|
|
2002-12-20 19:15:52 +01:00
|
|
|
do-extract:
|
2003-09-13 06:08:12 +02:00
|
|
|
@${CP} -Rp ${LIBNBCOMPAT_FILESDIR} ${LIBNBCOMPAT_SRCDIR}
|
2002-12-20 19:15:52 +01:00
|
|
|
@${CP} -Rp ${FILESDIR} ${WRKSRC}
|
2001-10-30 15:12:37 +01:00
|
|
|
|
2003-09-13 06:08:12 +02:00
|
|
|
pre-configure:
|
2003-09-19 01:42:24 +02:00
|
|
|
cd ${LIBNBCOMPAT_SRCDIR} && ${SETENV} CC="${CC}" ./configure && \
|
|
|
|
${MAKE_PROGRAM}
|
2003-09-13 06:08:12 +02:00
|
|
|
|
1999-03-13 04:47:49 +01:00
|
|
|
post-install:
|
2003-08-31 13:06:02 +02:00
|
|
|
if [ ! -f ${PKG_DBDIR}/pkgdb.byfile.db ]; then \
|
|
|
|
if [ ! -d ${PKG_DBDIR} ]; then \
|
|
|
|
${INSTALL_DATA_DIR} ${PKG_DBDIR}; \
|
|
|
|
fi; \
|
2003-08-31 13:55:09 +02:00
|
|
|
${PKG_ADMIN} rebuild; \
|
1999-03-30 14:52:36 +02:00
|
|
|
fi
|
1999-03-13 04:47:49 +01:00
|
|
|
|
1998-08-28 14:25:35 +02:00
|
|
|
.include "../../mk/bsd.pkg.mk"
|
2003-01-09 14:13:04 +01:00
|
|
|
|
2003-01-11 12:59:35 +01:00
|
|
|
PREFIX:= ${PKG_TOOLS_BIN:C|/[^/]?bin$||}
|
2003-01-11 08:54:28 +01:00
|
|
|
.if ${PREFIX} == "/usr"
|
2003-01-11 08:52:15 +01:00
|
|
|
CONFIGURE_ARGS+= --mandir=${PREFIX}/share/man
|
2003-10-11 09:29:29 +02:00
|
|
|
MANDIR= share/
|
2003-01-11 08:52:15 +01:00
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --mandir=${PREFIX}/man
|
2003-10-11 09:29:29 +02:00
|
|
|
MANDIR= # empty
|
2003-01-11 08:54:28 +01:00
|
|
|
.endif
|