Skip to content
Snippets Groups Projects
Commit f5b94054 authored by Dmitry Puzyrkov's avatar Dmitry Puzyrkov
Browse files

...

parent c5cce7fd
No related branches found
No related tags found
No related merge requests found
......@@ -21,16 +21,18 @@ MHERE="$DIR"
export SOURCES=${MHERE}/../
case "${UNAME_OUT}" in
NAME_OUT="$(uname -s)"
case "${NAME_OUT}" in
Linux*) MACHINE=Linux;;
Darwin*) MACHINE=Mac;;
CYGWIN*) MACHINE=Cygwin;;
MINGW*) MACHINE=MinGw;;
MSYS_NT*) MACHINE=Git;;
*) MACHINE="UNKNOWN:${UNAME_OUT}"
*) MACHINE="UNKNOWN:${NAME_OUT}"
esac
#validate input params
. ${MHERE}/validate.sh
......@@ -68,7 +70,25 @@ set -- "${POSITIONAL_ARGS[@]}" # restore positional parameters
BUILD_TYPE="${1:-release}"
BUILD_OPTIONS="${@:2}"
BUILD_TARGET="${TARGET:-linux}"
DEFAULT_TARGET="linux"
if [ "$MACHINE" == "Mac" ]
then
DEFAULT_TARGET="osx"
fi
if [ "$MACHINE" == "Linux" ]
then
DEFAULT_TARGET="linux"
fi
if [ "$MACHINE" == "Git" ]
then
DEFAULT_TARGET="windows"
fi
echo "Host machin is $MACHINE"
BUILD_TARGET="${TARGET:-$DEFAULT_TARGET}"
BUILD_DIR=${PWD}/build_${BUILD_TARGET}_${BUILD_TYPE}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment