Changing how the game is build.
This commit is contained in:
parent
bc8315db35
commit
8e18b24f94
15
build.sh
15
build.sh
@ -16,6 +16,13 @@ then
|
|||||||
cmake="cmake -DCMAKE_SYSTEM_NAME='Windows' -DCMAKE_FIND_ROOT_PATH='/usr/bin:/usr/x86_64-w64-mingw32' -DCMAKE_CXX_COMPILER='x86_64-w64-mingw32-g++' -DCMAKE_C_COMPILER='x86_64-w64-mingw32-gcc'"
|
cmake="cmake -DCMAKE_SYSTEM_NAME='Windows' -DCMAKE_FIND_ROOT_PATH='/usr/bin:/usr/x86_64-w64-mingw32' -DCMAKE_CXX_COMPILER='x86_64-w64-mingw32-g++' -DCMAKE_C_COMPILER='x86_64-w64-mingw32-gcc'"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
buildType=$2
|
||||||
|
|
||||||
|
if [[ $2 == "" ]]
|
||||||
|
then
|
||||||
|
buildType="Debug"
|
||||||
|
fi
|
||||||
|
|
||||||
currentDir=$(pwd)
|
currentDir=$(pwd)
|
||||||
threads=$(($(nproc)+1))
|
threads=$(($(nproc)+1))
|
||||||
|
|
||||||
@ -38,10 +45,10 @@ mkdir -p build
|
|||||||
cd build
|
cd build
|
||||||
if hash ninja 2>/dev/null
|
if hash ninja 2>/dev/null
|
||||||
then
|
then
|
||||||
$cmake -DBUILD_DEMOS=0 -DBUILD_EXTRAS=0 -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=0 -GNinja ..
|
$cmake -DBUILD_DEMOS=0 -DBUILD_EXTRAS=0 -DCMAKE_BUILD_TYPE=$buildType -DBUILD_SHARED_LIBS=0 -GNinja ..
|
||||||
ninja
|
ninja
|
||||||
else
|
else
|
||||||
$cmake -DBUILD_DEMOS=0 -DBUILD_EXTRAS=0 -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=0 ..
|
$cmake -DBUILD_DEMOS=0 -DBUILD_EXTRAS=0 -DCMAKE_BUILD_TYPE=$buildType -DBUILD_SHARED_LIBS=0 ..
|
||||||
make -j$threads
|
make -j$threads
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -53,9 +60,9 @@ mkdir -p build
|
|||||||
cd build
|
cd build
|
||||||
if hash ninja 2>/dev/null
|
if hash ninja 2>/dev/null
|
||||||
then
|
then
|
||||||
$cmake -DGLFW_BUILD_EXAMPLES=0 -DGLFW_BUILD_TESTS=0 -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=0 -GNinja ..
|
$cmake -DGLFW_BUILD_EXAMPLES=0 -DGLFW_BUILD_TESTS=0 -DCMAKE_BUILD_TYPE=$buildType -DBUILD_SHARED_LIBS=0 -GNinja ..
|
||||||
ninja
|
ninja
|
||||||
else
|
else
|
||||||
$cmake -DGLFW_BUILD_EXAMPLES=0 -DGLFW_BUILD_TESTS=0 -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=0 ..
|
$cmake -DGLFW_BUILD_EXAMPLES=0 -DGLFW_BUILD_TESTS=0 -DCMAKE_BUILD_TYPE=$buildType -DBUILD_SHARED_LIBS=0 ..
|
||||||
make -j$threads
|
make -j$threads
|
||||||
fi
|
fi
|
||||||
|
@ -21,7 +21,7 @@ then
|
|||||||
./build.sh clean
|
./build.sh clean
|
||||||
fi
|
fi
|
||||||
|
|
||||||
./build.sh $platform
|
./build.sh $platform Release
|
||||||
|
|
||||||
rc=$?
|
rc=$?
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user