| 1 |
<?xml version="1.0" encoding="utf-8"?> |
| 2 |
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
| 3 |
<ItemGroup> |
| 4 |
<PropertyPageSchema |
| 5 |
Include="$(MSBuildThisFileDirectory)$(MSBuildThisFileName).xml" /> |
| 6 |
<AvailableItemName |
| 7 |
Include="NASM"> |
| 8 |
<Targets>_NASM</Targets> |
| 9 |
</AvailableItemName> |
| 10 |
</ItemGroup> |
| 11 |
<UsingTask |
| 12 |
TaskName="NASM" |
| 13 |
TaskFactory="XamlTaskFactory" |
| 14 |
AssemblyName="Microsoft.Build.Tasks.v4.0"> |
| 15 |
<Task>$(MSBuildThisFileDirectory)$(MSBuildThisFileName).xml</Task> |
| 16 |
</UsingTask> |
| 17 |
<Target |
| 18 |
Name="_NASM" |
| 19 |
BeforeTargets="$(NASMBeforeTargets)" |
| 20 |
AfterTargets="$(NASMAfterTargets)" |
| 21 |
Condition="'@(NASM)' != ''" |
| 22 |
DependsOnTargets="$(NASMDependsOn);ComputeNASMOutput" |
| 23 |
Outputs="@(NASM->Metadata('Outputs')->Distinct())" |
| 24 |
Inputs="@(NASM);%(NASM.AdditionalDependencies);$(MSBuildProjectFile)"> |
| 25 |
<ItemGroup |
| 26 |
Condition="'@(SelectedFiles)' != ''"> |
| 27 |
<NASM |
| 28 |
Remove="@(NASM)" |
| 29 |
Condition="'%(Identity)' != '@(SelectedFiles)'" /> |
| 30 |
</ItemGroup> |
| 31 |
<ItemGroup> |
| 32 |
<NASM_tlog |
| 33 |
Include="%(NASM.Outputs)" |
| 34 |
Condition="'%(NASM.Outputs)' != '' and '%(NASM.ExcludedFromBuild)' != 'true'"> |
| 35 |
<Source>@(NASM, '|')</Source> |
| 36 |
</NASM_tlog> |
| 37 |
</ItemGroup> |
| 38 |
<Message |
| 39 |
Importance="High" |
| 40 |
Text="%(NASM.ExecutionDescription)" /> |
| 41 |
<WriteLinesToFile |
| 42 |
Condition="'@(NASM_tlog)' != '' and '%(NASM_tlog.ExcludedFromBuild)' != 'true'" |
| 43 |
File="$(IntDir)$(ProjectName).write.1.tlog" |
| 44 |
Lines="^%(NASM_tlog.Source);@(NASM_tlog->'%(Fullpath)')" /> |
| 45 |
<NASM |
| 46 |
Condition="'@(NASM)' != '' and '%(NASM.ExcludedFromBuild)' != 'true'" |
| 47 |
CommandLineTemplate="%(NASM.CommandLineTemplate)" |
| 48 |
OutFile="%(NASM.OutFile)" |
| 49 |
BinFormat="%(NASM.BinFormat)" |
| 50 |
IncludeDir="%(NASM.IncludeDir)" |
| 51 |
Defines="%(NASM.Defines)" |
| 52 |
AdditionalOptions="%(NASM.AdditionalOptions)" |
| 53 |
Inputs="@(NASM)" /> |
| 54 |
</Target> |
| 55 |
<PropertyGroup> |
| 56 |
<ComputeLinkInputsTargets> |
| 57 |
$(ComputeLinkInputsTargets); |
| 58 |
ComputeNASMOutput; |
| 59 |
</ComputeLinkInputsTargets> |
| 60 |
<ComputeLibInputsTargets> |
| 61 |
$(ComputeLibInputsTargets); |
| 62 |
ComputeNASMOutput; |
| 63 |
</ComputeLibInputsTargets> |
| 64 |
</PropertyGroup> |
| 65 |
<Target |
| 66 |
Name="ComputeNASMOutput" |
| 67 |
Condition="'@(NASM)' != ''"> |
| 68 |
<ItemGroup> |
| 69 |
<NASMDirsToMake |
| 70 |
Condition="'@(NASM)' != '' and '%(NASM.ExcludedFromBuild)' != 'true'" |
| 71 |
Include="%(NASM.OutFile)" /> |
| 72 |
<Link |
| 73 |
Include="%(NASMDirsToMake.Identity)" |
| 74 |
Condition="'%(Extension)'=='.obj' or '%(Extension)'=='.res' or '%(Extension)'=='.rsc' or '%(Extension)'=='.lib'" /> |
| 75 |
<Lib |
| 76 |
Include="%(NASMDirsToMake.Identity)" |
| 77 |
Condition="'%(Extension)'=='.obj' or '%(Extension)'=='.res' or '%(Extension)'=='.rsc' or '%(Extension)'=='.lib'" /> |
| 78 |
<ImpLib |
| 79 |
Include="%(NASMDirsToMake.Identity)" |
| 80 |
Condition="'%(Extension)'=='.obj' or '%(Extension)'=='.res' or '%(Extension)'=='.rsc' or '%(Extension)'=='.lib'" /> |
| 81 |
</ItemGroup> |
| 82 |
<MakeDir |
| 83 |
Directories="@(NASMDirsToMake->'%(RootDir)%(Directory)')" /> |
| 84 |
</Target> |
| 85 |
</Project> |