summaryrefslogtreecommitdiffstats
path: root/ui/gfx/compositor
diff options
context:
space:
mode:
authorpkotwicz@chromium.org <pkotwicz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-06 19:01:48 +0000
committerpkotwicz@chromium.org <pkotwicz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-06 19:01:48 +0000
commite73bbf9e346e9c150ba7dedfdadf3eca77f967d9 (patch)
tree0ce497f8e580d9f4f703c7485c7ed106fc479d75 /ui/gfx/compositor
parent99faed6540a94dd926fa287ad5a1510d75b2a1ff (diff)
downloadchromium_src-e73bbf9e346e9c150ba7dedfdadf3eca77f967d9.zip
chromium_src-e73bbf9e346e9c150ba7dedfdadf3eca77f967d9.tar.gz
chromium_src-e73bbf9e346e9c150ba7dedfdadf3eca77f967d9.tar.bz2
Adds command line switch such that compositor_unittests use osmesa by default.
BUG= TEST= Review URL: http://codereview.chromium.org/8138009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@104340 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/gfx/compositor')
-rw-r--r--ui/gfx/compositor/compositor.gyp6
-rw-r--r--ui/gfx/compositor/test_suite.cc4
2 files changed, 10 insertions, 0 deletions
diff --git a/ui/gfx/compositor/compositor.gyp b/ui/gfx/compositor/compositor.gyp
index c605f7e..d5e38b7 100644
--- a/ui/gfx/compositor/compositor.gyp
+++ b/ui/gfx/compositor/compositor.gyp
@@ -109,6 +109,12 @@
'<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources/ui_resources.rc',
],
'conditions': [
+ # osmesa GL implementation is used on linux.
+ ['OS=="linux"', {
+ 'dependencies': [
+ '<(DEPTH)/third_party/mesa/mesa.gyp:osmesa',
+ ],
+ }],
['OS!="mac"', {
'dependencies': [
'<(DEPTH)/chrome/chrome.gyp:packed_resources',
diff --git a/ui/gfx/compositor/test_suite.cc b/ui/gfx/compositor/test_suite.cc
index 967709a..f26cd31 100644
--- a/ui/gfx/compositor/test_suite.cc
+++ b/ui/gfx/compositor/test_suite.cc
@@ -7,11 +7,15 @@
#include "ui/base/resource/resource_bundle.h"
#include "ui/base/ui_base_paths.h"
#include "ui/gfx/gfx_paths.h"
+#include "ui/gfx/gl/gl_implementation.h"
CompositorTestSuite::CompositorTestSuite(int argc, char** argv)
: TestSuite(argc, argv) {}
void CompositorTestSuite::Initialize() {
+#if defined(OS_LINUX)
+ gfx::InitializeGLBindings(gfx::kGLImplementationOSMesaGL);
+#endif
base::TestSuite::Initialize();
gfx::RegisterPathProvider();