Add /usr/X11R6/bin to the exported PATH. If /usr/local/bin is there,

/usr/X11R6/bin should be there.  This helps all the ports that need to
run `mkfontdir' and error out as many port maintainers do not realize
`mkfontdir' isn't in the path.

Prompted by:	pkg_add pcemu
This commit is contained in:
David E. O'Brien 2001-04-25 19:11:09 +00:00
parent 145643dbc8
commit f9722b4b48
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=75981

View File

@ -163,7 +163,8 @@ main(int argc, char **argv)
usage();
}
/* Make sure the sub-execs we invoke get found */
setenv("PATH", "/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/bin", 1);
setenv("PATH", "/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin"
1);
/* Set a reasonable umask */
umask(022);
@ -189,12 +190,17 @@ getpackagesite(void)
return sitepath;
}
if (getenv("PACKAGEROOT"))
strcpy(sitepath, getenv("PACKAGEROOT"));
if (getenv("PACKAGEMIRROR"))
strcpy(sitepath, getenv("PACKAGEMIRROR"));
else
strcpy(sitepath, "ftp://ftp.FreeBSD.org");
strcat(sitepath, "/pub/FreeBSD/ports/");
if (getenv("PACKAGEROOT"))
strcpy(sitepath, getenv("PACKAGEMIRRORROOT"));
else
strcat(sitepath, "/pub");
strcat(sitepath, "/FreeBSD/ports/");
uname(&u);
strcat(sitepath, u.machine);