mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-07 13:09:53 +01:00
Tools: Fix handling program parameters in runwait.sh. Issue #40045, patch by Dean Mustakinov.
This commit is contained in:
parent
edbe283fc6
commit
5ea4a1e270
@ -1,10 +1,12 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
CommandLine="$@"
|
CommandLine="$@"
|
||||||
|
ExeName="$1"
|
||||||
#set -x
|
#set -x
|
||||||
|
|
||||||
echo $CommandLine
|
echo $CommandLine
|
||||||
ext=${CommandLine#*.}
|
ext=${ExeName#*.}
|
||||||
|
echo "ext=$ext"
|
||||||
if [ "$ext" = "exe" ]; then
|
if [ "$ext" = "exe" ]; then
|
||||||
echo "Windows Executable detected. Attempting to use WINE..."
|
echo "Windows Executable detected. Attempting to use WINE..."
|
||||||
if [ -x "`which wine`" ]; then
|
if [ -x "`which wine`" ]; then
|
||||||
@ -13,7 +15,8 @@ if [ "$ext" = "exe" ]; then
|
|||||||
echo "WINE not found in path"
|
echo "WINE not found in path"
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
"$CommandLine"
|
shift
|
||||||
|
"$ExeName" $@
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "--------------------------------------------------"
|
echo "--------------------------------------------------"
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user