Skip to content

Commit

Permalink
Test of using xmake for building/generating C++ projects.
Browse files Browse the repository at this point in the history
  • Loading branch information
tomspilman committed Jul 7, 2024
1 parent 9b295e8 commit 7f3bc9d
Show file tree
Hide file tree
Showing 8 changed files with 70 additions and 334 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -88,5 +88,9 @@ IDE/MonoDevelop/MonoDevelop.MonoGame/templates/Common/MonoGame.Framework.dll.con
# CAKE
.cake/**

# Xmake
.xmake
vsxmake2022

# docfx
_*
100 changes: 5 additions & 95 deletions MonoGame.Framework.Native.sln
Original file line number Diff line number Diff line change
Expand Up @@ -11,120 +11,30 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "MonoGame.Generator.CTypes",
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "MonoGame.Tests.WindowsVK", "Tests\MonoGame.Tests.WindowsVK.csproj", "{C670BF60-56F7-493F-B5DD-50F97DB80A04}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "monogame.wndows", "src\monogame\windows\monogame_windows.vcxproj", "{E9536A29-2151-4839-A580-1A03FE787999}"
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "desktopvk", "src\monogame\vsxmake2022\desktopvk\desktopvk.vcxproj", "{92A214CA-39E6-4EBB-9A5F-8ADCCE4EF2B1}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug_DX|Any CPU = Debug_DX|Any CPU
Debug_DX|x64 = Debug_DX|x64
Debug_VK|Any CPU = Debug_VK|Any CPU
Debug_VK|x64 = Debug_VK|x64
Debug|Any CPU = Debug|Any CPU
Debug|x64 = Debug|x64
Release_DX|Any CPU = Release_DX|Any CPU
Release_DX|x64 = Release_DX|x64
Release_VK|Any CPU = Release_VK|Any CPU
Release_VK|x64 = Release_VK|x64
Release|Any CPU = Release|Any CPU
Release|x64 = Release|x64
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_DX|Any CPU.ActiveCfg = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_DX|Any CPU.Build.0 = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_DX|x64.ActiveCfg = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_DX|x64.Build.0 = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_VK|Any CPU.ActiveCfg = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_VK|Any CPU.Build.0 = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_VK|x64.ActiveCfg = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug_VK|x64.Build.0 = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug|Any CPU.Build.0 = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug|x64.ActiveCfg = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Debug|x64.Build.0 = Debug|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_DX|Any CPU.ActiveCfg = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_DX|Any CPU.Build.0 = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_DX|x64.ActiveCfg = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_DX|x64.Build.0 = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_VK|Any CPU.ActiveCfg = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_VK|Any CPU.Build.0 = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_VK|x64.ActiveCfg = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release_VK|x64.Build.0 = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release|Any CPU.ActiveCfg = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release|Any CPU.Build.0 = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release|x64.ActiveCfg = Release|Any CPU
{56BA741D-6AF1-489B-AB00-338DE11B1D32}.Release|x64.Build.0 = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_DX|Any CPU.ActiveCfg = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_DX|Any CPU.Build.0 = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_DX|x64.ActiveCfg = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_DX|x64.Build.0 = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_VK|Any CPU.ActiveCfg = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_VK|Any CPU.Build.0 = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_VK|x64.ActiveCfg = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug_VK|x64.Build.0 = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug|Any CPU.Build.0 = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug|x64.ActiveCfg = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Debug|x64.Build.0 = Debug|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_DX|Any CPU.ActiveCfg = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_DX|Any CPU.Build.0 = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_DX|x64.ActiveCfg = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_DX|x64.Build.0 = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_VK|Any CPU.ActiveCfg = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_VK|Any CPU.Build.0 = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_VK|x64.ActiveCfg = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release_VK|x64.Build.0 = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release|Any CPU.ActiveCfg = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release|Any CPU.Build.0 = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release|x64.ActiveCfg = Release|Any CPU
{74F12E34-D96B-4EC1-A218-BAFC83DC6220}.Release|x64.Build.0 = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_DX|Any CPU.ActiveCfg = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_DX|Any CPU.Build.0 = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_DX|x64.ActiveCfg = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_DX|x64.Build.0 = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_VK|Any CPU.ActiveCfg = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_VK|Any CPU.Build.0 = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_VK|x64.ActiveCfg = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug_VK|x64.Build.0 = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug|Any CPU.Build.0 = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug|x64.ActiveCfg = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Debug|x64.Build.0 = Debug|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_DX|Any CPU.ActiveCfg = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_DX|Any CPU.Build.0 = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_DX|x64.ActiveCfg = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_DX|x64.Build.0 = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_VK|Any CPU.ActiveCfg = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_VK|Any CPU.Build.0 = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_VK|x64.ActiveCfg = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release_VK|x64.Build.0 = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release|Any CPU.ActiveCfg = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release|Any CPU.Build.0 = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release|x64.ActiveCfg = Release|Any CPU
{C670BF60-56F7-493F-B5DD-50F97DB80A04}.Release|x64.Build.0 = Release|Any CPU
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_DX|Any CPU.ActiveCfg = Debug_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_DX|Any CPU.Build.0 = Debug_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_DX|x64.ActiveCfg = Debug_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_DX|x64.Build.0 = Debug_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_VK|Any CPU.ActiveCfg = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_VK|Any CPU.Build.0 = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_VK|x64.ActiveCfg = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug_VK|x64.Build.0 = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug|Any CPU.ActiveCfg = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug|Any CPU.Build.0 = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug|x64.ActiveCfg = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Debug|x64.Build.0 = Debug_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_DX|Any CPU.ActiveCfg = Release_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_DX|Any CPU.Build.0 = Release_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_DX|x64.ActiveCfg = Release_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_DX|x64.Build.0 = Release_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_VK|Any CPU.ActiveCfg = Release_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_VK|Any CPU.Build.0 = Release_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_VK|x64.ActiveCfg = Release_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release_VK|x64.Build.0 = Release_VK|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release|Any CPU.ActiveCfg = Release_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release|Any CPU.Build.0 = Release_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release|x64.ActiveCfg = Release_DX|x64
{E9536A29-2151-4839-A580-1A03FE787999}.Release|x64.Build.0 = Release_DX|x64
{92A214CA-39E6-4EBB-9A5F-8ADCCE4EF2B1}.Debug_VK|Any CPU.ActiveCfg = Debug|x64
{92A214CA-39E6-4EBB-9A5F-8ADCCE4EF2B1}.Debug_VK|Any CPU.Build.0 = Debug|x64
{92A214CA-39E6-4EBB-9A5F-8ADCCE4EF2B1}.Release_VK|Any CPU.ActiveCfg = Release|x64
{92A214CA-39E6-4EBB-9A5F-8ADCCE4EF2B1}.Release_VK|Any CPU.Build.0 = Release|x64
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
8 changes: 3 additions & 5 deletions Tests/MonoGame.Tests.WindowsVK.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
Expand Down Expand Up @@ -50,11 +50,9 @@

<ItemGroup>
<ProjectReference Include="..\MonoGame.Framework\MonoGame.Framework.Native.csproj" />
<ProjectReference Include="..\src\monogame\windows\monogame_windows.vcxproj">
<Private>True</Private>
</ProjectReference>
<ProjectReference Include="..\src\monogame\vsxmake2022\desktopvk\desktopvk.vcxproj" />

<Content Include="..\Artifacts\monogame.wndows\$(Configuration)_VK\monogame.native.dll">
<Content Include="..\Artifacts\monogame.native\windows\desktopvk\$(Configuration)\monogame.native.dll">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>

Expand Down
8 changes: 8 additions & 0 deletions src/monogame/build_windows.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
@echo off
@echo.
@echo === Debug ========================================================================
xmake f -m debug && xmake -r

@echo.
@echo === Release ======================================================================
xmake f -m release && xmake -r
4 changes: 4 additions & 0 deletions src/monogame/make_windows_solution.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
@echo off
xmake project -m "Release,Debug" -k vsxmake


Loading

0 comments on commit 7f3bc9d

Please sign in to comment.