D2k csproj: Use MSBuild tasks instead of shelling out
This commit is contained in:
@@ -39,12 +39,6 @@
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<CustomCommands>
|
||||
<CustomCommands>
|
||||
<Command type="AfterBuild" command="cp ${TargetFile} ../mods/d2k" workingdir="${ProjectDir}" />
|
||||
<Command type="AfterBuild" command="cp ${TargetFile}.mdb ../mods/d2k" workingdir="${ProjectDir}" />
|
||||
</CustomCommands>
|
||||
</CustomCommands>
|
||||
<DefineConstants>TRACE;DEBUG;</DefineConstants>
|
||||
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
|
||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||
@@ -59,12 +53,6 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
|
||||
<Optimize>true</Optimize>
|
||||
<CustomCommands>
|
||||
<CustomCommands>
|
||||
<Command type="AfterBuild" command="cp ${TargetFile} ../mods/d2k" workingdir="${ProjectDir}" />
|
||||
<Command type="AfterBuild" command="cp ${TargetFile}.mdb ../mods/d2k" workingdir="${ProjectDir}" />
|
||||
</CustomCommands>
|
||||
</CustomCommands>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System" />
|
||||
@@ -101,7 +89,6 @@
|
||||
<Compile Include="Traits\World\D2kEditorResourceLayer.cs" />
|
||||
<Compile Include="Lint\CheckImportActors.cs" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<PropertyGroup>
|
||||
<PostBuildEvent>mkdir "$(SolutionDir)mods/d2k/"
|
||||
copy "$(TargetPath)" "$(SolutionDir)mods/d2k/"
|
||||
@@ -136,6 +123,30 @@ cd "$(SolutionDir)"</PostBuildEvent>
|
||||
<Install>true</Install>
|
||||
</BootstrapperPackage>
|
||||
</ItemGroup>
|
||||
<ItemGroup />
|
||||
<ItemGroup />
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<Target Name="AfterBuild">
|
||||
<MakeDir Directories="$(SolutionDir)mods/d2k/"/>
|
||||
<Copy
|
||||
SourceFiles="$(TargetPath)"
|
||||
DestinationFolder="$(SolutionDir)mods/d2k/"/>
|
||||
<!--
|
||||
We need to copy OpenRA.Mods.D2k.pdb (not `.dll.pdb`). This is only necessary on Windows.
|
||||
Mono outputs a `.dll.mdb` so we can just append `.mdb` directly.
|
||||
-->
|
||||
<Copy
|
||||
SourceFiles="$(TargetDir)$(TargetName).pdb"
|
||||
DestinationFolder="$(SolutionDir)mods/d2k/"
|
||||
Condition="'$(OS)' == 'Windows_NT'"/>
|
||||
<Copy
|
||||
SourceFiles="$(TargetPath).mdb"
|
||||
DestinationFolder="$(SolutionDir)mods/d2k/"
|
||||
Condition="'$(OS)' == 'Unix'"/>
|
||||
<!-- Uncomment these lines when debugging or adding to this target
|
||||
<Message Text="DEBUG OS: $(OS)"/>
|
||||
<Message Text="DEBUG SolutionDir: $(SolutionDir)"/>
|
||||
<Message Text="DEBUG TargetPath: $(TargetPath)"/>
|
||||
<Message Text="DEBUG TargetDir: $(TargetDir)"/>
|
||||
<Message Text="DEBUG TargetName: $(TargetName)"/>
|
||||
-->
|
||||
</Target>
|
||||
</Project>
|
||||
Reference in New Issue
Block a user