VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src/Build/build_veracrypt_linux_no_sse2.sh
diff options
context:
space:
mode:
Diffstat (limited to 'src/Build/build_veracrypt_linux_no_sse2.sh')
-rwxr-xr-xsrc/Build/build_veracrypt_linux_no_sse2.sh14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/Build/build_veracrypt_linux_no_sse2.sh b/src/Build/build_veracrypt_linux_no_sse2.sh
index 5f29dc49..7162ecd4 100755
--- a/src/Build/build_veracrypt_linux_no_sse2.sh
+++ b/src/Build/build_veracrypt_linux_no_sse2.sh
@@ -20,8 +20,20 @@ if [ "$(id -u)" != "0" ]; then
exit 1
fi
-# the sources of wxWidgets 3.2.5 must be extracted to the parent directory
+# Check if wxWidgets-3.2.5 exists in PARENTDIR; if not, use /tmp
+if [ ! -d "$PARENTDIR/wxWidgets-3.2.5" ]; then
+ export PARENTDIR="/tmp"
+fi
+
+# The sources of wxWidgets 3.2.5 must be extracted to the parent directory
export WX_ROOT=$PARENTDIR/wxWidgets-3.2.5
+
+# Exit with error if wxWidgets is not found
+if [ ! -d "$WX_ROOT" ]; then
+ echo "Error: wxWidgets-3.2.5 not found in either the default PARENTDIR or /tmp. Exiting."
+ exit 1
+fi
+
echo "Using wxWidgets sources in $WX_ROOT"
cd $SOURCEPATH