mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-16 07:58:04 +00:00
. javavmwrapper uses PATH to make sure it gets the system version of
utilities. Unfortunately this overrides any PATH that may have been set by the user and hence affects the ability of java to execute external programmes. So, save the PATH before setting it and then restore it immediately before executing java. . Bump PORTREVISION for this fix. Reported by: Christian Laursen <xi@borderworlds.dk>
This commit is contained in:
parent
119c49b59d
commit
59fc5151e6
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=121460
@ -9,6 +9,7 @@
|
||||
|
||||
PORTNAME= javavmwrapper
|
||||
PORTVERSION= 2.0
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= java
|
||||
MASTER_SITES= # none
|
||||
DISTFILES= # none
|
||||
|
@ -29,6 +29,7 @@
|
||||
#
|
||||
# MAINTAINER=java@FreeBSD.org
|
||||
|
||||
SAVE_PATH=${PATH}
|
||||
export PATH=/bin:/sbin:/usr/bin:/usr/sbin
|
||||
|
||||
PREFIX="%%PREFIX%%"
|
||||
@ -42,6 +43,9 @@ MAKE=/usr/bin/make
|
||||
tryJavaCommand () {
|
||||
# Check for the command being executable and exec it if so.
|
||||
if [ -x "${1}" ]; then
|
||||
if [ ! -z "${SAVE_PATH}" ]; then
|
||||
export PATH=${SAVE_PATH}
|
||||
fi
|
||||
exec "${@}"
|
||||
fi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user