504820b762c0253ed79d3e03faf082ca44a40e31
[WebKit-https.git] / Source / WTF / WTF.vcxproj / WTF.proj
1 <?xml version="1.0" encoding="utf-8"?>\r
2 <Project InitialTargets="PreBuild" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
3 \r
4   <!-- normalize configuration case -->\r
5   <PropertyGroup Condition="'$(CONFIGURATION)'=='Release'">\r
6         <CONFIG>Production</CONFIG>\r
7     <DebugSuffix></DebugSuffix>\r
8   </PropertyGroup>\r
9   <PropertyGroup Condition="'$(CONFIGURATION)'=='Debug'">\r
10         <CONFIG>DebugSuffix</CONFIG>\r
11     <DebugSuffix>_debug</DebugSuffix>\r
12   </PropertyGroup>\r
13 \r
14   <!-- Wrapper to build WTF for both win32 and x64. -->\r
15   <PropertyGroup>\r
16     <OFFICIAL_BUILD>1</OFFICIAL_BUILD>\r
17     <WebKit_Libraries>$(SRCROOT)\AppleInternal</WebKit_Libraries>\r
18     <WebKit_OutputDir>$(OBJROOT)</WebKit_OutputDir>\r
19     <AppleInternal>$(DSTROOT)\AppleInternal</AppleInternal>\r
20     <AppleInternalLib32>$(AppleInternal)\lib32</AppleInternalLib32>\r
21     <AppleInternalLib64>$(AppleInternal)\lib64</AppleInternalLib64>\r
22     <AppleInternalBin32>$(AppleInternal)\bin32</AppleInternalBin32>\r
23     <AppleInternalBin64>$(AppleInternal)\bin64</AppleInternalBin64>\r
24     <AppleInternal32Symbols>$(AppleInternal)\public32\sym</AppleInternal32Symbols>\r
25     <AppleInternal64Symbols>$(AppleInternal)\public64\sym</AppleInternal64Symbols>\r
26     <ProgramFilesAAS32>Program Files (x86)\Common Files\Apple\Apple Application Support</ProgramFilesAAS32>\r
27     <ProgramFilesAAS64>Program Files\Common Files\Apple\Apple Application Support</ProgramFilesAAS64>\r
28     <ConfigurationBuildDir>$(OBJROOT)\$(CONFIG)</ConfigurationBuildDir>  \r
29     <OutputDirectory>$(DSTROOT)</OutputDirectory>\r
30   </PropertyGroup>\r
31 \r
32   <ItemGroup>\r
33     <WTF Include="WTF.submit.sln">\r
34       <AdditionalProperties>Platform=Win32;WEBKIT_OUTPUTDIR=$(WebKit_OutputDir);WEBKIT_LIBRARIES=$(WebKit_Libraries);OFFICIAL_BUILD=$(OFFICIAL_BUILD)</AdditionalProperties>\r
35     </WTF>\r
36     <WTF Include="WTF.submit.sln">\r
37       <AdditionalProperties>Platform=x64;WEBKIT_OUTPUTDIR=$(WebKit_OutputDir);WEBKIT_LIBRARIES=$(WebKit_Libraries);OFFICIAL_BUILD=$(OFFICIAL_BUILD)</AdditionalProperties>\r
38     </WTF>\r
39   </ItemGroup>\r
40 \r
41   <!-- Prepare for build -->\r
42   <Target Name="PreBuild" BeforeTargets="Build">\r
43     <Error Text="DSTROOT property or environment variable must be defined." Condition="'$(DSTROOT)' == ''" />\r
44     <Error Text="OBJROOT property or environment variable must be defined." Condition="'$(OBJROOT)' == ''" />\r
45     <MakeDir Directories="$(DSTROOT);$(OBJROOT)" />\r
46     <Message Text="Build output -> $(OBJROOT)" />\r
47     <Message Text="Final output -> $(DSTROOT)" />\r
48     <MakeDir Directories="$(AppleInternalLib32);$(AppleInternalLib64);$(AppleInternalBin32);$(AppleInternalBin64);$(AppleInternal32Symbols);$(AppleInternal64Symbols);$(AppleInternal)\include;$(DSTROOT)\$(ProgramFilesAAS32);$(DSTROOT)\$(ProgramFilesAAS64)" />\r
49   </Target>\r
50 \r
51   <!-- Build WTF Software -->\r
52   <Target Name="Build" AfterTargets="PreBuild">\r
53     <Message Text="Building $(CONFIGURATION) Solution" />\r
54     <Error Text="DSTROOT property or environment variable must be defined." Condition="'$(DSTROOT)' == ''" />\r
55     <Message Text="Output=$(WebKit_OutputDir)" />\r
56     <MSBuild Projects="@(WTF)" Properties="Configuration=$(CONFIG)" Targets="ReBuild" />\r
57   </Target>\r
58 \r
59   <Target Name="PostBuild" AfterTargets="Build">\r
60     <Error Text="DSTROOT property or environment variable must be defined." Condition="'$(DSTROOT)' == ''" />\r
61     <Message Text="Moving $(CONFIG) build results to $(DSTROOT)" />\r
62  \r
63     <!-- Identify the files to copy over -->\r
64     <CreateItem Include="$(ConfigurationBuildDir)\include\**\*.*">\r
65       <Output TaskParameter="Include" ItemName="IncFiles" />\r
66     </CreateItem>\r
67     <CreateItem Include="$(ConfigurationBuildDir)\bin32\*">\r
68        <Output TaskParameter="Include" ItemName="Bin32Files" />\r
69     </CreateItem>\r
70     <CreateItem Include="$(ConfigurationBuildDir)\bin64\*">\r
71        <Output TaskParameter="Include" ItemName="Bin64Files" />\r
72     </CreateItem>\r
73     <CreateItem Include="$(ConfigurationBuildDir)\bin32\WTF$(DebugSuffix).dll">\r
74       <Output TaskParameter="Include" ItemName="Bin32DLLFiles" />\r
75     </CreateItem>\r
76     <CreateItem Include="$(ConfigurationBuildDir)\bin64\WTF$(DebugSuffix).dll">\r
77       <Output TaskParameter="Include" ItemName="Bin64DLLFiles" />\r
78     </CreateItem>\r
79     <CreateItem Include="$(ConfigurationBuildDir)\bin32\*.pdb">\r
80        <Output TaskParameter="Include" ItemName="Bin32SymbolFiles" />\r
81     </CreateItem>\r
82     <CreateItem Include="$(ConfigurationBuildDir)\bin64\*.pdb">\r
83        <Output TaskParameter="Include" ItemName="Bin64SymbolFiles" />\r
84     </CreateItem>\r
85     <CreateItem Include="$(ConfigurationBuildDir)\lib32\*">\r
86        <Output TaskParameter="Include" ItemName="Lib32Files" />\r
87     </CreateItem>\r
88     <CreateItem Include="$(ConfigurationBuildDir)\lib64\*">\r
89        <Output TaskParameter="Include" ItemName="Lib64Files" />\r
90     </CreateItem>\r
91  \r
92     <Copy SourceFiles="@(IncFiles)" DestinationFiles="@(IncFiles->'$(DSTROOT)\AppleInternal\include\%(RecursiveDir)%(Filename)%(Extension)')" />\r
93     <Copy SourceFiles="@(Lib32Files)" DestinationFolder="$(AppleInternalLib32)" />\r
94     <Copy SourceFiles="@(Lib64Files)" DestinationFolder="$(AppleInternalLib64)" />\r
95     <Copy SourceFiles="@(Bin32Files)" DestinationFolder="$(AppleInternalBin32)" />\r
96     <Copy SourceFiles="@(Bin32DLLFiles)" DestinationFolder="$(DSTROOT)\$(ProgramFilesAAS32)" />\r
97     <Copy SourceFiles="@(Bin32SymbolFiles)" DestinationFolder="$(AppleInternal32Symbols)" />\r
98     <Copy SourceFiles="@(Bin64Files)" DestinationFolder="$(AppleInternalBin64)" />\r
99     <Copy SourceFiles="@(Bin64DLLFiles)" DestinationFolder="$(DSTROOT)\$(ProgramFilesAAS64)" />\r
100     <Copy SourceFiles="@(Bin64SymbolFiles)" DestinationFolder="$(AppleInternal64Symbols)" />\r
101   </Target>\r
102 \r
103 </Project>\r
104 \r