This repository was archived by the owner on Feb 26, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Jaezmien Naejara
committed
Dec 22, 2020
1 parent
a847d65
commit ba1f7ea
Showing
1 changed file
with
23 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,42 @@ | ||
@echo off | ||
setlocal enabledelayedexpansion | ||
|
||
:: Build | ||
echo [Build.bat] Building FiMSharp... | ||
dotnet build FiMSharp -c Release -o bin/ | ||
|
||
echo. | ||
echo. | ||
echo [Build.bat] Building FiMSharp.Javascript... | ||
dotnet build FiMSharp.Javascript -c Release -o bin/ | ||
|
||
:: Build test program (optional) | ||
set osType=%1 | ||
if not "%osType%"=="" ( | ||
if not "%1"=="" ( | ||
|
||
echo [Build.bat] Building test program... | ||
set binDir=bin/%osType% | ||
dotnet clean -c Release -o "%binDir%" | ||
set FiMos=%1 | ||
set FiMbinDir=bin/!FiMos! | ||
|
||
echo. | ||
echo. | ||
echo [Build.bat] Building test program to "!FiMbinDir!"... | ||
dotnet clean -c Release -o "!FiMbinDir!" | ||
|
||
set buildCommand=dotnet publish FiMSharp.Test --self-contained=true -p:PublishSingleFile=True -c Release -o "%binDir%" | ||
set buildCommand=dotnet publish FiMSharp.Test --self-contained=true -p:PublishSingleFile=True -c Release -o "!FiMbinDir!" | ||
|
||
if "%osType%" == "win32" ( | ||
%buildCommand% --runtime win-x86 | ||
if "!FiMos!" == "win32" ( | ||
!buildCommand! --runtime win-x86 | ||
) | ||
if "%osType%" == "win" ( | ||
%buildCommand% --runtime win-x64 | ||
if "!FiMos!" == "win" ( | ||
!buildCommand! --runtime win-x64 | ||
) | ||
if "%osType%" == "linux" ( | ||
%buildCommand% --runtime linux-x64 | ||
if "!FiMos!" == "linux" ( | ||
!buildCommand! --runtime linux-x64 | ||
) | ||
if "%osType%" == "linuxarm" ( | ||
%buildCommand% --runtime linux-arm | ||
if "!FiMos!" == "linuxarm" ( | ||
!buildCommand! --runtime linux-arm | ||
) | ||
if "%osType%" == "darwin" ( | ||
%buildCommand% --runtime osx-x64 | ||
if "!FiMos!" == "darwin" ( | ||
!buildCommand! --runtime osx-x64 | ||
) | ||
|
||
) |