summaryrefslogtreecommitdiffstats
path: root/chrome/chrome_common.gypi
diff options
context:
space:
mode:
authorevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-23 18:59:09 +0000
committerevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-23 18:59:09 +0000
commit9d87da0351d34bfe0dedb8f4c569ed1d347bb77e (patch)
treec5ead39cbbf58177cb1147d32f6c187e1df28427 /chrome/chrome_common.gypi
parente1fcf1482fd306b7e404ed037106801840deda76 (diff)
downloadchromium_src-9d87da0351d34bfe0dedb8f4c569ed1d347bb77e.zip
chromium_src-9d87da0351d34bfe0dedb8f4c569ed1d347bb77e.tar.gz
chromium_src-9d87da0351d34bfe0dedb8f4c569ed1d347bb77e.tar.bz2
Move chrome_version_info target into chrome_common.
The source files live in chrome/common, and they're there because we need to get at version infomation all over the product (not just from the exe, like the gyp files are currently written). This refactoring is necessary for a follow-up change. TEST=compiles Review URL: http://codereview.chromium.org/3113026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@57084 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/chrome_common.gypi')
-rw-r--r--chrome/chrome_common.gypi63
1 files changed, 63 insertions, 0 deletions
diff --git a/chrome/chrome_common.gypi b/chrome/chrome_common.gypi
index 82d8bd4..cf08d07 100644
--- a/chrome/chrome_common.gypi
+++ b/chrome/chrome_common.gypi
@@ -122,6 +122,68 @@
},
'targets': [
{
+ 'target_name': 'chrome_version_info',
+ 'type': '<(library)',
+ 'sources': [
+ 'common/chrome_version_info.cc',
+ 'common/chrome_version_info.h',
+ ],
+ 'include_dirs': [
+ '<(DEPTH)',
+ ],
+ 'conditions': [
+ [ 'OS == "linux" or OS == "freebsd" or OS == "openbsd" or OS == "solaris"', {
+ 'include_dirs': [
+ '<(SHARED_INTERMEDIATE_DIR)',
+ ],
+ 'actions': [
+ {
+ 'action_name': 'posix_version',
+ 'variables': {
+ 'lastchange_path':
+ '<(SHARED_INTERMEDIATE_DIR)/build/LASTCHANGE',
+ 'version_py_path': 'tools/build/version.py',
+ 'version_path': 'VERSION',
+ 'template_input_path': 'common/chrome_version_info_posix.h.version',
+ },
+ 'conditions': [
+ [ 'branding == "Chrome"', {
+ 'variables': {
+ 'branding_path':
+ 'app/theme/google_chrome/BRANDING',
+ },
+ }, { # else branding!="Chrome"
+ 'variables': {
+ 'branding_path':
+ 'app/theme/chromium/BRANDING',
+ },
+ }],
+ ],
+ 'inputs': [
+ '<(template_input_path)',
+ '<(version_path)',
+ '<(branding_path)',
+ '<(lastchange_path)',
+ ],
+ 'outputs': [
+ '<(SHARED_INTERMEDIATE_DIR)/chrome/common/chrome_version_info_posix.h',
+ ],
+ 'action': [
+ 'python',
+ '<(version_py_path)',
+ '-f', '<(version_path)',
+ '-f', '<(branding_path)',
+ '-f', '<(lastchange_path)',
+ '<(template_input_path)',
+ '<@(_outputs)',
+ ],
+ 'message': 'Generating version information',
+ },
+ ],
+ }],
+ ]
+ },
+ {
'target_name': 'common',
'type': '<(library)',
'msvs_guid': '899F1280-3441-4D1F-BA04-CCD6208D9146',
@@ -143,6 +205,7 @@
'chrome_strings',
'common_constants',
'common_net',
+ 'chrome_version_info',
'default_plugin/default_plugin.gyp:default_plugin',
'theme_resources',
'../app/app.gyp:app_base',