|
|
|
@ -5,6 +5,7 @@ platform=x64
@@ -5,6 +5,7 @@ platform=x64
|
|
|
|
|
vs=vs2022 |
|
|
|
|
configuration=Release |
|
|
|
|
build_only=false |
|
|
|
|
disable_tests=true |
|
|
|
|
ci=false |
|
|
|
|
target_framework= |
|
|
|
|
verbosity=minimal |
|
|
|
@ -18,10 +19,6 @@ oshost=""
@@ -18,10 +19,6 @@ oshost=""
|
|
|
|
|
os="" |
|
|
|
|
test= |
|
|
|
|
|
|
|
|
|
if [[ $(uname -m) != *"64"* ]]; then |
|
|
|
|
platform=x86 |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
build() |
|
|
|
|
{ |
|
|
|
|
if [ $ci = true ]; then |
|
|
|
@ -67,10 +64,10 @@ generate()
@@ -67,10 +64,10 @@ generate()
|
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
if [ "$os" = "linux" ] || [ "$os" = "macosx" ]; then |
|
|
|
|
"$builddir/premake.sh" --file="$builddir/premake5.lua" gmake2 --os=$os --arch=$platform --configuration=$configuration --target-framework=$target_framework "$@" |
|
|
|
|
"$builddir/premake.sh" --file="$builddir/premake5.lua" gmake2 --os=$os --arch=$platform --configuration=$configuration --target-framework=$target_framework --disable-tests=$disable_tests "$@" |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
"$builddir/premake.sh" --file="$builddir/premake5.lua" $vs --os=$os --arch=$platform --configuration=$configuration --target-framework=$target_framework |
|
|
|
|
"$builddir/premake.sh" --file="$builddir/premake5.lua" $vs --os=$os --arch=$platform --configuration=$configuration --target-framework=$target_framework --disable-tests=$disable_tests |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
restore() |
|
|
|
@ -180,6 +177,29 @@ detect_os()
@@ -180,6 +177,29 @@ detect_os()
|
|
|
|
|
os=$oshost |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
detect_arch() |
|
|
|
|
{ |
|
|
|
|
if [ "$oshost" = "linux" ] || [ "$oshost" = "macosx" ]; then |
|
|
|
|
arch=$(uname -m) |
|
|
|
|
if [ "$arch" = "x86_64" ]; then |
|
|
|
|
platform="x64" |
|
|
|
|
elif [ "$arch" = "arm64" ] || [ "$arch" = "aarch64" ]; then |
|
|
|
|
platform="arm64" |
|
|
|
|
else |
|
|
|
|
echo "Unknown architecture: $arch" |
|
|
|
|
fi |
|
|
|
|
elif [ "$oshost" = "windows" ]; then |
|
|
|
|
arch=$(echo $PROCESSOR_ARCHITECTURE) |
|
|
|
|
if [ "$arch" = "AMD64" ]; then |
|
|
|
|
platform="x64" |
|
|
|
|
elif [ "$arch" = "ARM64" ]; then |
|
|
|
|
platform="arm64" |
|
|
|
|
else |
|
|
|
|
echo "Unknown architecture: $arch" |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
find_msbuild() |
|
|
|
|
{ |
|
|
|
|
if [ -x "$(command -v MSBuild.exe)" ]; then |
|
|
|
@ -191,6 +211,7 @@ find_msbuild()
@@ -191,6 +211,7 @@ find_msbuild()
|
|
|
|
|
|
|
|
|
|
cmd=$(tr '[:upper:]' '[:lower:]' <<< $1) |
|
|
|
|
detect_os |
|
|
|
|
detect_arch |
|
|
|
|
download_premake |
|
|
|
|
|
|
|
|
|
while [[ $# > 0 ]]; do |
|
|
|
@ -227,6 +248,9 @@ while [[ $# > 0 ]]; do
@@ -227,6 +248,9 @@ while [[ $# > 0 ]]; do
|
|
|
|
|
-build_only) |
|
|
|
|
build_only=true |
|
|
|
|
;; |
|
|
|
|
-disable-tests) |
|
|
|
|
disable_tests=true |
|
|
|
|
;; |
|
|
|
|
esac |
|
|
|
|
shift |
|
|
|
|
done |
|
|
|
|