summaryrefslogtreecommitdiffstats
path: root/mojo/gles2/export.h
diff options
context:
space:
mode:
authorabarth@chromium.org <abarth@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-11 22:23:49 +0000
committerabarth@chromium.org <abarth@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-11 22:23:49 +0000
commite161119d3ec2049e25732b59331053fc7855f13b (patch)
tree73b24afb97b34fabdef89d19a3b1e6d9667c4096 /mojo/gles2/export.h
parent9317c24980c39f7134a7a9dbe4ea0cea6ffc9ade (diff)
downloadchromium_src-e161119d3ec2049e25732b59331053fc7855f13b.zip
chromium_src-e161119d3ec2049e25732b59331053fc7855f13b.tar.gz
chromium_src-e161119d3ec2049e25732b59331053fc7855f13b.tar.bz2
Make mojo_gles2 work properly in the static build
This CL changes the public mojo_gles2 library to follow the same pattern as the public mojo_system library. Now the dynamic library is jump a trampoline back into mojo_gles2_impl, which is currently linked into mojo_shell. If we end up execing a sub executable in the child process, we'll need to link mojo_gles2_impl into the stub. R=viettrungluu@chromium.org Review URL: https://codereview.chromium.org/106863005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240195 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'mojo/gles2/export.h')
-rw-r--r--mojo/gles2/export.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/mojo/gles2/export.h b/mojo/gles2/export.h
new file mode 100644
index 0000000..bf58015
--- /dev/null
+++ b/mojo/gles2/export.h
@@ -0,0 +1,29 @@
+// Copyright 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef MOJO_GLES2_EXPORT_H_
+#define MOJO_GLES2_EXPORT_H_
+
+#if defined(COMPONENT_BUILD)
+#if defined(WIN32)
+
+#if defined(MOJO_GLES2_IMPL_IMPLEMENTATION)
+#define MOJO_GLES2_IMPL_EXPORT __declspec(dllexport)
+#else
+#define MOJO_GLES2_IMPL_EXPORT __declspec(dllimport)
+#endif // defined(MOJO_GLES2_IMPL_IMPLEMENTATION)
+
+#else // defined(WIN32)
+#if defined(MOJO_GLES2_IMPL_IMPLEMENTATION)
+#define MOJO_GLES2_IMPL_EXPORT __attribute__((visibility("default")))
+#else
+#define MOJO_GLES2_IMPL_EXPORT
+#endif
+#endif
+
+#else // defined(COMPONENT_BUILD)
+#define MOJO_GLES2_IMPL_EXPORT
+#endif
+
+#endif // MOJO_GLES2_EXPORT_H_