Skip to content

Commit

Permalink
Use conditional compilation directives to split DLL and EXE source
Browse files Browse the repository at this point in the history
  • Loading branch information
JockeJarre committed Jun 24, 2024
1 parent ac68072 commit e97ab40
Show file tree
Hide file tree
Showing 23 changed files with 1,037 additions and 297 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/b2s-backglass.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,30 +62,30 @@ jobs:
- name: Build Server
run: |
msbuild b2s_screenresidentifier/B2S_ScreenResIdentifier.sln /t:Rebuild /p:Configuration=${{ matrix.config }} /p:Platform=${{ matrix.platform }}
msbuild b2sbackglassserverexe/B2SBackglassServerEXE.sln /t:Restore,Rebuild /p:Configuration=${{ matrix.config }} /p:Platform="Any CPU"
msbuild b2sbackglassserver/B2SBackglassServerEXE.sln /t:Rebuild /p:Configuration=${{ matrix.config }} /p:Platform=${{ matrix.platform }}
msbuild b2sbackglassserverregisterapp/B2SBackglassServerRegisterApp.sln /t:Rebuild /p:Configuration=${{ matrix.config }} /p:Platform=${{ matrix.platform }}
msbuild b2sbackglassserver/B2SBackglassServer.sln /t:Rebuild /p:Configuration=${{ matrix.config }}
msbuild B2SWindowPunch/B2SWindowPunch.sln /t:Rebuild /p:Configuration=${{ matrix.config }}
shell: cmd
- name: Bundle
run: |
ls -R b2sbackglassserver/b2sbackglassserver/bin
mkdir tmp
cp b2s_screenresidentifier/b2s_screenresidentifier/bin/${{ matrix.platform }}/${{ matrix.config }}/B2S_ScreenResIdentifier.exe tmp
cp b2s_screenresidentifier/b2s_screenresidentifier/bin/${{ matrix.platform }}/${{ matrix.config }}/B2S_ScreenResIdentifier.exe.config tmp
: # ls -R b2sbackglassserverexe
cp b2sbackglassserverexe/bin/${{ matrix.config }}/B2SBackglassServerEXE.exe tmp
: # cp b2sbackglassserverexe/bin/${{ matrix.config }}/B2SBackglassServerEXE.exe.config tmp
cp b2sbackglassserverregisterapp/b2sbackglassserverregisterapp/bin/${{ matrix.platform }}/${{ matrix.config }}/B2SBackglassServerRegisterApp.exe tmp
cp b2sbackglassserver/b2sbackglassserver/bin/${{ matrix.config }}/B2SServerPluginInterface.dll tmp
cp B2SServerPluginInterface/B2SServerPluginInterface/bin/${{ matrix.config }}/B2SServerPluginInterface.dll tmp
cp b2sbackglassserver/b2sbackglassserver/bin/${{ matrix.config }}/B2SBackglassServer.dll tmp
cp b2sbackglassserver/b2sbackglassserver/bin/${{ matrix.platform }}/${{ matrix.config }}/B2SBackglassServerEXE.exe tmp
cp b2sbackglassserver/b2sbackglassserver/bin/${{ matrix.platform }}/${{ matrix.config }}/B2SBackglassServerEXE.exe.config tmp
cp b2sbackglassserver/b2sbackglassserver/B2SInit.cmd tmp
cp B2SWindowPunch/B2SWindowPunch/bin/${{ matrix.config }}/B2SWindowPunch.exe tmp
if [[ "${{ matrix.config }}" == "Debug" ]]; then
cp b2s_screenresidentifier/b2s_screenresidentifier/bin/${{ matrix.platform }}/${{ matrix.config }}/B2S_ScreenResIdentifier.pdb tmp
: # cp b2sbackglassserverexe/bin/${{ matrix.config }}/*/B2SBackglassServerEXE.pdb tmp
cp b2sbackglassserverregisterapp/b2sbackglassserverregisterapp/bin/${{ matrix.platform }}/${{ matrix.config }}/B2SBackglassServerRegisterApp.pdb tmp
cp b2sbackglassserver/b2sbackglassserver/bin/${{ matrix.config }}/B2SServerPluginInterface.pdb tmp
cp B2SServerPluginInterface/B2SServerPluginInterface/bin/${{ matrix.config }}/B2SServerPluginInterface.pdb tmp
cp b2sbackglassserver/b2sbackglassserver/bin/${{ matrix.config }}/B2SBackglassServer.pdb tmp
cp b2sbackglassserver/b2sbackglassserver/bin/${{ matrix.platform }}/${{ matrix.config }}/B2SBackglassServerEXE.pdb tmp
cp B2SWindowPunch/B2SWindowPunch/bin/${{ matrix.config }}/B2SWindowPunch.pdb tmp
fi
mkdir tmp/Plugins tmp/Plugins64
Expand Down
31 changes: 31 additions & 0 deletions b2sbackglassserver/B2SBackglassServerEXE.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.4.33205.214
MinimumVisualStudioVersion = 10.0.40219.1
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "B2SBackglassServerEXE", "B2SBackglassServer\B2SBackglassServerEXE.vbproj", "{AC2E94BE-21CD-434A-9039-6551DF43698B}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Debug|x64.ActiveCfg = Debug|x64
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Debug|x64.Build.0 = Debug|x64
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Debug|x86.ActiveCfg = Debug|x86
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Debug|x86.Build.0 = Debug|x86
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Release|x64.ActiveCfg = Release|x64
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Release|x64.Build.0 = Release|x64
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Release|x86.ActiveCfg = Release|x86
{AC2E94BE-21CD-434A-9039-6551DF43698B}.Release|x86.Build.0 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {5F9BB968-681A-4FB2-8074-C179F66DB0F2}
EndGlobalSection
EndGlobal
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<RegisterForComInterop>false</RegisterForComInterop>
<Prefer32Bit>false</Prefer32Bit>
<DefineConstants>B2S="DLL"</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
Expand All @@ -40,6 +41,7 @@
<RegisterForComInterop>false</RegisterForComInterop>
<RemoveIntegerChecks>true</RemoveIntegerChecks>
<Prefer32Bit>false</Prefer32Bit>
<DefineConstants>B2S="DLL"</DefineConstants>
</PropertyGroup>
<PropertyGroup>
<OptionExplicit>On</OptionExplicit>
Expand Down
Binary file not shown.
307 changes: 307 additions & 0 deletions b2sbackglassserver/b2sbackglassserver/B2SBackglassServerEXE.vbproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,307 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<ProjectGuid>{AC2E94BE-21CD-434A-9039-6551DF43698B}</ProjectGuid>
<OutputType>WinExe</OutputType>
<RootNamespace>B2S</RootNamespace>
<AssemblyName>B2SBackglassServerEXE</AssemblyName>
<FileAlignment>512</FileAlignment>
<MyType>WindowsFormsWithCustomSubMain</MyType>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<SccProjectName>SAK</SccProjectName>
<SccLocalPath>SAK</SccLocalPath>
<SccAuxPath>SAK</SccAuxPath>
<SccProvider>SAK</SccProvider>
<TargetFrameworkProfile />
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<DefineDebug>true</DefineDebug>
<DefineTrace>true</DefineTrace>
<OutputPath>bin\x86\Debug\</OutputPath>
<DocumentationFile>B2SBackglassServerEXE.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<RegisterForComInterop>false</RegisterForComInterop>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<DefineDebug>false</DefineDebug>
<DefineTrace>true</DefineTrace>
<Optimize>true</Optimize>
<OutputPath>bin\x86\Release\</OutputPath>
<DocumentationFile>B2SBackglassServerEXE.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<RegisterForComInterop>false</RegisterForComInterop>
<RemoveIntegerChecks>true</RemoveIntegerChecks>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' ">
<PlatformTarget>x64</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<DefineDebug>true</DefineDebug>
<DefineTrace>true</DefineTrace>
<OutputPath>bin\x64\Debug\</OutputPath>
<DocumentationFile>B2SBackglassServerEXE.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<RegisterForComInterop>false</RegisterForComInterop>
<Prefer32Bit>false</Prefer32Bit>
<DefineConstants>B2S="EXE"</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x64' ">
<PlatformTarget>x64</PlatformTarget>
<DebugType>pdbonly</DebugType>
<DefineDebug>false</DefineDebug>
<DefineTrace>true</DefineTrace>
<Optimize>true</Optimize>
<OutputPath>bin\x64\Release\</OutputPath>
<DocumentationFile>B2SBackglassServerEXE.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<RegisterForComInterop>false</RegisterForComInterop>
<RemoveIntegerChecks>true</RemoveIntegerChecks>
<Prefer32Bit>false</Prefer32Bit>
<DefineConstants>B2S="EXE"</DefineConstants>
</PropertyGroup>
<PropertyGroup>
<OptionExplicit>On</OptionExplicit>
</PropertyGroup>
<PropertyGroup>
<OptionCompare>Binary</OptionCompare>
</PropertyGroup>
<PropertyGroup>
<OptionStrict>Off</OptionStrict>
</PropertyGroup>
<PropertyGroup>
<OptionInfer>On</OptionInfer>
</PropertyGroup>
<PropertyGroup>
<StartupObject>Sub Main</StartupObject>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>B2SBackglassServerEXE.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'">
<DebugSymbols>true</DebugSymbols>
<DefineDebug>true</DefineDebug>
<DefineTrace>true</DefineTrace>
<OutputPath>bin\Debug\</OutputPath>
<DocumentationFile>B2SBackglassServerEXE.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<DebugType>full</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|AnyCPU'">
<DefineTrace>true</DefineTrace>
<OutputPath>bin\Release\</OutputPath>
<RemoveIntegerChecks>true</RemoveIntegerChecks>
<DocumentationFile>B2SBackglassServerEXE.xml</DocumentationFile>
<Optimize>true</Optimize>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<DebugType>pdbonly</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
</PropertyGroup>
<PropertyGroup>
<ApplicationManifest>My Project\app.manifest</ApplicationManifest>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
</ItemGroup>
<ItemGroup>
<Import Include="Microsoft.VisualBasic" />
<Import Include="System" />
<Import Include="System.Collections" />
<Import Include="System.Collections.Generic" />
<Import Include="System.Data" />
<Import Include="System.Diagnostics" />
<Import Include="System.Linq" />
<Import Include="System.Xml.Linq" />
</ItemGroup>
<ItemGroup>
<Compile Include="Classes\B2SAnimation.vb" />
<Compile Include="Classes\B2SBackglassServerEXE.vb" />
<Compile Include="Classes\B2SCollectData.vb" />
<Compile Include="Classes\B2SData.vb" />
<Compile Include="Classes\B2SLED.vb" />
<Compile Include="Classes\B2SPlayer.vb" />
<Compile Include="Classes\B2SReelDisplay.vb" />
<Compile Include="Classes\B2SScreen.vb" />
<Compile Include="Classes\B2SSettings.vb" />
<Compile Include="Classes\B2SStatistics.vb" />
<Compile Include="Classes\B2SSystem.vb" />
<Compile Include="Classes\Processes.vb" />
<Compile Include="Controls\B2SBaseBox.vb">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\B2SLEDBox.vb">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\B2SPictureBox.vb">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\B2SReelBox.vb">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\B2SSnifferPanel.vb">
<SubType>Component</SubType>
</Compile>
<Compile Include="Dream7\Dream7Display.vb">
<SubType>Component</SubType>
</Compile>
<Compile Include="Dream7\Segment.vb" />
<Compile Include="Dream7\SegmentNumber.vb" />
<Compile Include="Forms\Background.Designer.vb">
<DependentUpon>Background.vb</DependentUpon>
</Compile>
<Compile Include="Forms\Background.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\formBackglass.Designer.vb">
<DependentUpon>formBackglass.vb</DependentUpon>
</Compile>
<Compile Include="Forms\formBackglass.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\formDMD.Designer.vb">
<DependentUpon>formDMD.vb</DependentUpon>
</Compile>
<Compile Include="Forms\formDMD.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\formMode.Designer.vb">
<DependentUpon>formMode.vb</DependentUpon>
</Compile>
<Compile Include="Forms\formMode.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\formSettings.Designer.vb">
<DependentUpon>formSettings.vb</DependentUpon>
</Compile>
<Compile Include="Forms\formSettings.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\formSettingsMore.Designer.vb">
<DependentUpon>formSettingsMore.vb</DependentUpon>
</Compile>
<Compile Include="Forms\formSettingsMore.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Logging\Statistics.vb" />
<Compile Include="Logging\Log.vb" />
<Compile Include="moduleImageExtensions.vb" />
<Compile Include="My Project\AssemblyInfo.vb" />
<Compile Include="My Project\Application.Designer.vb">
<AutoGen>True</AutoGen>
<DependentUpon>Application.myapp</DependentUpon>
<DesignTime>True</DesignTime>
</Compile>
<Compile Include="My Project\Resources.Designer.vb">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="My Project\Settings.Designer.vb">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="Forms\Background.resx">
<DependentUpon>Background.vb</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="Forms\formBackglass.resx">
<DependentUpon>formBackglass.vb</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="Forms\formDMD.resx">
<DependentUpon>formDMD.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Forms\formMode.resx">
<DependentUpon>formMode.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Forms\formSettings.resx">
<DependentUpon>formSettings.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Forms\formSettingsMore.resx">
<DependentUpon>formSettingsMore.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="My Project\Resources.resx">
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
<CustomToolNamespace>My.Resources</CustomToolNamespace>
<SubType>Designer</SubType>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
<None Include="app.config" />
<None Include="My Project\app.manifest" />
<None Include="My Project\Application.myapp">
<Generator>MyApplicationCodeGenerator</Generator>
<LastGenOutput>Application.Designer.vb</LastGenOutput>
</None>
<None Include="My Project\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<CustomToolNamespace>My</CustomToolNamespace>
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
</None>
</ItemGroup>
<ItemGroup>
<None Include="Resources\camera1.wav" />
</ItemGroup>
<ItemGroup>
<None Include="Resources\EMReel.wav" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.8">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.8 %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<Folder Include="Plugin\" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
Loading

0 comments on commit e97ab40

Please sign in to comment.