This repository has been archived by the owner on Oct 28, 2023. It is now read-only.
/
hpg.csproj
109 lines (97 loc) · 4.23 KB
/
hpg.csproj
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"
DefaultTargets="Build">
<Import Project="hpg.targets" />
<PropertyGroup>
<ProjectGuid>{10A1F47C-6714-4047-8024-0DED4A331A361}</ProjectGuid>
<ProjectTypeGuids>{43F2F29C-E7A8-42CB-9375-27EA323809D8}</ProjectTypeGuids>
<OutputType>Exe</OutputType>
<AssemblyName>hpg</AssemblyName>
</PropertyGroup>
<ItemGroup>
<!-- Common Sources -->
<Compile Include="generator\parsable.cs" />
<Compile Include="generator\generator.cs" />
<Compile Include="generator\factory.cs" />
<Compile Include="generator\emitter.csharp.cs" />
<Compile Include="generator\emitter.bnf.cs" />
<Compile Include="generator\format.csharp.cs" />
<Compile Include="generator\AssemblyInfo.cs" />
<!-- Additional Generation 0 (aka Bootstrap) Sources -->
<Gen0 Include="generator\grammar.cs" />
<Gen0 Include="generator\bootstrap.cs" />
<!-- Additional Generation 1 Sources -->
<Gen1 Include="generator\parser.gen1.cs" />
<Gen1 Include="generator\hpg.cs" />
<!-- Additional HPG Sources -->
<HPG Include="generator\parser.cs" />
<HPG Include="generator\hpg.cs" />
<!-- Additional Test Sources -->
<Test Include="generator\parser.cs" />
<Test Include="test\test_*.cs" />
<!-- Files To Be Cleaned Up -->
<FileWrites Include="$(OutputPath)*"/>
<FileWrites Include="generator\parser.gen1.cs"/>
<FileWrites Include="generator\parser.cs"/>
</ItemGroup>
<Target Name="MakeBuildDirectory"
BeforeTargets="Gen0Parser">
<MakeDir Directories="$(OutputPath)" />
</Target>
<Target Name="Gen0Parser"
Inputs="@(Compile);@(Gen0)"
Outputs="$(OutputPath)hpg.gen0.exe">
<CSC Sources="@(Compile);@(Gen0)"
TargetType="exe"
OutputAssembly="$(OutputPath)hpg.gen0.exe"
EmitDebugInformation="true" />
</Target>
<Target Name="Gen1Source"
Inputs="$(OutputPath)hpg.gen0.exe;generator\hpg.bnf"
Outputs="generator\parser.gen1.cs"
DependsOnTargets="Gen0Parser"
BeforeTargets="Gen1Parser">
<Exec Command="$(ExeLauncher) $(OutputPath)hpg.gen0.exe generator\hpg.bnf $(AStyle) > generator\parser.gen1.cs"/>
</Target>
<Target Name="Gen1Parser"
Inputs="@(Compile);@(Gen1)"
Outputs="$(OutputPath)hpg.gen1.exe"
DependsOnTargets="Gen1Source">
<CSC Sources="@(Compile);@(Gen1)"
TargetType="exe"
OutputAssembly="$(OutputPath)hpg.gen1.exe"
EmitDebugInformation="true" />
</Target>
<Target Name="HPGSource"
Inputs="$(OutputPath)hpg.gen1.exe;generator\hpg.bnf"
Outputs="generator\parser.cs"
DependsOnTargets="Gen1Parser">
<Exec Command="$(ExeLauncher) $(OutputPath)hpg.gen1.exe generator\hpg.bnf $(AStyle) > generator\parser.cs" />
</Target>
<Target Name="Build"
Inputs="@(Compile);@(HPG)"
Outputs="$(OutputPath)\hpg.exe"
DependsOnTargets="HPGSource">
<CSC Sources="@(Compile);@(HPG)"
TargetType="exe"
OutputAssembly="$(OutputPath)hpg.exe"
EmitDebugInformation="true" />
</Target>
<Target Name="RunTests"
DependsOnTargets="HPGSource">
<CSC Sources="@(Compile);@(Test)"
TargetType="library"
References="$(NUnitReference)"
OutputAssembly="$(OutputPath)test.dll"
EmitDebugInformation="true" />
<Exec Command="$(NUnitConsole) $(OutputPath)test.dll"/>
</Target>
<Target Name="CheckCI">
<MSBuild Projects="hpg.csproj" Targets="RunTests" Properties="AStyle=" />
<MSBuild Projects="example\pascal\pascal.csproj" Properties="AStyle=" />
<MSBuild Projects="example\cobol\cobol.csproj" Properties="AStyle=" />
<MSBuild Projects="example\ini\ini.csproj" Properties="AStyle=" />
<MSBuild Projects="example\mini-java\mini-java.csproj" Properties="AStyle=" />
<MSBuild Projects="example\db2-ddl\ddl.csproj" Properties="AStyle=" />
</Target>
</Project>