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