Skip to content

Commit

Permalink
Add Appvayor build script for Windows WTL build
Browse files Browse the repository at this point in the history
  • Loading branch information
loveemu committed Feb 25, 2017
1 parent 1bbdb97 commit 273c661
Show file tree
Hide file tree
Showing 2 changed files with 95 additions and 0 deletions.
34 changes: 34 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Static build version - changing the version dynamically means you can't
# just click from github to see how things are progressing until the build has
# finished, which could be a bit annoying.
version: 1.{build}-{branch}

environment:
matrix:
- platform: Win32
target: Release
visualstudio_string: vs2015

init:
# Use CRLF line endings on Windows so users can just use Notepad.
- git config --global core.autocrlf true

build_script:
- msbuild buildbot.xml /m /t:%target% /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"

after_build:
- ps: $env:gitrev = git describe --tags
- ps: $env:my_version = "$env:gitrev-$env:appveyor_repo_branch-$env:appveyor_build_number"
- set package_name=vgmtrans-%my_version%-%visualstudio_string%-%platform%-%target%
- copy %target%_WTL\VGMTrans_WTL.exe bin\vgmtrans.exe
- mkdir vgmtrans
- move bin vgmtrans
- move LICENSE.txt vgmtrans
- move README.md vgmtrans
- 7z a -mx9 %package_name%.7z vgmtrans

test: off

artifacts:
- path: $(package_name).7z
name: $(visualstudio_string)-$(target)
61 changes: 61 additions & 0 deletions buildbot.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Release" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- Add all the solutions here. -->
<ItemGroup>
<SolutionSet Include="$(MSBuildProjectDirectory)\VGMTrans_WTL.sln" />
<ProjectSetCPU Include="$(MSBuildProjectDirectory)\VGMTrans_WTL.sln" />
</ItemGroup>
<!-- Add common build properties here. -->
<PropertyGroup>
<CreateHardLinksIfPossible>true</CreateHardLinksIfPossible>
<CompileFastPlz>BuildInParallel=True;
CreateHardLinksForCopyFilesToOutputDirectoryIfPossible=$(CreateHardLinksIfPossible);
CreateHardLinksForCopyAdditionalFilesIfPossible=$(CreateHardLinksIfPossible);
CreateHardLinksForCopyLocalIfPossible=$(CreateHardLinksIfPossible);
CreateHardLinksForPublishFilesIfPossible=$(CreateHardLinksIfPossible);
</CompileFastPlz>
</PropertyGroup>
<!-- Add all the custom targets here. -->
<Target Name="CleanBloat" AfterTargets="InternalBuild">
<ItemGroup>
<BloatToDelete Include="$(MSBuildProjectDirectory)\bin\**\*.bsc"/>
<BloatToDelete Include="$(MSBuildProjectDirectory)\bin\**\*.exp"/>
<BloatToDelete Include="$(MSBuildProjectDirectory)\bin\**\*.ilk"/>
<BloatToDelete Include="$(MSBuildProjectDirectory)\bin\**\*.iobj"/>
<BloatToDelete Include="$(MSBuildProjectDirectory)\bin\**\*.ipdb"/>
<BloatToDelete Include="$(MSBuildProjectDirectory)\bin\**\*.lib"/>
<BloatToDelete Include="$(MSBuildProjectDirectory)\bin\**\*.pdb"/>
</ItemGroup>
<Delete Files="@(BloatToDelete)" />
</Target>
<Target Name="CleanCruft">
<ItemGroup>
<CruftToDelete Include="$(MSBuildProjectDirectory)\**\svnrev.h"/>
<CruftToDelete Include="$(MSBuildProjectDirectory)\**\*.CppClean.log" />
</ItemGroup>
<Delete Files="@(CruftToDelete)" />
</Target>
<Target Name="InternalBuild" AfterTargets="Debug;Release">
<MSBuild Projects="@(SolutionSet)" BuildInParallel="false" Properties="Configuration=$(BaseConfiguration)" Targets="Clean" />
<MSBuild Projects="@(ProjectSetCPU)" BuildInParallel="false" Properties="Configuration=%(ConfigCPU.Identity)" Targets="Clean" />
<CallTarget Targets="CleanCruft" />
<MSBuild Projects="@(SolutionSet)" BuildInParallel="false" Properties="Configuration=$(BaseConfiguration);$(CompileFastPlz)" Targets="Build" />
<MSBuild Projects="@(ProjectSetCPU)" BuildInParallel="true" Properties="Configuration=%(ConfigCPU.Identity);BuildProjectReferences=false;$(CompileFastPlz)" Targets="@(TargetsSetCPU)" />
</Target>
<Target Name="Debug">
<PropertyGroup>
<BaseConfiguration>Debug</BaseConfiguration>
</PropertyGroup>
<ItemGroup>
<ConfigCPU Include="Debug"/>
</ItemGroup>
</Target>
<Target Name="Release">
<PropertyGroup>
<BaseConfiguration>Release</BaseConfiguration>
</PropertyGroup>
<ItemGroup>
<ConfigCPU Include="Release"/>
</ItemGroup>
</Target>
</Project>

0 comments on commit 273c661

Please sign in to comment.