0023712: Remove dependency on Aspect_GraphicDevice from Aspect_Window
[occt.git] / samples / qt / IESample / run.sh
1 #!/bin/sh
2
3 export aSamplePath="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
4 if [ -e "${aSamplePath}/env.sh" ]; then source "${aSamplePath}/env.sh"; fi
5 cd $aSamplePath
6
7 host=`uname -s`
8 STATION=$host
9
10 RES_DIR="${aSamplePath}/res"
11
12 aSystem=`uname -s`
13 if [ "$aSystem" == "Darwin" ] && [ "$MACOSX_USE_GLX" != "true" ]; then
14   if [ "${CASDEB}" == "d" ]; then
15     BIN_DIR="${aSamplePath}/build/Debug/IESample.app/Contents/MacOS"
16   else
17     BIN_DIR="${aSamplePath}/build/Release/IESample.app/Contents/MacOS"
18   fi
19 else
20   BIN_DIR="${aSamplePath}/${STATION}/bin${CASDEB}"
21 fi
22
23 CSF_ResourcesDefaults="${RES_DIR}"
24 CSF_IEResourcesDefaults="${RES_DIR}"
25
26 PATH="${BIN_DIR}:${PATH}"
27
28 export CSF_IEResourcesDefaults CSF_ResourcesDefaults
29 export PATH
30
31 if test ! -r "${BIN_DIR}/IESample"; then
32   echo "Executable \"${BIN_DIR}/IESample\" not found."
33   if [ "$aSystem" == "Darwin" ] && [ "$MACOSX_USE_GLX" != "true" ]; then
34     echo "Probably you don't compile the application. Build it with Xcode."
35   else
36     echo "Probably you don't compile the application. Execute \"make\"."
37   fi
38   exit 1
39 fi
40
41 ${BIN_DIR}/IESample