diff options
author | jkh <jkh@FreeBSD.org> | 1997-06-06 12:19:11 +0000 |
---|---|---|
committer | jkh <jkh@FreeBSD.org> | 1997-06-06 12:19:11 +0000 |
commit | 950dcc5c24cddc6c6edeef1df3340a1305209e8b (patch) | |
tree | 0710027785ab35af569ecc606609c94d2858b56e /usr.sbin/pkg_install | |
parent | 041a050592a40a39317e2e28a6df2312d1af501b (diff) | |
download | FreeBSD-src-950dcc5c24cddc6c6edeef1df3340a1305209e8b.zip FreeBSD-src-950dcc5c24cddc6c6edeef1df3340a1305209e8b.tar.gz |
Add support for srcdir overrides.
Diffstat (limited to 'usr.sbin/pkg_install')
-rw-r--r-- | usr.sbin/pkg_install/create/create.h | 5 | ||||
-rw-r--r-- | usr.sbin/pkg_install/create/main.c | 11 | ||||
-rw-r--r-- | usr.sbin/pkg_install/create/perform.c | 10 |
3 files changed, 20 insertions, 6 deletions
diff --git a/usr.sbin/pkg_install/create/create.h b/usr.sbin/pkg_install/create/create.h index 6ef8888..b9348d9 100644 --- a/usr.sbin/pkg_install/create/create.h +++ b/usr.sbin/pkg_install/create/create.h @@ -1,4 +1,4 @@ -/* $Id$ */ +/* $Id: create.h,v 1.11 1997/02/22 16:09:24 peter Exp $ */ /* * FreeBSD install - a package for the installation and maintainance @@ -31,10 +31,11 @@ extern char *Install; extern char *DeInstall; extern char *Contents; extern char *Require; -extern char PlayPen[]; +extern char *SrcDir; extern char *ExcludeFrom; extern char *Mtree; extern char *Pkgdeps; +extern char PlayPen[]; extern int Dereference; extern int PlistOnly; diff --git a/usr.sbin/pkg_install/create/main.c b/usr.sbin/pkg_install/create/main.c index 0d8d3d1..d8cef07 100644 --- a/usr.sbin/pkg_install/create/main.c +++ b/usr.sbin/pkg_install/create/main.c @@ -1,5 +1,5 @@ #ifndef lint -static const char *rcsid = "$Id: main.c,v 1.14 1997/02/22 16:09:25 peter Exp $"; +static const char *rcsid = "$Id: main.c,v 1.15 1997/03/31 05:10:47 imp Exp $"; #endif /* @@ -16,20 +16,21 @@ static const char *rcsid = "$Id: main.c,v 1.14 1997/02/22 16:09:25 peter Exp $"; #include "lib.h" #include "create.h" -static char Options[] = "YNOhvf:p:P:c:d:i:k:r:t:X:D:m:"; +static char Options[] = "YNOhvf:p:P:c:d:i:k:r:t:X:D:m:s:"; char *Prefix = NULL; char *Comment = NULL; char *Desc = NULL; +char *SrcDir = NULL; char *Display = NULL; char *Install = NULL; char *DeInstall = NULL; char *Contents = NULL; char *Require = NULL; -char PlayPen[FILENAME_MAX]; char *ExcludeFrom = NULL; char *Mtree = NULL; char *Pkgdeps = NULL; +char PlayPen[FILENAME_MAX]; int Dereference = 0; int PlistOnly = 0; @@ -63,6 +64,10 @@ main(int argc, char **argv) Prefix = optarg; break; + case 's': + SrcDir = optarg; + break; + case 'f': Contents = optarg; break; diff --git a/usr.sbin/pkg_install/create/perform.c b/usr.sbin/pkg_install/create/perform.c index 83c4f35..428c0cd 100644 --- a/usr.sbin/pkg_install/create/perform.c +++ b/usr.sbin/pkg_install/create/perform.c @@ -1,5 +1,5 @@ #ifndef lint -static const char *rcsid = "$Id$"; +static const char *rcsid = "$Id: perform.c,v 1.34 1997/02/22 16:09:28 peter Exp $"; #endif /* @@ -83,6 +83,14 @@ pkg_perform(char **pkgs) if (Verbose && !PlistOnly) printf(".\n"); } + + /* If a SrcDir override is set, add it now */ + if (SrcDir) { + if (Verbose && !PlistOnly) + printf("Using SrcDir value of %s\n", SrcDir); + add_plist(&plist, PLIST_SRC, SrcDir); + } + /* Slurp in the packing list */ read_plist(&plist, pkg_in); |