mirror of
https://github.com/JustArchiNET/ArchiSteamFarm
synced 2024-11-15 01:17:37 +00:00
More debug
This commit is contained in:
parent
2a61ecb681
commit
c115158279
1 changed files with 9 additions and 0 deletions
|
@ -7,6 +7,7 @@ MONO_DEBUG_IF_AVAILABLE() {
|
|||
if [[ -z "$PREVIOUS_MONO_DEBUG" ]]; then
|
||||
export MONO_DEBUG="$1"
|
||||
elif echo "$PREVIOUS_MONO_DEBUG" | grep -Fq "$1"; then
|
||||
echo "Success: $1 already exists"
|
||||
return 0
|
||||
else
|
||||
export MONO_DEBUG="${PREVIOUS_MONO_DEBUG},${1}"
|
||||
|
@ -15,10 +16,12 @@ MONO_DEBUG_IF_AVAILABLE() {
|
|||
# If we did a change, check if Mono supports that option
|
||||
# If not, it will be listed as invalid option on line 1
|
||||
if mono "" 2>&1 | head -n 1 | grep -Fq "$1"; then
|
||||
echo "Failure: $1"
|
||||
export MONO_DEBUG="$PREVIOUS_MONO_DEBUG"
|
||||
return 1
|
||||
fi
|
||||
|
||||
echo "Success: $1"
|
||||
return 0
|
||||
}
|
||||
|
||||
|
@ -46,9 +49,15 @@ VERSION_LESS_EQUAL() {
|
|||
[[ "$1" = "$(echo -e "$1\n$2" | sort -V | head -n 1)" ]]
|
||||
}
|
||||
|
||||
echo "Mono environment setup executed!"
|
||||
|
||||
MONO_VERSION="$(mono -V | head -n 1 | cut -d ' ' -f 5)"
|
||||
|
||||
echo "Mono version: $MONO_VERSION"
|
||||
|
||||
if VERSION_GREATER_EQUAL "$MONO_VERSION" "4.6.0"; then
|
||||
echo "Appending no-compact-seq-points to MONO_DEBUG..."
|
||||
MONO_DEBUG_IF_AVAILABLE "no-compact-seq-points"
|
||||
fi
|
||||
|
||||
echo "Mono environment setup finished!"
|
||||
|
|
Loading…
Reference in a new issue