Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: adblockplus.gyp

Issue 5979045791531008: create utils project with shared files (Closed)
Patch Set: Created July 16, 2014, 12:23 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 { 1 {
2 'includes': ['defaults.gypi'], 2 'includes': ['defaults.gypi'],
3 3
4 'variables': { 4 'variables': {
5 'build_type%': 'devbuild', 5 'build_type%': 'devbuild',
6 'build_version%': '', 6 'build_version%': '',
7 'shared_files': [
8 'src/shared/AutoHandle.cpp',
9 'src/shared/Communication.cpp',
10 'src/shared/Dictionary.cpp',
11 'src/shared/Utils.cpp',
12 ]
13 }, 7 },
14 8
15 'target_defaults': { 9 'target_defaults': {
16 'conditions': [ 10 'conditions': [
17 [ 11 [
18 'build_type=="devbuild"', 12 'build_type=="devbuild"',
19 { 13 {
20 'defines': ['ADBLOCK_PLUS_TEST_MODE', 'ADBLOCKPLUS_TEST_MODE'], 14 'defines': ['ADBLOCK_PLUS_TEST_MODE', 'ADBLOCKPLUS_TEST_MODE'],
21 }, 15 },
22 { 16 {
23 'defines': ['ADBLOCK_PLUS_PRODUCTION_MODE', 'ADBLOCKPLUS_PRODUCTION_MO DE'], 17 'defines': ['ADBLOCK_PLUS_PRODUCTION_MODE', 'ADBLOCKPLUS_PRODUCTION_MO DE'],
24 }, 18 },
25 ], 19 ],
26 [ 20 [
27 'build_version!=""', 21 'build_version!=""',
28 { 22 {
29 'defines': [ 23 'defines': [
30 'IEPLUGIN_VERSION=L"<(build_version)"', 24 'IEPLUGIN_VERSION=L"<(build_version)"',
31 'VERSIONINFO_VERSION=<!(python -c "import sys; print sys.argv[1].rep lace(\'.\', \',\')" <(build_version).0)', 25 'VERSIONINFO_VERSION=<!(python -c "import sys; print sys.argv[1].rep lace(\'.\', \',\')" <(build_version).0)',
32 'VERSIONINFO_VERSION_STR=\\"<(build_version).0\\"', 26 'VERSIONINFO_VERSION_STR=\\"<(build_version).0\\"',
33 ], 27 ],
34 } 28 }
35 ], 29 ],
36 ], 30 ],
37 }, 31 },
38 32
39 'targets': [{ 33 'targets': [{
34 'target_name': 'utils',
Felix Dahlke 2014/07/16 15:17:19 I'd vote for calling this "shared", like the direc
sergei 2014/07/16 15:50:18 Would it have more semantically sense to rename th
35 'type': 'static_library',
36 'sources': [
37 'src/shared/AutoHandle.cpp',
38 'src/shared/Communication.cpp',
39 'src/shared/Dictionary.cpp',
40 'src/shared/Utils.cpp',
41 ]
42 },
43
44 {
40 'target_name': 'AdblockPlusEngine', 45 'target_name': 'AdblockPlusEngine',
41 'type': 'executable', 46 'type': 'executable',
42 'dependencies': [ 47 'dependencies': [
48 'utils',
43 'libadblockplus/libadblockplus.gyp:libadblockplus', 49 'libadblockplus/libadblockplus.gyp:libadblockplus',
44 ], 50 ],
45 'sources': [ 51 'sources': [
46 'src/engine/Main.cpp', 52 'src/engine/Main.cpp',
47 'src/engine/Debug.cpp', 53 'src/engine/Debug.cpp',
48 'src/engine/UpdateInstallDialog.cpp', 54 'src/engine/UpdateInstallDialog.cpp',
49 'src/engine/Updater.cpp', 55 'src/engine/Updater.cpp',
50 'src/engine/engine.rc', 56 'src/engine/engine.rc',
51 '<@(shared_files)',
52 ], 57 ],
53 'libraries': [ 58 'libraries': [
54 '-ladvapi32', 59 '-ladvapi32',
55 '-lole32', 60 '-lole32',
56 '-luser32', 61 '-luser32',
57 '-lshell32', 62 '-lshell32',
58 '-lshlwapi', 63 '-lshlwapi',
59 ], 64 ],
60 'msbuild_toolset': 'v110_xp', 65 'msbuild_toolset': 'v110_xp',
61 'msvs_settings': { 66 'msvs_settings': {
62 'VCLinkerTool': { 67 'VCLinkerTool': {
63 'DelayLoadDLLs': ['Shell32.dll'], 68 'DelayLoadDLLs': ['Shell32.dll'],
64 }, 69 },
65 }, 70 },
66 }, 71 },
67 72
68 { 73 {
69 'target_name': 'AdblockPlus', 74 'target_name': 'AdblockPlus',
70 'type': 'shared_library', 75 'type': 'shared_library',
76 'dependencies': [
77 'utils'
78 ],
71 'sources': [ 79 'sources': [
72 'src/plugin/AdblockPlusClient.cpp', 80 'src/plugin/AdblockPlusClient.cpp',
73 'src/plugin/AdblockPlusDomTraverser.cpp', 81 'src/plugin/AdblockPlusDomTraverser.cpp',
74 'src/plugin/AdblockPlusTab.cpp', 82 'src/plugin/AdblockPlusTab.cpp',
75 'src/plugin/NotificationMessage.cpp', 83 'src/plugin/NotificationMessage.cpp',
76 'src/plugin/Plugin.cpp', 84 'src/plugin/Plugin.cpp',
77 'src/plugin/PluginClass.cpp', 85 'src/plugin/PluginClass.cpp',
78 'src/plugin/PluginClientBase.cpp', 86 'src/plugin/PluginClientBase.cpp',
79 'src/plugin/PluginClientFactory.cpp', 87 'src/plugin/PluginClientFactory.cpp',
80 'src/plugin/PluginDebug.cpp', 88 'src/plugin/PluginDebug.cpp',
81 'src/plugin/PluginFilter.cpp', 89 'src/plugin/PluginFilter.cpp',
82 'src/plugin/PluginMimeFilterClient.cpp', 90 'src/plugin/PluginMimeFilterClient.cpp',
83 'src/plugin/PluginMutex.cpp', 91 'src/plugin/PluginMutex.cpp',
84 'src/plugin/PluginSettings.cpp', 92 'src/plugin/PluginSettings.cpp',
85 'src/plugin/PluginStdAfx.cpp', 93 'src/plugin/PluginStdAfx.cpp',
86 'src/plugin/PluginSystem.cpp', 94 'src/plugin/PluginSystem.cpp',
87 'src/plugin/PluginTabBase.cpp', 95 'src/plugin/PluginTabBase.cpp',
88 'src/plugin/PluginUserSettings.cpp', 96 'src/plugin/PluginUserSettings.cpp',
89 'src/plugin/PluginUtil.cpp', 97 'src/plugin/PluginUtil.cpp',
90 'src/plugin/PluginWbPassThrough.cpp', 98 'src/plugin/PluginWbPassThrough.cpp',
91 'src/plugin/AdblockPlus.def', 99 'src/plugin/AdblockPlus.def',
92 'src/plugin/AdblockPlus.idl', 100 'src/plugin/AdblockPlus.idl',
93 'src/plugin/AdblockPlus.rc', 101 'src/plugin/AdblockPlus.rc',
94 'src/plugin/AdblockPlus.rgs', 102 'src/plugin/AdblockPlus.rgs',
95 '<@(shared_files)',
96 ], 103 ],
97 'include_dirs': [ 104 'include_dirs': [
98 '$(WindowsSDK_IncludePath)', 105 '$(WindowsSDK_IncludePath)',
99 '$(VCInstallDir)atlmfc/include', 106 '$(VCInstallDir)atlmfc/include',
100 '$(WINDDKDIR)/inc/atl71', 107 '$(WINDDKDIR)/inc/atl71',
101 ], 108 ],
102 # See "Adding Visual Style Support to an Extension, Plug-in, MMC Snap-in or a DLL 109 # See "Adding Visual Style Support to an Extension, Plug-in, MMC Snap-in or a DLL
103 # That Is Brought into a Process" on the link here: 110 # That Is Brought into a Process" on the link here:
104 # http://msdn.microsoft.com/en-us/library/windows/desktop/bb773175%28v=vs.85 %29.aspx#using_manifests 111 # http://msdn.microsoft.com/en-us/library/windows/desktop/bb773175%28v=vs.85 %29.aspx#using_manifests
105 'defines': ['PRODUCT_ADBLOCKPLUS', 'ISOLATION_AWARE_ENABLED'], 112 'defines': ['PRODUCT_ADBLOCKPLUS', 'ISOLATION_AWARE_ENABLED'],
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 ]], 151 ]],
145 'DelayLoadDLLs': ['Shell32.dll'], 152 'DelayLoadDLLs': ['Shell32.dll'],
146 }, 153 },
147 }, 154 },
148 }, 155 },
149 156
150 { 157 {
151 'target_name': 'tests', 158 'target_name': 'tests',
152 'type': 'executable', 159 'type': 'executable',
153 'dependencies': [ 160 'dependencies': [
161 'utils',
154 'libadblockplus/third_party/googletest.gyp:googletest_main', 162 'libadblockplus/third_party/googletest.gyp:googletest_main',
155 ], 163 ],
156 'sources': [ 164 'sources': [
157 'test/CommunicationTest.cpp', 165 'test/CommunicationTest.cpp',
158 'test/DictionaryTest.cpp', 166 'test/DictionaryTest.cpp',
159 '<@(shared_files)',
160 ], 167 ],
161 'defines': ['WINVER=0x0501'], 168 'defines': ['WINVER=0x0501'],
162 'link_settings': { 169 'link_settings': {
163 'libraries': ['-ladvapi32', '-lshell32', '-lole32'], 170 'libraries': ['-ladvapi32', '-lshell32', '-lole32'],
164 }, 171 },
165 'msvs_settings': { 172 'msvs_settings': {
166 'VCLinkerTool': { 173 'VCLinkerTool': {
167 'SubSystem': '1', # Console 174 'SubSystem': '1', # Console
168 'EntryPointSymbol': 'mainCRTStartup', 175 'EntryPointSymbol': 'mainCRTStartup',
169 }, 176 },
170 }, 177 },
171 }] 178 }]
172 } 179 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld