This repository has been archived by the owner on Jun 14, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Uses multiple project.json's instead Haven't tested the shell script again
- Loading branch information
1 parent
1318421
commit eca87f1
Showing
8 changed files
with
125 additions
and
49 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 |
---|---|---|
|
@@ -2,6 +2,7 @@ | |
*.*~ | ||
bin/ | ||
obj/ | ||
out/ | ||
project.lock.json | ||
.DS_Store | ||
*.pyc | ||
|
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"version": "1.0.0-*", | ||
"buildOptions": { | ||
"emitEntryPoint": true, | ||
"define": [ | ||
"LINUX" | ||
] | ||
}, | ||
"frameworks": { | ||
"netcoreapp1.0": { | ||
"dependencies": { | ||
"Microsoft.NETCore.App": { | ||
"type": "platform", | ||
"version": "1.0.0" | ||
} | ||
} | ||
} | ||
}, | ||
"publishOptions": { | ||
"includeFiles": "libglfw.so" | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"version": "1.0.0-*", | ||
"buildOptions": { | ||
"emitEntryPoint": true, | ||
"define": [ | ||
"OSX" | ||
] | ||
}, | ||
"frameworks": { | ||
"netcoreapp1.0": { | ||
"dependencies": { | ||
"Microsoft.NETCore.App": { | ||
"type": "platform", | ||
"version": "1.0.0" | ||
} | ||
} | ||
} | ||
}, | ||
"publishOptions": { | ||
"includeFiles": "libglfw.dylib" | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"version": "1.0.0-*", | ||
"buildOptions": { | ||
"emitEntryPoint": true, | ||
"define": [ | ||
"WINDOWS" | ||
] | ||
}, | ||
"frameworks": { | ||
"netcoreapp1.0": { | ||
"dependencies": { | ||
"Microsoft.NETCore.App": { | ||
"type": "platform", | ||
"version": "1.0.0" | ||
} | ||
} | ||
} | ||
}, | ||
"publishOptions": { | ||
"includeFiles": "glfw.dll" | ||
} | ||
} |
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
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,27 @@ | ||
:: Clean output directory | ||
rmdir /s /q out | ||
|
||
:: Back up the current project.json | ||
ren project.json project.json.bak | ||
|
||
:: Windows | ||
copy "build_jsons\project.windows.json" "project.json" | ||
dotnet restore | ||
dotnet publish -c Release -o "out\windows" | ||
del project.json | ||
|
||
:: OSX | ||
copy "build_jsons\project.osx.json" "project.json" | ||
dotnet restore | ||
dotnet publish -c Release -o "out\osx" | ||
del project.json | ||
|
||
:: Linux | ||
copy "build_jsons\project.linux.json" "project.json" | ||
dotnet restore | ||
dotnet publish -c Release -o "out\linux" | ||
del project.json | ||
|
||
:: Restore backup | ||
ren project.json.bak project.json | ||
dotnet restore |
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,14 +1,27 @@ | ||
mv Program.cs Program.cs.temp | ||
echo "#define WINDOWS" | cat - Program.cs.temp > Program.cs | ||
dotnet publish -c Release -r win10-x64 | ||
rm Program.cs | ||
echo "#define OSX" | cat - Program.cs.temp > Program.cs | ||
dotnet publish -c Release -r osx.10.10-x64 | ||
rm Program.cs | ||
echo "#define LINUX" | cat - Program.cs.temp > Program.cs | ||
dotnet publish -c Release -r ubuntu.14.04-x64 | ||
rm Program.cs | ||
mv Program.cs.temp Program.cs | ||
cp "glfw.dll" "./bin/Release/netcoreapp1.0/win10-x64/publish" | ||
cp "libglfw.dylib" "./bin/Release/netcoreapp1.0/osx.10.10-x64/publish" | ||
cp "libglfw.so" "./bin/Release/netcoreapp1.0/ubuntu.14.04-x64/publish" | ||
# Clean output directory | ||
rm -rf out | ||
|
||
# Back up the current project.json | ||
mv project.json project.json.bak | ||
|
||
# Windows | ||
cp "/build_jsons/project.windows.json" "project.json" | ||
dotnet restore | ||
dotnet publish -c Release -o "out/windows" | ||
rm project.json | ||
|
||
# OSX | ||
cp "/build_jsons/project.osx.json" "project.json" | ||
dotnet restore | ||
dotnet publish -c Release -o "out/osx" | ||
rm project.json | ||
|
||
# Linux | ||
cp "/build_jsons/project.linux.json" "project.json" | ||
dotnet restore | ||
dotnet publish -c Release -o "out/linux" | ||
rm project.json | ||
|
||
# Restore backup | ||
mv project.json.bak project.json | ||
dotnet restore |