Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(548)

Unified Diff: ui/base/ozone/ozone.gyp

Issue 44053005: Implement --ozone-platform flag to select OzonePlatform implementation at runtime (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove obsolete CreateDefaultOzonePlatform() prototype Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/base/ozone/ozone.gyp
diff --git a/ui/base/ozone/ozone.gyp b/ui/base/ozone/ozone.gyp
index 19c466bb0b12b5bfaad2769dc9847fe5480151fb..008e4eb90d0a3a161ccd23829dffeb73f9059f2c 100644
--- a/ui/base/ozone/ozone.gyp
+++ b/ui/base/ozone/ozone.gyp
@@ -21,7 +21,11 @@
'defines': [
'OZONE_IMPLEMENTATION',
],
+ 'variables': {
+ 'platform_list_file': '<(SHARED_INTERMEDIATE_DIR)/ui/base/ozone/ozone_platform_list.cc',
+ },
'sources': [
+ '<(platform_list_file)',
'ozone_platform.cc',
'ozone_platform.h',
'ozone_switches.cc',
@@ -32,13 +36,46 @@
'platform/test/ozone_platform_test.h',
'<@(external_ozone_platform_files)',
],
+ 'actions': [
+ {
+ 'action_name': 'generate_ozone_platform_list',
+ 'variables': {
+ 'generator_path': 'generate_ozone_platform_list.py',
+ },
+ 'inputs': [
+ '<(generator_path)',
+ ],
+ 'outputs': [
+ '<(platform_list_file)',
+ ],
+ 'action': [
+ 'python',
+ '<(generator_path)',
+ '--output_file=<(platform_list_file)',
+ '--default=<(ozone_platform)',
+ '<@(ozone_platforms)',
+ ],
+ },
+ ],
'conditions': [
- ['ozone_platform != "dri"', {
+ ['<(ozone_platform_dri)==1', {
+ 'variables': {
+ 'ozone_platforms': [
+ 'dri'
+ ]
+ }
+ }, { # ozone_platform_dri==0
kalyank 2013/10/25 21:09:30 If ozone is enabled, we always enable ozone_platfo
spang 2013/10/25 21:14:14 Yes, because everything from common.gypi is a defa
'sources/': [
['exclude', '^platform/dri/'],
]
}],
- ['ozone_platform != "test"', {
+ ['<(ozone_platform_test)==1', {
+ 'variables': {
+ 'ozone_platforms': [
+ 'test'
+ ],
+ }
+ }, { # ozone_platform_test==0
'sources/': [
['exclude', '^platform/test/'],
]

Powered by Google App Engine
This is Rietveld 408576698