-
Notifications
You must be signed in to change notification settings - Fork 129
/
Copy pathcheckenv.sh
32 lines (28 loc) · 1018 Bytes
/
checkenv.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/sh
if [ ! -d "$DIR" ]; then
echo "ERROR: 3d-fixes directory not set"
exit 1
fi
PATH="$DIR:$PATH"
DOSDIR="$DIR"
which cygpath >/dev/null 2>&1 && DOSDIR="$(cygpath -w "$DIR")"
echo "Using 3d-fixes directory: $DOSDIR"
# Check 3d-fixes contains required scripts and execute permissions are properly set:
if [ ! -x "$DIR/shadertool.py" \
-o ! -f "$DIR/shaderutil.py" \
-o ! -x "$DIR/unity_asset_extractor.py" \
-o ! -x "$DIR/unity_asset_bundle_extractor.py" \
-o ! -x "$DIR/extract_unity55_shaders.py" \
-o ! -x "$DIR/extract_unity53_shaders.py" \
-o ! -x "$DIR/extract_unity_shaders.py" \
]; then
echo "ERROR: Required scripts are missing from 3d-fixes directory."
echo " Please double check that you checked out / extracted 3d-fixes correctly."
exit 1
fi
# Check python3 is installed
if ! which python3 >/dev/null 2>&1; then
echo "ERROR: Python3 is not installed."
echo " Please re-run the cygwin installer and choose to install \"python3\" in the package selection."
exit 1
fi