diff --git a/usr.sbin/pkg_install/add/perform.c b/usr.sbin/pkg_install/add/perform.c index a351a03d171f..baae120d7069 100644 --- a/usr.sbin/pkg_install/add/perform.c +++ b/usr.sbin/pkg_install/add/perform.c @@ -1,11 +1,11 @@ -/* $NetBSD: perform.c,v 1.87 2003/09/08 07:00:10 jlam Exp $ */ +/* $NetBSD: perform.c,v 1.88 2003/09/23 06:19:46 grant Exp $ */ #include #ifndef lint #if 0 static const char *rcsid = "from FreeBSD Id: perform.c,v 1.44 1997/10/13 15:03:46 jkh Exp"; #else -__RCSID("$NetBSD: perform.c,v 1.87 2003/09/08 07:00:10 jlam Exp $"); +__RCSID("$NetBSD: perform.c,v 1.88 2003/09/23 06:19:46 grant Exp $"); #endif #endif @@ -640,7 +640,7 @@ ignore_replace_depends_check: if (Verbose) printf("mtree -U -f %s -d -e -p %s\n", MTREE_FNAME, p ? p->name : "/"); if (!Fake) { - if (vsystem("%s/mtree -U -f %s -d -e -p %s", BINDIR, MTREE_FNAME, p ? p->name : "/")) + if (vsystem("%s -U -f %s -d -e -p %s", MTREE_CMD, MTREE_FNAME, p ? p->name : "/")) warnx("mtree returned a non-zero status - continuing"); } unlink(MTREE_FNAME); /* remove this line to tar up pkg later - HF */ diff --git a/usr.sbin/pkg_install/lib/lib.h b/usr.sbin/pkg_install/lib/lib.h index 24bc96e17ea5..1e28954053e0 100644 --- a/usr.sbin/pkg_install/lib/lib.h +++ b/usr.sbin/pkg_install/lib/lib.h @@ -1,4 +1,4 @@ -/* $NetBSD: lib.h,v 1.57 2003/09/17 13:27:42 agc Exp $ */ +/* $NetBSD: lib.h,v 1.58 2003/09/23 06:19:45 grant Exp $ */ /* from FreeBSD Id: lib.h,v 1.25 1997/10/08 07:48:03 charnier Exp */ @@ -89,6 +89,14 @@ #define CHGRP_CMD "chgrp" #endif +#ifndef MTREE_CMD +# ifdef BINDIR +# define MTREE_CMD BINDIR "/mtree" +# else +# define MTREE_CMD "mtree" +# endif +#endif + /* The names of our "special" files */ #define CONTENTS_FNAME "+CONTENTS" #define COMMENT_FNAME "+COMMENT"