aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.sbin/pkg_install/add/extract.c12
-rw-r--r--usr.sbin/pkg_install/add/perform.c4
2 files changed, 10 insertions, 6 deletions
diff --git a/usr.sbin/pkg_install/add/extract.c b/usr.sbin/pkg_install/add/extract.c
index c9978cdef0f8..d5db041e6a06 100644
--- a/usr.sbin/pkg_install/add/extract.c
+++ b/usr.sbin/pkg_install/add/extract.c
@@ -1,5 +1,5 @@
#ifndef lint
-static const char *rcsid = "$Id: extract.c,v 1.5 1993/09/04 05:06:26 jkh Exp $";
+static const char *rcsid = "$Id: extract.c,v 1.4 1993/09/06 23:26:21 jkh Exp $";
#endif
/*
@@ -40,6 +40,8 @@ extract_plist(char *home, Package *pkg)
/* Do it */
while (p) {
+ char cmd[FILENAME_MAX];
+
switch(p->type) {
case PLIST_NAME:
PkgName = p->name;
@@ -75,11 +77,11 @@ extract_plist(char *home, Package *pkg)
break;
case PLIST_CMD:
+ format_cmd(cmd, p->name, Directory, last_file);
if (Verbose)
- printf("extract: exec cmd '%s' (lastfile = %s)\n", p->name,
- last_file);
- if (!Fake && vsystem(p->name, Directory, last_file))
- whinge("Command '%s' failed.", p->name);
+ printf("extract: execute '%s'\n", cmd);
+ if (!Fake && system(cmd))
+ whinge("Command '%s' failed.", cmd);
break;
case PLIST_CHMOD:
diff --git a/usr.sbin/pkg_install/add/perform.c b/usr.sbin/pkg_install/add/perform.c
index d285c0e1f3e0..be7b5078eeae 100644
--- a/usr.sbin/pkg_install/add/perform.c
+++ b/usr.sbin/pkg_install/add/perform.c
@@ -1,5 +1,5 @@
#ifndef lint
-static const char *rcsid = "$Id: perform.c,v 1.8 1993/09/04 05:06:29 jkh Exp $";
+static const char *rcsid = "$Id: perform.c,v 1.3 1993/09/05 04:53:50 jkh Exp $";
#endif
/*
@@ -168,6 +168,8 @@ pkg_do(char *pkg)
code = 1;
goto success; /* close enough for government work */
}
+ /* Make sure pkg_info can read the entry */
+ vsystem("chmod a+rx %s", LogDir);
if (fexists(DEINSTALL_FNAME))
copy_file(".", DEINSTALL_FNAME, LogDir);
if (fexists(REQUIRE_FNAME))