summaryrefslogtreecommitdiffstats
path: root/tools/grit
Commit message (Collapse)AuthorAgeFilesLines
* Altering grit so that it clobbers all outputs even on windows.bradnelson@chromium.org2009-09-042-6/+99
| | | | | | | | | | | | | | | | | | | | Previously headers were handled differently only as an optimization. This thwarts vstudio + gyp. Adding a grit_info python stub so that gyp can get an accurate list of inputs and outputs from a grd file. Currently only using it for the inputs, because there's no good way in gyp to have rules invoke a !@( expansion once per rule instance. This change will over-specify dependencies for these modules, but it will at least not under-specify them anymore. BUG=24836 TEST=None Review URL: http://codereview.chromium.org/197007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25499 0039d316-1c4b-4281-b951-d872f2087c98
* Updatetony@chromium.org2009-09-041-0/+4
| | | | | | | | | | | | | | grit to replace \n to actual new lines in data pack files. Windows' MessageBox automatically converts \n to a new line, but GTK+ doesn't. BUG=20943 Review URL: http://codereview.chromium.org/196007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25408 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 24094, caused a build break.maruel@chromium.org2009-08-242-11/+2
| | | | | | | | | TBR=mnaganov BUG=none TEST=none Review URL: http://codereview.chromium.org/174319 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24096 0039d316-1c4b-4281-b951-d872f2087c98
* DevTools l10n: merge Inspector's and DevTools's strings; also, disable l10n ↵mnaganov@chromium.org2009-08-242-2/+11
| | | | | | | | | | | until mgr agreeement. BUG=none TEST=none Review URL: http://codereview.chromium.org/173267 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24094 0039d316-1c4b-4281-b951-d872f2087c98
* GRIT: add support for 'js_map_format' needed for DevTools l10n.mnaganov@chromium.org2009-08-107-5/+176
| | | | | | | | | WebKit Inspector is localized using a JS file containing the following map: localizedStrings[<english text>] = <translated text>; Review URL: http://codereview.chromium.org/164066 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22900 0039d316-1c4b-4281-b951-d872f2087c98
* Add <if> blocks to xtb files in the simplest possible way. This currentlytc@google.com2009-07-221-1/+18
| | | | | | | | | | | | only supports checking the OS, but we can add more information if necessary. BUG=16884 Review URL: http://codereview.chromium.org/159148 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21249 0039d316-1c4b-4281-b951-d872f2087c98
* Instead of try:-except:-finally:, use nested try:-except: withinsgk@google.com2009-06-191-28/+29
| | | | | | | | | try:-finally: so builds will work without forced upgrades to Python 2.5. BUG=12818 TEST=successful build Review URL: http://codereview.chromium.org/140005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18848 0039d316-1c4b-4281-b951-d872f2087c98
* Convert to gyp generation of chrome_resources and chrome_strings.sgk@chromium.org2009-06-043-5/+5
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/119128 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17609 0039d316-1c4b-4281-b951-d872f2087c98
* Revert last checkin to fix resources in Release builds.sgk@chromium.org2009-06-033-5/+5
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/119075 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17468 0039d316-1c4b-4281-b951-d872f2087c98
* Convert to gyp generation of chrome_resources and chrome_strings.sgk@chromium.org2009-06-033-5/+5
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/119061 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17467 0039d316-1c4b-4281-b951-d872f2087c98
* Fix branded resource buiding.jrg@chromium.org2009-05-291-2/+8
| | | | | | | | | | | One visible change: new tab page has Google icon, not Chromium. Gyp doesn't have a set environment variable facility; hence the addition of a command line option to grit. Review URL: http://codereview.chromium.org/113974 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17148 0039d316-1c4b-4281-b951-d872f2087c98
* Have the grit rules depend on the .pak files.tc@google.com2009-05-062-2/+2
| | | | | | | | | | | chrome_resources and chrome_strings was continually rebuilding because it depended on the .h file, but the .h file doesn't get written if there are no changes. The .pak file always gets written. Review URL: http://codereview.chromium.org/115035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15432 0039d316-1c4b-4281-b951-d872f2087c98
* Doesn't fix anything at all but make it clearer.maruel@chromium.org2009-05-061-28/+28
| | | | | | Review URL: http://codereview.chromium.org/109051 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15375 0039d316-1c4b-4281-b951-d872f2087c98
* Move the shared JS and CSS out of the HTML files and into separate files.arv@chromium.org2009-05-051-5/+36
| | | | | | Review URL: http://codereview.chromium.org/99151 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15323 0039d316-1c4b-4281-b951-d872f2087c98
* Only skip the GRIT header writing on Windows. This will causetc@google.com2009-05-011-5/+6
| | | | | | | | | | | | | | resource only changes to rebuild lots of stuff on Mac and Linux, but since most of this is happening on Windows anyway, only optimize for Windows. This should make second builds faster since all the dependencies are up to date. Review URL: http://codereview.chromium.org/99265 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15023 0039d316-1c4b-4281-b951-d872f2087c98
* Changes in preparation for webkit switch to gyp.bradnelson@google.com2009-04-291-1/+1
| | | | | | | | These won't get gated live without a change to all.gyp, so landing them separately. Review URL: http://codereview.chromium.org/100146 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14822 0039d316-1c4b-4281-b951-d872f2087c98
* First cut at adding a map between strings names and resource ids.tc@google.com2009-04-244-1/+127
| | | | | | | | | | | | | This creates a mapping for all the entries in the theme_resources.grd file and adds a static method for querying the mapping. BUG=10639 Review URL: http://codereview.chromium.org/92085 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14443 0039d316-1c4b-4281-b951-d872f2087c98
* grit: cut down on chattiness.evan@chromium.org2009-04-142-5/+10
| | | | | | | | | - We don't need to print the copyright every time we run. - Don't print empty lines when there are no warnings. Review URL: http://codereview.chromium.org/67085 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13691 0039d316-1c4b-4281-b951-d872f2087c98
* This adds link[rel=icon] elements to the DOM UI html files for downloads and arv@chromium.org2009-04-101-3/+6
| | | | | | | | | | | | history. It also adds code to inline the resources for <link rel="icon"> elements BUG=9805 Review URL: http://codereview.chromium.org/66041 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13550 0039d316-1c4b-4281-b951-d872f2087c98
* Remove the checked-in scons configuration files.sgk@google.com2009-04-011-15/+0
| | | | | | Review URL: http://codereview.chromium.org/53121 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12982 0039d316-1c4b-4281-b951-d872f2087c98
* This fixes a few GRIT issues:tc@google.com2009-03-273-7/+24
| | | | | | | | | | | | | | - The generated header files had the wrong paths specified in the vcproj files. - Have the .h files generate to a temp file and overwrite the real .h files if they changed from the last run. This prevents recompiling when only a resource is changed. - Change the output file to the .rc file because otherwise the vcproj file would recompile every time because the .h file wasn't changing. Since the .rc file gets written all the time, this isn't a problem. On a side note, you still have to re-link to get the resources in chrome.dll. I imagine if you turn on incremental linking, this would be pretty fast. BUG=7967 Review URL: http://codereview.chromium.org/53028 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12630 0039d316-1c4b-4281-b951-d872f2087c98
* Switching net over to use gyp on windows.bradnelson@google.com2009-03-181-1/+1
| | | | | | Review URL: http://codereview.chromium.org/48108 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11942 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes CRLF and trailing white spaces.maruel@chromium.org2009-03-0572-918/+918
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10982 0039d316-1c4b-4281-b951-d872f2087c98
* Use grit to generate locale rc files and remove the old locale rc files from ↵tc@google.com2009-03-053-55/+20
| | | | | | | | | | | | | | the tree. I made a small change to grit so we can use our resource ID as the translation ID making it a bit easier to read. The old locale_settings*.rc files would #include the google_strings.rc or chromium_strings.rc. Instead, I added it to the vcproj file using $(CHROMIUM_BUILD) to grab the right file. This required changing the output names in the grd files. TBR=deanm Review URL: http://codereview.chromium.org/39152 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10955 0039d316-1c4b-4281-b951-d872f2087c98
* fix python2.6 warnings in grittc@google.com2009-03-044-7/+9
| | | | | | | | | | | remove one assert as it's not correct BUG=8298,8299 Review URL: http://codereview.chromium.org/40073 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10922 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Use grit to generate locale rc files and remove the old locale rc ↵tc@google.com2009-03-032-19/+4
| | | | | | | | | | | files from the tree." Revert "window_ is null during BrowserWindow creation. Assume full screen" Revert "Move SupportsWindowFeature from BrowserView to Browser so" git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10814 0039d316-1c4b-4281-b951-d872f2087c98
* Use grit to generate locale rc files and remove the old locale rc files from ↵tc@google.com2009-03-032-4/+19
| | | | | | | | | | | | | the tree. I made a small change to grit so we can use our resource ID as the translation ID making it a bit easier to read. I also used a script to convert the existing .rc files to .xtb files. Review URL: http://codereview.chromium.org/28327 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10809 0039d316-1c4b-4281-b951-d872f2087c98
* Properly handle errors in GRIT in the scons build.tc@google.com2009-02-271-29/+37
| | | | | | | | | | This lets the child process exit even if there are errors and causes the main scons process to identify these errors as build failures. Review URL: http://codereview.chromium.org/28282 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10652 0039d316-1c4b-4281-b951-d872f2087c98
* Add os support to grit so we can conditionally include resources based ontc@google.com2009-02-271-0/+3
| | | | | | | | | platform. Review URL: http://codereview.chromium.org/28237 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10556 0039d316-1c4b-4281-b951-d872f2087c98
* Fix a bug where the flattened HTML file was not gettingtc@google.com2009-02-261-4/+3
| | | | | | | | | included in data pack files. Review URL: http://codereview.chromium.org/28222 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10525 0039d316-1c4b-4281-b951-d872f2087c98
* fix the grd scanner to only include files that we're usingtc@google.com2009-02-261-5/+2
| | | | | | | | | bug=8139 Review URL: http://codereview.chromium.org/28225 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10519 0039d316-1c4b-4281-b951-d872f2087c98
* Fix scons build where the internal theme files don't exist.tc@google.com2009-02-261-1/+6
| | | | | | | Review URL: http://codereview.chromium.org/28218 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10515 0039d316-1c4b-4281-b951-d872f2087c98
* Fix grit include dependencies in the scons build.tc@google.com2009-02-262-14/+4
| | | | | | | | | | | | | | | Re-enable the scons code that walks a grd file and adds its dependencies as build dependencies. This requires that all our dependencies are files in our source tree (which is what motivated getting rid of the tld data as a generated resource). I had to fix up the terms of service for this. Also remove some code that disabled .pak file generation on windows which was broken because it couldn't find the tld data. Review URL: http://codereview.chromium.org/28194 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10494 0039d316-1c4b-4281-b951-d872f2087c98
* Enable the .pak files on mac builds also.thomasvl@chromium.org2009-02-261-2/+3
| | | | | | Review URL: http://codereview.chromium.org/27153 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10446 0039d316-1c4b-4281-b951-d872f2087c98
* Allow grit to run in parallel with scons by forking child processestc@google.com2009-02-251-4/+11
| | | | | | | | | for each grit builder. This speeds up the build a bit. Review URL: http://codereview.chromium.org/27118 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10401 0039d316-1c4b-4281-b951-d872f2087c98
* fix call to os.makedirstc@google.com2009-02-251-1/+1
| | | | | | | | | | | it's in the os module, not os.path. tbr=deanm Review URL: http://codereview.chromium.org/27114 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10312 0039d316-1c4b-4281-b951-d872f2087c98
* Final step in converting all grit includes to have grit in the path.tc@google.com2009-02-242-22/+5
| | | | | | | | | | | | Fixes some linux/mac issues that were pending and fix up the scons build to expect the file in the grit subdir. BUG=7537 Review URL: http://codereview.chromium.org/28035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10306 0039d316-1c4b-4281-b951-d872f2087c98
* Update include paths for grit files. Go ahead and resorttc@google.com2009-02-222-2/+2
| | | | | | | | the headers too. Review URL: http://codereview.chromium.org/21472 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10167 0039d316-1c4b-4281-b951-d872f2087c98
* step 1 on getting strings in linux: create a locale_settings.grdtc@google.com2009-02-182-5/+14
| | | | | | | | | | | | | | | | | | based on locale_settings_en-US.rc. We don't use this anywhere yet, just putting things in place. - Fix preprocessor defines in grit vcproj files (needs to be defined everywhere) and update grit_localized_resources.rules to pass the preprocessor define to grit. - Add generated .h files to chrome_strings.vcproj so people can ctrl+alt+a open them. - Update GRIT so it knows how to substitute [GRITLANGCODE] in strings to the locale value. Review URL: http://codereview.chromium.org/20440 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9922 0039d316-1c4b-4281-b951-d872f2087c98
* Another pass at fixing grit includesjoshia@google.com2009-02-171-1/+1
| | | | | | | | TBR=tony@chromium.org Review URL: http://codereview.chromium.org/20428 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9891 0039d316-1c4b-4281-b951-d872f2087c98
* Add relative include path for grit includesjoshia@google.com2009-02-171-1/+1
| | | | | | | | TBR=tony@chromium.org Review URL: http://codereview.chromium.org/20422 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9880 0039d316-1c4b-4281-b951-d872f2087c98
* Fix scons build for non-official builds.tc@google.com2009-02-121-0/+2
| | | | | | | | | | We were trying to include all resources, even those hidden behind an preprocessor #if. Review URL: http://codereview.chromium.org/20311 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9680 0039d316-1c4b-4281-b951-d872f2087c98
* Second try of landing chrome_resources project. Changes from last time:tc@google.com2009-02-124-2/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | - fix scons dependencies by adding a target for grit/theme_resources.h - fix mac build by adding grit to unittest include path - fix check deps by adding rules for /grit dir. Create a chrome_resources.vcproj that holds grd files that hold non-string resources. Put browser_resources.grd into this vcproj. Port theme_resources.rc/theme_resources.h to theme_resources.grd and put it in the vcproj too. I did a find/replace on the theme_resources include line. Modify grit so header files go in grit_generated_resources/grit/ so the include path can be cleaner. I'll migrate the others in follow up patches. theme_resources.rc had a conditional include of distribution_resources.rc so I had to add support for preprocessor defines to visual studio. Review URL: http://codereview.chromium.org/24011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9664 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Create a chrome_resources.vcproj that holds grd files that hold"tc@google.com2009-02-123-38/+2
| | | | | | | | | | This reverts commit r9631. TBR=deanm Review URL: http://codereview.chromium.org/23023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9634 0039d316-1c4b-4281-b951-d872f2087c98
* Create a chrome_resources.vcproj that holds grd files that holdtc@google.com2009-02-123-2/+38
| | | | | | | | | | | | | | | | | | | | | non-string resources. Put browser_resources.grd into this vcproj. Port theme_resources.rc/theme_resources.h to theme_resources.grd and put it in the vcproj too. I did a find/replace on the theme_resources include line. Modify grit so header files go in grit_generated_resources/grit/ so the include path can be cleaner. I'll migrate the others in follow up patches. theme_resources.rc had a conditional include of distribution_resources.rc so I had to add support for preprocessor defines to visual studio. Review URL: http://codereview.chromium.org/20247 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9631 0039d316-1c4b-4281-b951-d872f2087c98
* Only run one grit builder at a time under scons.tc@google.com2009-02-102-14/+4
| | | | | | | | | | | GRIT is not thread safe, we shouldn't be running multiple copies at one time. This is causing the header files to have duplicates when it shouldn't. I also removed some code in build.py which tried to prevent an identical regenerated header file from being used (so stuff doesn't rebuild unnecessarily). This code isn't necessary for our build since VS/xcode/scons handles the dependency for us (i.e., this isn't a blanket prebuild step). Review URL: http://codereview.chromium.org/21191 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9488 0039d316-1c4b-4281-b951-d872f2087c98
* Move browser_resources.rc into a a grd file. While I'm at it,tc@google.com2009-02-093-4/+133
| | | | | | | | | | | | I removed the flatten_html visual studio rule and just rolled the functionality directly into GRIT. The sln change is to have browser depend on browser_resources (now needed for browser_resources.h). Review URL: http://codereview.chromium.org/21148 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9418 0039d316-1c4b-4281-b951-d872f2087c98
* Add a Repack tool to scons. This is used to compile linux resourcestc@google.com2009-02-061-1/+1
| | | | | | | | | | | | together (kind of like the windows RES builder). I also moved the GRIT builder into the chromium site_scons since we import it in lots of places. This seems cleaner. Review URL: http://codereview.chromium.org/21115 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9331 0039d316-1c4b-4281-b951-d872f2087c98
* fix webkit hammer buildtc@google.com2009-02-051-1/+3
| | | | | | | | | TBR=evan Review URL: http://codereview.chromium.org/21108 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9275 0039d316-1c4b-4281-b951-d872f2087c98
* Some cleanup on the GRIT scons builder.tc@google.com2009-02-052-25/+41
| | | | | | | | | | | | | | - Cause the builder to have nicer output by removing a stray print in rc_header.py and adding a custom print function to the build action. - Fix the source scanner by hooking it up directly to the Builder, scanning for include dependencies and adding dependencies on the grit python source. Review URL: http://codereview.chromium.org/21102 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9271 0039d316-1c4b-4281-b951-d872f2087c98