|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
|
2 // Use of this source code is governed by a BSD-style license that can be |
|
3 // found in the LICENSE file. |
|
4 |
|
5 // Precompiled header for Chromium project on Windows, not used by |
|
6 // other build configurations. Using precompiled headers speeds the |
|
7 // build up significantly, around 1/4th on VS 2010 on an HP Z600 with 12 |
|
8 // GB of memory. |
|
9 // |
|
10 // Numeric comments beside includes are the number of times they were |
|
11 // included under src/chrome/browser on 2011/8/20, which was used as a |
|
12 // baseline for deciding what to include in the PCH. Includes without |
|
13 // a numeric comment are generally included at least 5 times. It may |
|
14 // be possible to tweak the speed of the build by commenting out or |
|
15 // removing some of the less frequently used headers. |
|
16 |
|
17 #if defined(BUILD_PRECOMPILE_H_) |
|
18 #error You shouldn't include the precompiled header file more than once. |
|
19 #endif |
|
20 |
|
21 #define BUILD_PRECOMPILE_H_ |
|
22 |
|
23 // The Windows header needs to come before almost all the other |
|
24 // Windows-specific headers. |
|
25 #include <Windows.h> |
|
26 #include <dwmapi.h> |
|
27 #include <shellapi.h> |
|
28 #include <wincrypt.h> // 4 |
|
29 #include <wtypes.h> // 2 |
|
30 |
|
31 // Defines in atlbase.h cause conflicts; if we could figure out how |
|
32 // this family of headers can be included in the PCH, it might speed |
|
33 // up the build as several of them are used frequently. |
|
34 /* |
|
35 #include <atlbase.h> |
|
36 #include <atlapp.h> |
|
37 #include <atlcom.h> |
|
38 #include <atlcrack.h> // 2 |
|
39 #include <atlctrls.h> // 2 |
|
40 #include <atlmisc.h> // 2 |
|
41 #include <atlsafe.h> // 1 |
|
42 #include <atltheme.h> // 1 |
|
43 #include <atlwin.h> // 2 |
|
44 */ |
|
45 |
|
46 // Objbase.h and other files that rely on it bring in [ #define |
|
47 // interface struct ] which can cause problems in a multi-platform |
|
48 // build like Chrome's. #undef-ing it does not work as there are |
|
49 // currently 118 targets that break if we do this, so leaving out of |
|
50 // the precompiled header for now. |
|
51 //#include <commctrl.h> // 2 |
|
52 //#include <commdlg.h> // 3 |
|
53 //#include <cryptuiapi.h> // 2 |
|
54 //#include <Objbase.h> // 2 |
|
55 //#include <objidl.h> // 1 |
|
56 //#include <ole2.h> // 1 |
|
57 //#include <oleacc.h> // 2 |
|
58 //#include <oleauto.h> // 1 |
|
59 //#include <oleidl.h> // 1 |
|
60 //#include <propkey.h> // 2 |
|
61 //#include <propvarutil.h> // 2 |
|
62 //#include <pstore.h> // 2 |
|
63 //#include <shlguid.h> // 1 |
|
64 //#include <shlwapi.h> // 1 |
|
65 //#include <shobjidl.h> // 4 |
|
66 //#include <urlhist.h> // 2 |
|
67 |
|
68 // Caused other conflicts in addition to the 'interface' issue above. |
|
69 // #include <shlobj.h> |
|
70 |
|
71 #include <errno.h> |
|
72 #include <fcntl.h> |
|
73 #include <limits.h> // 4 |
|
74 #include <math.h> |
|
75 #include <memory.h> // 1 |
|
76 #include <signal.h> |
|
77 #include <stdarg.h> // 1 |
|
78 #include <stddef.h> |
|
79 #include <stdio.h> |
|
80 #include <stdlib.h> |
|
81 #include <string.h> |
|
82 #include <time.h> // 4 |
|
83 |
|
84 #include <algorithm> |
|
85 #include <bitset> // 3 |
|
86 #include <cmath> |
|
87 #include <cstddef> |
|
88 #include <cstdio> // 3 |
|
89 #include <cstdlib> // 2 |
|
90 #include <cstring> |
|
91 #include <deque> |
|
92 #include <fstream> // 3 |
|
93 #include <functional> |
|
94 #include <iomanip> // 2 |
|
95 #include <iosfwd> // 2 |
|
96 #include <iterator> |
|
97 #include <limits> |
|
98 #include <list> |
|
99 #include <map> |
|
100 #include <numeric> // 2 |
|
101 #include <ostream> |
|
102 #include <queue> |
|
103 #include <set> |
|
104 #include <sstream> |
|
105 #include <stack> |
|
106 #include <string> |
|
107 #include <utility> |
|
108 #include <vector> |