mirror of
https://git.freebsd.org/ports.git
synced 2025-05-17 01:23:12 -04:00
99 lines
4.9 KiB
Text
99 lines
4.9 KiB
Text
--- platform/lib/nbexec.orig 2011-05-25 09:06:02.000000000 +0200
|
|
+++ platform/lib/nbexec 2011-05-25 09:11:16.000000000 +0200
|
|
@@ -182,7 +182,7 @@
|
|
# if heap dump on OOME is supported enable it
|
|
if "${jdkhome}/bin/java" -XX:+HeapDumpOnOutOfMemoryError > /dev/null 2>&1 ; then
|
|
jargs="$jargs -XX:+HeapDumpOnOutOfMemoryError"
|
|
- if echo $jargs | grep -v -- "-XX:HeapDumpPath=" > /dev/null ; then
|
|
+ if echo $jargs | %%GREP%% -v -- "-XX:HeapDumpPath=" > /dev/null ; then
|
|
jargs="$jargs -XX:HeapDumpPath=\"${userdir}/var/log/heapdump.hprof\""
|
|
fi
|
|
fi
|
|
@@ -201,7 +201,7 @@
|
|
if [ "`echo "${dir}"/*.$ex`" != "${dir}/*.$ex" ] ; then
|
|
for x in "${dir}"/*.$ex ; do
|
|
subx=`basename "$x"`
|
|
- if echo "$paths" | fgrep -v "$subpath$subx" > /dev/null ; then
|
|
+ if echo "$paths" | %%GREP%% -v "$subpath$subx" > /dev/null ; then
|
|
if [ ! -z "$cp" ] ; then cp="$cp:" ; fi
|
|
cp="$cp$x"
|
|
if [ ! -z "$paths" ] ; then paths="$paths:" ; fi
|
|
@@ -345,7 +345,7 @@
|
|
}
|
|
|
|
detect_gnome_proxy () {
|
|
- gconftool=/usr/bin/gconftool-2
|
|
+ gconftool=%%GCONFTOOL2%%
|
|
if [ -x $gconftool ] ; then
|
|
proxy_mode=`$gconftool --get /system/proxy/mode 2>/dev/null`
|
|
if [ "$proxy_mode" = "manual" ] ; then
|
|
@@ -354,7 +354,7 @@
|
|
http_proxy_tmp=$http_proxy_host:$http_proxy_port
|
|
http_non_proxy_hosts=`$gconftool --get /system/http_proxy/ignore_hosts 2>/dev/null`
|
|
if [ $? ] ; then
|
|
- http_non_proxy_hosts=`echo $http_non_proxy_hosts | /bin/sed 's/\]//'`
|
|
+ http_non_proxy_hosts=`echo $http_non_proxy_hosts | %%SED%% 's/\]//'`
|
|
fi
|
|
socks_proxy_host=`$gconftool --get /system/proxy/socks_host 2>/dev/null`
|
|
socks_proxy_port=`$gconftool --get /system/proxy/socks_port 2>/dev/null`
|
|
@@ -386,26 +386,26 @@
|
|
detect_kde_proxy () {
|
|
kioslaverc="${HOME}/.kde/share/config/kioslaverc"
|
|
if [ -f $kioslaverc ] ; then
|
|
- if /bin/grep 'ProxyType=1' "$kioslaverc" >/dev/null 2>&1; then
|
|
- http_proxy_tmp=`/bin/grep 'httpProxy=http://' "$kioslaverc"`
|
|
+ if %%GREP%% 'ProxyType=1' "$kioslaverc" >/dev/null 2>&1; then
|
|
+ http_proxy_tmp=`%%GREP%% 'httpProxy=http://' "$kioslaverc"`
|
|
if [ $? ] ; then
|
|
- http_proxy_tmp=`echo $http_proxy_tmp | /bin/sed 's/httpProxy=http:\/\///'`
|
|
+ http_proxy_tmp=`echo $http_proxy_tmp | %%SED%% 's/httpProxy=http:\/\///'`
|
|
return 0
|
|
fi
|
|
- http_non_proxy_hosts=`/bin/grep 'NoProxyFor=' "$kioslaverc"`
|
|
+ http_non_proxy_hosts=`%%GREP%% 'NoProxyFor=' "$kioslaverc"`
|
|
if [ $? ] ; then
|
|
- http_non_proxy_hosts=`echo $http_non_proxy_hosts | /bin/sed 's/NoProxyFor=//'`
|
|
+ http_non_proxy_hosts=`echo $http_non_proxy_hosts | %%SED%% 's/NoProxyFor=//'`
|
|
fi
|
|
else
|
|
- if /bin/grep 'ProxyType=0' "$kioslaverc" >/dev/null 2>&1; then
|
|
+ if %%GREP%% 'ProxyType=0' "$kioslaverc" >/dev/null 2>&1; then
|
|
detect_system_proxy
|
|
if [ -z "$http_proxy_tmp" ]; then
|
|
http_proxy_tmp="DIRECT"
|
|
fi
|
|
return 0
|
|
else
|
|
- if /bin/grep 'ProxyType=2' "$kioslaverc" >/dev/null 2>&1; then
|
|
- pac_file=`grep "Proxy Config Script=" $kioslaverc | cut -f 2 -d =`
|
|
+ if %%GREP%% 'ProxyType=2' "$kioslaverc" >/dev/null 2>&1; then
|
|
+ pac_file=`%%GREP%% "Proxy Config Script=" $kioslaverc | cut -f 2 -d =`
|
|
http_proxy_tmp="PAC "$pac_file
|
|
return 0
|
|
fi
|
|
@@ -427,9 +427,9 @@
|
|
close
|
|
EOF
|
|
|
|
- if /usr/bin/grep "ProxyAuto.*: *1" ${scutil_out} >/dev/null 2>&1; then
|
|
- if /usr/bin/grep "ProxyAutoConfigEnable.*: *1" ${scutil_out} >/dev/null 2>&1; then
|
|
- http_proxy_tmp="PAC `/usr/bin/grep ProxyAutoConfigURLString ${scutil_out} | /usr/bin/awk '{print $3}'`"
|
|
+ if %%GREP%% "ProxyAuto.*: *1" ${scutil_out} >/dev/null 2>&1; then
|
|
+ if %%GREP%% "ProxyAutoConfigEnable.*: *1" ${scutil_out} >/dev/null 2>&1; then
|
|
+ http_proxy_tmp="PAC `%%GREP%% ProxyAutoConfigURLString ${scutil_out} | /usr/bin/awk '{print $3}'`"
|
|
rm ${scutil_out}
|
|
return 0
|
|
fi
|
|
@@ -438,9 +438,9 @@
|
|
return 1
|
|
fi
|
|
|
|
- if /usr/bin/grep "HTTPEnable *: *1" ${scutil_out} >/dev/null 2>&1; then
|
|
- http_proxy_host=`/usr/bin/grep HTTPProxy ${scutil_out} | /usr/bin/awk '{print $3}'`
|
|
- http_proxy_port=`/usr/bin/grep HTTPPort ${scutil_out} | /usr/bin/awk '{print $3} '`
|
|
+ if %%GREP%% "HTTPEnable *: *1" ${scutil_out} >/dev/null 2>&1; then
|
|
+ http_proxy_host=`%%GREP%% HTTPProxy ${scutil_out} | /usr/bin/awk '{print $3}'`
|
|
+ http_proxy_port=`%%GREP%% HTTPPort ${scutil_out} | /usr/bin/awk '{print $3} '`
|
|
http_proxy_tmp=$http_proxy_host:$http_proxy_port
|
|
rm ${scutil_out}
|
|
return 0
|