summaryrefslogtreecommitdiff
path: root/pkgtools
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2007-09-08 21:57:57 +0000
committerjlam <jlam@pkgsrc.org>2007-09-08 21:57:57 +0000
commit2761568ac280270d3e97f7e38922103a7a4ff840 (patch)
tree090b4461321e87c968b099c0a26b69c4da29ff20 /pkgtools
parent48bbc6ce1f67bf684a69a2ea4678cd6f17f128e9 (diff)
downloadpkgsrc-2761568ac280270d3e97f7e38922103a7a4ff840.tar.gz
Convert to use the features framework.
Diffstat (limited to 'pkgtools')
-rw-r--r--pkgtools/libnbcompat/inplace.mk15
-rw-r--r--pkgtools/pax/Makefile5
-rw-r--r--pkgtools/pbulk/Makefile4
-rw-r--r--pkgtools/pkg_filecheck/Makefile12
-rw-r--r--pkgtools/pkg_filecheck/files/pkg_filecheck.c8
-rw-r--r--pkgtools/pkg_install/Makefile5
-rw-r--r--pkgtools/pkgfind/Makefile16
-rw-r--r--pkgtools/pkgfind/files/pkgfind.c2
-rw-r--r--pkgtools/rcorder/Makefile4
9 files changed, 27 insertions, 44 deletions
diff --git a/pkgtools/libnbcompat/inplace.mk b/pkgtools/libnbcompat/inplace.mk
index 7d2e9a5e694..c84e824d042 100644
--- a/pkgtools/libnbcompat/inplace.mk
+++ b/pkgtools/libnbcompat/inplace.mk
@@ -1,20 +1,19 @@
-# $NetBSD: inplace.mk,v 1.4 2007/08/02 07:22:31 tron Exp $
+# $NetBSD: inplace.mk,v 1.5 2007/09/08 21:57:59 jlam Exp $
#
# This Makefile fragment builds a working copy of libnbcompat inside
-# ${WRKDIR} and adds the appropriate paths to CPPFLAGS and LDFLAGS.
-# This can be used in place of libnbcompat/buildlink3.mk where it is
-# included by a bootstrap package Makefile.
+# ${WRKDIR}.
+#
.include "../../mk/bsd.prefs.mk"
LIBNBCOMPAT_FILESDIR= ${.CURDIR}/../../pkgtools/libnbcompat/files
LIBNBCOMPAT_SRCDIR= ${WRKDIR}/libnbcompat
-CPPFLAGS+= -I${LIBNBCOMPAT_SRCDIR}
-LDFLAGS+= -L${LIBNBCOMPAT_SRCDIR}
-LIBS+= -lnbcompat
+CPPFLAGS.nbcompat= -DHAVE_NBCOMPAT_H=1 -I${LIBNBCOMPAT_SRCDIR}
+LDFLAGS.nbcompat= -L${LIBNBCOMPAT_SRCDIR}
+LDADD.nbcompat= -lnbcompat
-do-extract: libnbcompat-extract
+post-extract: libnbcompat-extract
libnbcompat-extract:
${_PKG_SILENT}${_PKG_DEBUG} \
${CP} -R ${LIBNBCOMPAT_FILESDIR} ${LIBNBCOMPAT_SRCDIR}
diff --git a/pkgtools/pax/Makefile b/pkgtools/pax/Makefile
index 6dd1c401347..9562801bee8 100644
--- a/pkgtools/pax/Makefile
+++ b/pkgtools/pax/Makefile
@@ -1,8 +1,10 @@
-# $NetBSD: Makefile,v 1.15 2007/07/10 15:19:18 joerg Exp $
+# $NetBSD: Makefile,v 1.16 2007/09/08 21:57:59 jlam Exp $
#
# This version of pax installs into ${PKG_TOOLS_BIN}.
#
+USE_FEATURES= nbcompat
+
.include "../../archivers/pax/Makefile.common"
PKGREVISION= 1
@@ -10,5 +12,4 @@ CATEGORIES= pkgtools
NO_PKGTOOLS_REQD_CHECK= yes
-.include "../../pkgtools/libnbcompat/inplace.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/pkgtools/pbulk/Makefile b/pkgtools/pbulk/Makefile
index 1794014eac3..884b4a0eb86 100644
--- a/pkgtools/pbulk/Makefile
+++ b/pkgtools/pbulk/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.18 2007/08/16 13:02:05 joerg Exp $
+# $NetBSD: Makefile,v 1.19 2007/09/08 21:57:59 jlam Exp $
DISTNAME= pbulk-0.13
CATEGORIES= pkgtools
@@ -15,6 +15,7 @@ WRKSRC= ${WRKDIR}/pbulk
EXTRACT_ONLY= # empty
NO_CHECKSUM= YES
+USE_FEATURES= nbcompat
USE_TOOLS+= awk:run bzip2:run digest:run gzip:run ident:run make:run \
mail:run tar:run
DEPENDS+= rsync-[0-9]*:../../net/rsync
@@ -65,5 +66,4 @@ CPPFLAGS+= -D_GNU_SOURCE
.endif
.include "../../devel/libevent/buildlink3.mk"
-.include "../../pkgtools/libnbcompat/inplace.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/pkgtools/pkg_filecheck/Makefile b/pkgtools/pkg_filecheck/Makefile
index 87a61cf8551..4968c5b22db 100644
--- a/pkgtools/pkg_filecheck/Makefile
+++ b/pkgtools/pkg_filecheck/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.26 2007/09/06 21:51:54 jlam Exp $
+# $NetBSD: Makefile,v 1.27 2007/09/08 21:57:59 jlam Exp $
#
DISTNAME= pkg_filecheck-0.4
@@ -12,6 +12,7 @@ COMMENT= Check for files not owned by any package
WRKSRC= ${WRKDIR}
USE_TOOLS+= perl:run
+USE_FEATURES= fts_open
EXTRACT_ONLY= # empty
NO_CHECKSUM= yes
@@ -24,8 +25,6 @@ CONF_FILES= ${PREFIX}/share/examples/pkg_filecheck/pkg_filecheck.conf \
INSTALLATION_DIRS= bin ${PKGMANDIR}/man1 ${PKGMANDIR}/man5
-.include "../../mk/bdb.buildlink3.mk"
-
SUBST_CLASSES+= paths
SUBST_FILES.paths= builddb.pl builddb.1 pkg_filecheck.conf
SUBST_FILES.paths+= pkg_filecheck.conf.5 pkg_filecheck.c pkg_filecheck.1
@@ -57,11 +56,6 @@ do-install:
${INSTALL_DATA} ${WRKSRC}/pkg_filecheck.conf \
${PREFIX}/share/examples/pkg_filecheck/pkg_filecheck.conf
-.include "../../mk/bsd.prefs.mk"
-
-.if ${OPSYS} != "NetBSD"
-CPPFLAGS+= -DUSE_LIBNBCOMPAT
-. include "../../pkgtools/libnbcompat/inplace.mk"
-.endif
+.include "../../mk/bdb.buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/pkgtools/pkg_filecheck/files/pkg_filecheck.c b/pkgtools/pkg_filecheck/files/pkg_filecheck.c
index 6932e45008a..149dc4f053b 100644
--- a/pkgtools/pkg_filecheck/files/pkg_filecheck.c
+++ b/pkgtools/pkg_filecheck/files/pkg_filecheck.c
@@ -1,5 +1,5 @@
/*
- $NetBSD: pkg_filecheck.c,v 1.5 2007/02/16 22:57:09 tonio Exp $
+ $NetBSD: pkg_filecheck.c,v 1.6 2007/09/08 21:57:59 jlam Exp $
pkg_filecheck.c -- check for files not owned by any package
Copyright (C) 2001 Dieter Baron
@@ -30,18 +30,12 @@
IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#if defined(USE_LIBNBCOMPAT)
-#include <nbcompat.h>
-#endif
-
#include <sys/types.h>
#include <sys/stat.h>
#include <db_185.h>
#include <errno.h>
#include <fcntl.h>
-#if !defined(USE_LIBNBCOMPAT) || defined(HAVE_FTS_H)
#include <fts.h>
-#endif
#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/pkgtools/pkg_install/Makefile b/pkgtools/pkg_install/Makefile
index 1d269a57c57..8b440525347 100644
--- a/pkgtools/pkg_install/Makefile
+++ b/pkgtools/pkg_install/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.141 2007/08/29 15:42:39 jlam Exp $
+# $NetBSD: Makefile,v 1.142 2007/09/08 21:57:59 jlam Exp $
# Notes to package maintainers:
#
@@ -31,6 +31,8 @@ USE_TOOLS+= pax:run tar:run gzcat:run
USE_TOOLS+= chmod cmp cp env find grep ln mkdir rm rmdir \
sed sort touch
+USE_FEATURES= nbcompat
+
SKIP_AUDIT_PACKAGES= yes
NO_PKGTOOLS_REQD_CHECK= yes
NO_CHECKSUM= yes
@@ -148,5 +150,4 @@ update:
${MAKE} ${UPDATE_TARGET}
${MAKE} clean
-.include "../../pkgtools/libnbcompat/inplace.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/pkgtools/pkgfind/Makefile b/pkgtools/pkgfind/Makefile
index 125d6b8efaf..654205e41d8 100644
--- a/pkgtools/pkgfind/Makefile
+++ b/pkgtools/pkgfind/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.18 2007/09/06 21:51:54 jlam Exp $
+# $NetBSD: Makefile,v 1.19 2007/09/08 21:57:59 jlam Exp $
DISTNAME= pkgfind-20050804
CATEGORIES= pkgtools
@@ -13,13 +13,16 @@ PKG_INSTALLATION_TYPES= overwrite pkgviews
NO_CONFIGURE= yes
NO_CHECKSUM= yes
+USE_FEATURES= err getprogname setprogname snprintf warn
+
INSTALLATION_DIRS= bin ${PKGMANDIR}/man1
do-extract:
@${CP} -R ${FILESDIR} ${WRKSRC}
do-build:
- ${LINK.c} -o ${WRKSRC}/pkgfind ${WRKSRC}/pkgfind.c
+ ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} -o ${WRKSRC}/pkgfind \
+ ${WRKSRC}/pkgfind.c ${LIBS}
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/pkgfind ${PREFIX}/bin/pkgfind
@@ -31,13 +34,4 @@ SUBST_FILES.path= pkgfind.c pkgfind.1
SUBST_SED.path= -e "s,/usr/pkgsrc,${PKGSRCDIR},g"
SUBST_MESSAGE.path= Adjusting pkgsrc directory.
-.include "../../mk/bsd.prefs.mk"
-
-# need err(1), warn(1), set/getprogname(1)
-.if ${OPSYS} != "NetBSD" && ${OPSYS} != "FreeBSD" && ${OPSYS} != "DragonFly"
-CFLAGS+= -DNEED_LIBNBCOMPAT
-LDFLAGS+= -lnbcompat
-. include "../../pkgtools/libnbcompat/inplace.mk"
-.endif
-
.include "../../mk/bsd.pkg.mk"
diff --git a/pkgtools/pkgfind/files/pkgfind.c b/pkgtools/pkgfind/files/pkgfind.c
index 0704594f39c..8fa0e92c43e 100644
--- a/pkgtools/pkgfind/files/pkgfind.c
+++ b/pkgtools/pkgfind/files/pkgfind.c
@@ -38,7 +38,7 @@
#include <sys/param.h>
#include <sys/stat.h>
-#ifdef NEED_LIBNBCOMPAT
+#if HAVE_NBCOMPAT_H
#include <nbcompat.h>
#else
#include <err.h>
diff --git a/pkgtools/rcorder/Makefile b/pkgtools/rcorder/Makefile
index 0203a8c6524..2d698de36d3 100644
--- a/pkgtools/rcorder/Makefile
+++ b/pkgtools/rcorder/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.10 2007/09/06 21:29:26 jlam Exp $
+# $NetBSD: Makefile,v 1.11 2007/09/08 21:58:00 jlam Exp $
#
DISTNAME= rcorder-20031013
@@ -12,9 +12,9 @@ COMMENT= Print a dependency ordering of interdependent files
NO_CHECKSUM= yes
GNU_CONFIGURE= yes
+USE_FEATURES= nbcompat
do-extract:
${CP} -R ${FILESDIR} ${WRKSRC}
-.include "../../pkgtools/libnbcompat/inplace.mk"
.include "../../mk/bsd.pkg.mk"