diff options
26 files changed, 197 insertions, 60 deletions
diff --git a/chrome/SConscript b/chrome/SConscript index 142702b..fefd331 100644 --- a/chrome/SConscript +++ b/chrome/SConscript @@ -46,7 +46,7 @@ if env_res.Bit('windows'): test_data_res = env_res.RES('test/data/resource.rc') webkit_res = env_res.RES('$WEBKIT_DIR/glue/webkit_resources.rc') - net_res = '$NET_DIR/net_resources.res' + net_res = '$TARGET_ROOT/grit_derived_sources/net_resources.res' dll_resources = [ browser_res, diff --git a/chrome/app/chrome_dll.vcproj b/chrome/app/chrome_dll.vcproj index 8471087..b61d3cd 100644 --- a/chrome/app/chrome_dll.vcproj +++ b/chrome/app/chrome_dll.vcproj @@ -130,7 +130,7 @@ /> <Tool Name="VCManifestTool" - AdditionalManifestFiles="$(SolutionDir)\app\chrome.dll.manifest" + AdditionalManifestFiles="$(SolutionDir)\app\chrome.dll.manifest" /> <Tool Name="VCXDCMakeTool" @@ -208,7 +208,7 @@ > </File> <File - RelativePath="..\..\net\base\net_resources.rc" + RelativePath="$(OutDir)\grit_derived_sources\net_resources.rc" > </File> <File diff --git a/chrome/app/chrome_dll_resource.h b/chrome/app/chrome_dll_resource.h index b5fa1a9..81fed6e 100644 --- a/chrome/app/chrome_dll_resource.h +++ b/chrome/app/chrome_dll_resource.h @@ -7,7 +7,6 @@ // Values around 200 are used by browser/browser_resources.h // Values around 300 are used by common/common_resources.h -// Values around 400 are used by common/net/net_resources.h // Values around 500 are used by renderer/renderer_resources.h #define IDR_SAD_PLUGIN 1000 diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc index d9c3e02..cae10ad 100644 --- a/chrome/browser/browser_main.cc +++ b/chrome/browser/browser_main.cc @@ -73,7 +73,6 @@ #include "chrome/installer/util/version.h" #include "chrome/views/accelerator_handler.h" #include "net/base/net_module.h" -#include "net/base/net_resources.h" #include "net/base/net_util.h" #include "net/base/sdch_manager.h" #include "net/base/winsock_init.h" @@ -81,6 +80,7 @@ #include "chromium_strings.h" #include "generated_resources.h" +#include "net_resources.h" namespace { diff --git a/chrome/browser/debugger/debugger_disabled.vsprops b/chrome/browser/debugger/debugger_disabled.vsprops index fd949c3..2d955b4 100644 --- a/chrome/browser/debugger/debugger_disabled.vsprops +++ b/chrome/browser/debugger/debugger_disabled.vsprops @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8.00" Name="debugger_disabled" - InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\breakpad\using_breakpad.vsprops;$(SolutionDir)..\third_party\libpng\using_libpng.vsprops;$(SolutionDir)..\skia\using_skia.vsprops;$(SolutionDir)..\third_party\zlib\using_zlib.vsprops;$(SolutionDir)\tools\build\win\using_generated_strings.vsprops;$(SolutionDir)..\third_party\icu38\build\using_icu.vsprops;$(SolutionDir)..\third_party\libxml\build\using_libxml.vsprops;$(SolutionDir)..\third_party\npapi\using_npapi.vsprops;$(SolutionDir)\tools\build\win\debugger_disabled.vsprops;$(SolutionDir)third_party\wtl\using_wtl.vsprops" + InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\breakpad\using_breakpad.vsprops;$(SolutionDir)..\third_party\libpng\using_libpng.vsprops;$(SolutionDir)..\skia\using_skia.vsprops;$(SolutionDir)..\third_party\zlib\using_zlib.vsprops;$(SolutionDir)..\tools\grit\build\using_generated_resources.vsprops;$(SolutionDir)..\third_party\icu38\build\using_icu.vsprops;$(SolutionDir)..\third_party\libxml\build\using_libxml.vsprops;$(SolutionDir)..\third_party\npapi\using_npapi.vsprops;$(SolutionDir)\tools\build\win\debugger_disabled.vsprops;$(SolutionDir)third_party\wtl\using_wtl.vsprops" > <Tool Name="VCCLCompilerTool" diff --git a/chrome/chrome.sln b/chrome/chrome.sln index aa0dbfd..716c97e 100755 --- a/chrome/chrome.sln +++ b/chrome/chrome.sln @@ -783,6 +783,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net", "..\net\build\net.vcp Release.AspNetCompiler.Debug = "False" EndProjectSection ProjectSection(ProjectDependencies) = postProject + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} = {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} EndProjectSection EndProject @@ -1948,6 +1949,12 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gcapi_test", "installer\gca {CD2FD73A-6AAB-4886-B887-760D18E8B635} = {CD2FD73A-6AAB-4886-B887-760D18E8B635} EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net_resources", "..\net\build\net_resources.vcproj", "{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}" + ProjectSection(WebsiteProperties) = preProject + Debug.AspNetCompiler.Debug = "True" + Release.AspNetCompiler.Debug = "False" + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Mixed Platforms = Debug|Mixed Platforms @@ -2556,6 +2563,14 @@ Global {8A3E1774-1DE9-445C-982D-3EE37C8A752A}.Release|Mixed Platforms.Build.0 = Release|Win32 {8A3E1774-1DE9-445C-982D-3EE37C8A752A}.Release|Win32.ActiveCfg = Release|Win32 {8A3E1774-1DE9-445C-982D-3EE37C8A752A}.Release|Win32.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Mixed Platforms.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Mixed Platforms.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Mixed Platforms.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.Build.0 = Release|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Mixed Platforms.Build.0 = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.ActiveCfg = Debug|Win32 @@ -3242,6 +3257,7 @@ Global {899F1280-3441-4D1F-BA04-CCD6208D9146} = {97555540-8163-4D0F-BCAC-EFA0FFED3453} {89C1C190-A5D1-4EC4-BD6A-67FF2195C7CC} = {846901FD-A619-4BD5-A303-38174730CDD6} {8A3E1774-1DE9-445C-982D-3EE37C8A752A} = {1174D37F-6ABB-45DA-81B3-C631281273B7} + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {EF78C1F9-AA17-4CA5-B6CB-39B37A73A3DA} {8C27D792-2648-4F5E-9ED0-374276327308} = {1AFC1EC3-24FA-4260-B099-76319EC9977A} {903F8C1E-537A-4C9E-97BE-075147CBE769} = {1174D37F-6ABB-45DA-81B3-C631281273B7} {9055E088-25C6-47FD-87D5-D9DD9FD75C9F} = {1174D37F-6ABB-45DA-81B3-C631281273B7} diff --git a/chrome/chrome_kjs.sln b/chrome/chrome_kjs.sln index 322a68c..d10859c 100644 --- a/chrome/chrome_kjs.sln +++ b/chrome/chrome_kjs.sln @@ -787,6 +787,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net", "..\net\build\net.vcp Release.AspNetCompiler.Debug = "False" EndProjectSection ProjectSection(ProjectDependencies) = postProject + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} = {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} EndProjectSection EndProject @@ -1738,6 +1739,12 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "terms", "terms", "{B1531263 app\resources\terms\terms_zh-TW.html = app\resources\terms\terms_zh-TW.html EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net_resources", "..\net\build\net_resources.vcproj", "{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}" + ProjectSection(WebsiteProperties) = preProject + Debug.AspNetCompiler.Debug = "True" + Release.AspNetCompiler.Debug = "False" + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -2427,6 +2434,16 @@ Global {8A3E1774-1DE9-445C-982D-3EE37C8A752A}.Release|Mixed Platforms.Build.0 = Release|Win32 {8A3E1774-1DE9-445C-982D-3EE37C8A752A}.Release|Win32.ActiveCfg = Release|Win32 {8A3E1774-1DE9-445C-982D-3EE37C8A752A}.Release|Win32.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Any CPU.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Mixed Platforms.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Any CPU.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Mixed Platforms.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Mixed Platforms.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.Build.0 = Release|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Any CPU.ActiveCfg = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Mixed Platforms.Build.0 = Debug|Win32 @@ -3164,6 +3181,7 @@ Global {899F1280-3441-4D1F-BA04-CCD6208D9146} = {97555540-8163-4D0F-BCAC-EFA0FFED3453} {89C1C190-A5D1-4EC4-BD6A-67FF2195C7CC} = {846901FD-A619-4BD5-A303-38174730CDD6} {8A3E1774-1DE9-445C-982D-3EE37C8A752A} = {1174D37F-6ABB-45DA-81B3-C631281273B7} + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {EF78C1F9-AA17-4CA5-B6CB-39B37A73A3DA} {8C27D792-2648-4F5E-9ED0-374276327308} = {1AFC1EC3-24FA-4260-B099-76319EC9977A} {903F8C1E-537A-4C9E-97BE-075147CBE769} = {1174D37F-6ABB-45DA-81B3-C631281273B7} {9055E088-25C6-47FD-87D5-D9DD9FD75C9F} = {1174D37F-6ABB-45DA-81B3-C631281273B7} diff --git a/net/base/net_resources.grd b/net/base/net_resources.grd new file mode 100644 index 0000000..655b785ca --- /dev/null +++ b/net/base/net_resources.grd @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="UTF-8"?> +<grit latest_public_release="0" current_release="1"> + <outputs> + <output filename="net_resources.h" type="rc_header"> + <emit emit_type='prepend'></emit> + </output> + <output filename="net_resources.rc" type="rc_all" /> + </outputs> + <translations /> + <release seq="1"> + <includes> + <include name="IDR_DIR_HEADER_HTML" file="dir_header.html" type="BINDATA" /> + + <!-- This file is generated by tld_cleanup. --> + <include name="IDR_EFFECTIVE_TLD_NAMES" file="effective_tld_names_clean.dat" filenameonly="true" type="BINDATA" /> + </includes> + </release> +</grit> diff --git a/net/base/net_resources.h b/net/base/net_resources.h deleted file mode 100644 index d0b9f8b..0000000 --- a/net/base/net_resources.h +++ /dev/null @@ -1,4 +0,0 @@ -// TODO(tc): Come up with a way to automate the generation of these -// IDs so they don't collide with other rc files. -#define IDR_DIR_HEADER_HTML 400 -#define IDR_EFFECTIVE_TLD_NAMES 401 diff --git a/net/base/net_resources.rc b/net/base/net_resources.rc deleted file mode 100644 index a85f4d3..0000000 --- a/net/base/net_resources.rc +++ /dev/null @@ -1,20 +0,0 @@ -// Resources used by the net module. This rc file is meant to be included by -// the application rc file (e.g., app/chrome_dll.rc). -// -// Paths in this file are relative to SolutionDir (//trunk/chrome/). - -#ifdef APSTUDIO_INVOKED - #error // Don't open in the Visual Studio resource editor! -#endif //APSTUDIO_INVOKED - -#include "net\\base\\net_resources.h" - -///////////////////////////////////////////////////////////////////////////// -// -// data resources -// - -IDR_DIR_HEADER_HTML BINDATA "net\\base\\dir_header.html" - -// The converted file is generated, so we need to use a path relative to "obj". -IDR_EFFECTIVE_TLD_NAMES BINDATA "net\\effective_tld_names_clean.dat" diff --git a/net/base/net_util.cc b/net/base/net_util.cc index 64f4d1d..6b24fe7 100644 --- a/net/base/net_util.cc +++ b/net/base/net_util.cc @@ -40,10 +40,13 @@ #include "googleurl/src/url_parse.h" #include "net/base/escape.h" #include "net/base/net_module.h" -#include "net/base/net_resources.h" #include "net/base/base64.h" #include "unicode/datefmt.h" +#if !defined(OS_MACOSX) +#include "net_resources.h" +#endif + using base::Time; namespace { diff --git a/net/base/registry_controlled_domain.cc b/net/base/registry_controlled_domain.cc index be485ac7..f6aa02a 100644 --- a/net/base/registry_controlled_domain.cc +++ b/net/base/registry_controlled_domain.cc @@ -45,9 +45,12 @@ #include "googleurl/src/gurl.h" #include "googleurl/src/url_parse.h" #include "net/base/net_module.h" -#include "net/base/net_resources.h" #include "net/base/net_util.h" +#if !defined(OS_MACOSX) +#include "net_resources.h" +#endif + namespace net { // This list of rules is used by unit tests and any other time that the main @@ -284,10 +287,14 @@ void RegistryControlledDomainService::UseDomainData(const std::string& data) { } void RegistryControlledDomainService::Init() { +#if defined(OS_MACOSX) + ParseDomainData(kDefaultDomainData); +#else // The resource file isn't present for some unit tests, for example. Fall // back to a tiny, basic list of rules in that case. StringPiece res_data = NetModule::GetResource(IDR_EFFECTIVE_TLD_NAMES); ParseDomainData(!res_data.empty() ? res_data : kDefaultDomainData); +#endif } void RegistryControlledDomainService::ParseDomainData(const StringPiece& data) { diff --git a/net/build/convert_tld_data.rules b/net/build/convert_tld_data.rules index 0331c13..db39029 100644 --- a/net/build/convert_tld_data.rules +++ b/net/build/convert_tld_data.rules @@ -7,8 +7,8 @@ <CustomBuildRule Name="Convert TLD Data File" DisplayName="Convert TLD Data File" - CommandLine=""$(OutDir)\tld_cleanup.exe" "$(InputPath)" "$(IntDir)\$(InputName)_clean.dat"" - Outputs=""$(IntDir)\$(InputName)_clean.dat"" + CommandLine=""$(OutDir)\tld_cleanup.exe" "$(InputPath)" "$(IntDir)\..\$(InputName)_clean.dat"" + Outputs=""$(IntDir)\..\$(InputName)_clean.dat"" FileExtensions="*.dat" ExecutionDescription="Converting TLD data file..." > diff --git a/net/build/net.vcproj b/net/build/net.vcproj index dad5e02..917f1d5 100644 --- a/net/build/net.vcproj +++ b/net/build/net.vcproj @@ -21,7 +21,7 @@ <Configuration Name="Debug|Win32" ConfigurationType="4" - InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\debug.vsprops;$(SolutionDir)..\third_party\icu38\build\using_icu.vsprops;$(SolutionDir)..\third_party\zlib\using_zlib.vsprops;$(SolutionDir)..\sdch\using_sdch.vsprops" + InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\debug.vsprops;$(SolutionDir)..\third_party\icu38\build\using_icu.vsprops;$(SolutionDir)..\third_party\zlib\using_zlib.vsprops;$(SolutionDir)..\sdch\using_sdch.vsprops;$(SolutionDir)..\tools\grit\build\using_generated_resources.vsprops" > <Tool Name="VCPreBuildEventTool" diff --git a/net/build/net_resources.vcproj b/net/build/net_resources.vcproj new file mode 100644 index 0000000..b122488 --- /dev/null +++ b/net/build/net_resources.vcproj @@ -0,0 +1,44 @@ +<?xml version="1.0" encoding="Windows-1252"?> +<VisualStudioProject + ProjectType="Visual C++" + Version="8.00" + Name="net_resources" + ProjectGUID="{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}" + RootNamespace="net_resources" + Keyword="Win32Proj" + > + <Platforms> + <Platform + Name="Win32" + /> + </Platforms> + <ToolFiles> + <ToolFile + RelativePath="..\..\tools\grit\build\grit_resources.rules" + /> + </ToolFiles> + <Configurations> + <Configuration + Name="Debug|Win32" + ConfigurationType="10" + InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\debug.vsprops" + > + </Configuration> + <Configuration + Name="Release|Win32" + ConfigurationType="10" + InheritedPropertySheets="$(SolutionDir)..\build\common.vsprops;$(SolutionDir)..\build\release.vsprops" + > + </Configuration> + </Configurations> + <Files> + <File + RelativePath="..\base\net_resources.grd" + > + </File> + <File + RelativePath="$(OutDir)\grit_derived_sources\net_resources.h" + > + </File> + </Files> +</VisualStudioProject> diff --git a/net/net.sln b/net/net.sln index 37878dc..daedba1 100644 --- a/net/net.sln +++ b/net/net.sln @@ -48,6 +48,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net", "build\net.vcproj", " Release.AspNetCompiler.Debug = "False" EndProjectSection ProjectSection(ProjectDependencies) = postProject + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} = {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} EndProjectSection EndProject @@ -154,10 +155,20 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sdch", "..\sdch\sdch.vcproj EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "dump_cache", "build\dump_cache.vcproj", "{4A14E455-2B7C-4C0F-BCC2-35A9666C186F}" + ProjectSection(WebsiteProperties) = preProject + Debug.AspNetCompiler.Debug = "True" + Release.AspNetCompiler.Debug = "False" + EndProjectSection ProjectSection(ProjectDependencies) = postProject {1832A374-8A74-4F9E-B536-69A699B3E165} = {1832A374-8A74-4F9E-B536-69A699B3E165} - {8C27D792-2648-4F5E-9ED0-374276327308} = {8C27D792-2648-4F5E-9ED0-374276327308} {326E9795-E760-410A-B69A-3F79DB3F5243} = {326E9795-E760-410A-B69A-3F79DB3F5243} + {8C27D792-2648-4F5E-9ED0-374276327308} = {8C27D792-2648-4F5E-9ED0-374276327308} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net_resources", "build\net_resources.vcproj", "{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}" + ProjectSection(WebsiteProperties) = preProject + Debug.AspNetCompiler.Debug = "True" + Release.AspNetCompiler.Debug = "False" EndProjectSection EndProject Global @@ -194,6 +205,10 @@ Global {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C}.Debug|Win32.Build.0 = Debug|Win32 {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C}.Release|Win32.ActiveCfg = Release|Win32 {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C}.Release|Win32.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.Build.0 = Release|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.ActiveCfg = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.Build.0 = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.ActiveCfg = Release|Win32 diff --git a/net/net_lib.scons b/net/net_lib.scons index 70d36e9..30e83a8 100644 --- a/net/net_lib.scons +++ b/net/net_lib.scons @@ -11,6 +11,7 @@ Import('env') env = env.Clone() env.ApplySConscript([ + '$GRIT_DIR/build/using_generated_resources.scons', '$ICU38_DIR/using_icu38.scons', '$SDCH_DIR/using_sdch.scons', '$ZLIB_DIR/using_zlib.scons', diff --git a/net/net_resources.scons b/net/net_resources.scons index c7dfc31..c76ed62 100644 --- a/net/net_resources.scons +++ b/net/net_resources.scons @@ -6,33 +6,39 @@ __doc__ = """ Configuration for building the net_resources.rc resources. """ +import os +import sys + Import('env') env = env.Clone() -env.Prepend( - RCFLAGS = [ - ['/l', '0x409'], - ], -) - input_files = [ 'base/effective_tld_names.dat', - 'tools/tld_cleanup/tld_cleanup.exe' + 'tools/tld_cleanup/tld_cleanup$PROGSUFFIX', ] +sys.path.append(env.Dir('$CHROME_SRC_DIR/tools/grit').abspath) +env.Tool('scons', toolpath=[env.Dir('$CHROME_SRC_DIR/tools/grit/grit')]) +# This dummy target is used to tell the emitter where to put the target files. +generated = env.GRIT('$TARGET_ROOT/grit_derived_sources/dummy_net_res', + 'base/net_resources.grd') + if env.Bit('windows'): + env.Prepend( + RCFLAGS = [ + '/l 0x409', + ], + ) + # TODO(port): Need to figure out what to do with external resources # on linux (and mac?). - # This dat file needed by net_resources is generated. - tld_names_clean = env.Command('net/effective_tld_names_clean.dat', - input_files, - '${SOURCES[1]} ${SOURCES[0]} $TARGET') - - rc = env.Command('net_resources.rc', - 'base/net_resources.rc', - Copy('$TARGET', '$SOURCE')) - - env.Depends(rc, tld_names_clean) - - env.RES(rc) + # This dat file needed by net_resources.rc is generated. + tld_names_clean = env.Command( + '$TARGET_ROOT/grit_derived_sources/effective_tld_names_clean.dat', + input_files, + '${SOURCES[1]} ${SOURCES[0]} $TARGET') + + for g in [g for g in generated if str(g).endswith('.rc')]: + net_res = env.RES(g) + env.Depends(net_res, tld_names_clean) diff --git a/net/tools/tld_cleanup/tld_cleanup.scons b/net/tools/tld_cleanup/tld_cleanup.scons index 882790f..fbdb2d3 100644 --- a/net/tools/tld_cleanup/tld_cleanup.scons +++ b/net/tools/tld_cleanup/tld_cleanup.scons @@ -14,7 +14,6 @@ env.ApplySConscript([ '$BASE_DIR/using_base.scons', '$CHROME_SRC_DIR/build/using_googleurl.scons', '$ICU38_DIR/using_icu38.scons', - '$NET_DIR/using_net.scons', ]) if env.Bit('windows'): diff --git a/webkit/build/localized_strings/SConscript b/webkit/build/localized_strings/SConscript index 39af769..5de0337 100644 --- a/webkit/build/localized_strings/SConscript +++ b/webkit/build/localized_strings/SConscript @@ -23,7 +23,6 @@ if env_res.Bit('windows'): ], ) -import os import sys sys.path.append(env.Dir('$CHROME_SRC_DIR/tools/grit').abspath) env_grd = env.Clone() diff --git a/webkit/tools/test_shell/SConscript b/webkit/tools/test_shell/SConscript index f41ee88..4a81850 100644 --- a/webkit/tools/test_shell/SConscript +++ b/webkit/tools/test_shell/SConscript @@ -178,7 +178,7 @@ if env.Bit('windows'): # TODO(port): figure out what to do with resources. resources = [ env_res.RES('resources/test_shell.rc'), - '$NET_DIR/net_resources.res', + '$TARGET_ROOT/grit_derived_sources/net_resources.res', '$TARGET_ROOT/grit_derived_sources/webkit_strings_en-US.res', ] diff --git a/webkit/tools/test_shell/test_shell.vcproj b/webkit/tools/test_shell/test_shell.vcproj index 86f1f39..9b55748 100644 --- a/webkit/tools/test_shell/test_shell.vcproj +++ b/webkit/tools/test_shell/test_shell.vcproj @@ -145,7 +145,7 @@ Name="resources" > <File - RelativePath="..\..\..\net\base\net_resources.rc" + RelativePath="$(OutDir)\grit_derived_sources\net_resources.rc" > </File> <File diff --git a/webkit/tools/test_shell/test_shell_tests.vcproj b/webkit/tools/test_shell/test_shell_tests.vcproj index cb579d5..ff0a6b2 100644 --- a/webkit/tools/test_shell/test_shell_tests.vcproj +++ b/webkit/tools/test_shell/test_shell_tests.vcproj @@ -183,7 +183,7 @@ > </File> <File - RelativePath="..\..\..\net\base\net_resources.rc" + RelativePath="$(OutDir)\grit_derived_sources\net_resources.rc" > </File> <File diff --git a/webkit/webkit.sln b/webkit/webkit.sln index 52c99fb..58d59dd 100644 --- a/webkit/webkit.sln +++ b/webkit/webkit.sln @@ -112,6 +112,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net", "..\net\build\net.vcp Release.AspNetCompiler.Debug = "False" EndProjectSection ProjectSection(ProjectDependencies) = postProject + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} = {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} EndProjectSection EndProject @@ -414,6 +415,12 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sqlite", "..\third_party\sq Release.AspNetCompiler.Debug = "False" EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net_resources", "..\net\build\net_resources.vcproj", "{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}" + ProjectSection(WebsiteProperties) = preProject + Debug.AspNetCompiler.Debug = "True" + Release.AspNetCompiler.Debug = "False" + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 @@ -512,6 +519,10 @@ Global {865575D0-37E2-405E-8CBA-5F6C485B5A26}.Debug|Win32.Build.0 = Debug|Win32 {865575D0-37E2-405E-8CBA-5F6C485B5A26}.Release|Win32.ActiveCfg = Release|Win32 {865575D0-37E2-405E-8CBA-5F6C485B5A26}.Release|Win32.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.Build.0 = Release|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.ActiveCfg = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.Build.0 = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.ActiveCfg = Release|Win32 @@ -621,6 +632,7 @@ Global {7100F41F-868D-4E99-80A2-AF8E6574749D} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {865575D0-37E2-405E-8CBA-5F6C485B5A26} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {8C27D792-2648-4F5E-9ED0-374276327308} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {A0D94973-D355-47A5-A1E2-3456F321F010} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {A508ADD3-CECE-4E0F-8448-2F5E454DF551} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} diff --git a/webkit/webkit_armu.sln b/webkit/webkit_armu.sln index 79a0c9b..99a7e0b 100644 --- a/webkit/webkit_armu.sln +++ b/webkit/webkit_armu.sln @@ -113,6 +113,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net", "..\net\build\net.vcp Release.AspNetCompiler.Debug = "False" EndProjectSection ProjectSection(ProjectDependencies) = postProject + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} = {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} EndProjectSection EndProject @@ -388,6 +389,12 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sqlite", "..\third_party\sq Release.AspNetCompiler.Debug = "False" EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net_resources", "..\net\build\net_resources.vcproj", "{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}" + ProjectSection(WebsiteProperties) = preProject + Debug.AspNetCompiler.Debug = "True" + Release.AspNetCompiler.Debug = "False" + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 @@ -478,6 +485,10 @@ Global {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C}.Debug|Win32.Build.0 = Debug|Win32 {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C}.Release|Win32.ActiveCfg = Release|Win32 {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C}.Release|Win32.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.Build.0 = Release|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.ActiveCfg = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.Build.0 = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.ActiveCfg = Release|Win32 @@ -581,6 +592,7 @@ Global {6EAD4A4B-2BBC-4974-8E45-BB5C16CC2AC9} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {7100F41F-868D-4E99-80A2-AF8E6574749D} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {8C27D792-2648-4F5E-9ED0-374276327308} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {A0D94973-D355-47A5-A1E2-3456F321F010} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {A508ADD3-CECE-4E0F-8448-2F5E454DF551} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} diff --git a/webkit/webkit_kjs.sln b/webkit/webkit_kjs.sln index 6e340f1..c9603cb 100644 --- a/webkit/webkit_kjs.sln +++ b/webkit/webkit_kjs.sln @@ -96,6 +96,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net", "..\net\build\net.vcp Release.AspNetCompiler.Debug = "False" EndProjectSection ProjectSection(ProjectDependencies) = postProject + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} = {E13045CD-7E1F-4A41-9B18-8D288B2E7B41} EndProjectSection EndProject @@ -399,6 +400,12 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sqlite", "..\third_party\sq Release.AspNetCompiler.Debug = "False" EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net_resources", "..\net\build\net_resources.vcproj", "{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}" + ProjectSection(WebsiteProperties) = preProject + Debug.AspNetCompiler.Debug = "True" + Release.AspNetCompiler.Debug = "False" + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 @@ -493,6 +500,10 @@ Global {867F64C9-D631-41A9-B467-13D6378A72AA}.Debug|Win32.Build.0 = Debug|Win32 {867F64C9-D631-41A9-B467-13D6378A72AA}.Release|Win32.ActiveCfg = Release|Win32 {867F64C9-D631-41A9-B467-13D6378A72AA}.Release|Win32.Build.0 = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.ActiveCfg = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Debug|Win32.Build.0 = Debug|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.ActiveCfg = Release|Win32 + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}.Release|Win32.Build.0 = Release|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.ActiveCfg = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.Build.0 = Debug|Win32 {8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.ActiveCfg = Release|Win32 @@ -597,6 +608,7 @@ Global {7100F41F-868D-4E99-80A2-AF8E6574749D} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {8423AF0D-4B88-4EBF-94E1-E4D00D00E21C} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {867F64C9-D631-41A9-B467-13D6378A72AA} = {4BC2C9E2-78FA-446A-B6E0-85689A2B4D3D} + {8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {8C27D792-2648-4F5E-9ED0-374276327308} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {A0D94973-D355-47A5-A1E2-3456F321F010} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} {A508ADD3-CECE-4E0F-8448-2F5E454DF551} = {2C5FC2FE-B8B0-44B9-A7C4-E5B5E7292F6B} |