Commit 55033e58 by Yuly Novikov Committed by Jamie Madill

Revert "Change angle_util to be a shared library"

This reverts commit 2f9b5e6f. Change-Id: I90a7ba0596e79795c9549bc268eabff69c96d572 Reviewed-on: https://chromium-review.googlesource.com/376079Reviewed-by: 's avatarYuly Novikov <ynovikov@chromium.org> Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
parent 0ea0caeb
...@@ -497,7 +497,7 @@ config("angle_util_config") { ...@@ -497,7 +497,7 @@ config("angle_util_config") {
} }
} }
shared_library("angle_util") { static_library("angle_util") {
sources = rebase_path(util_gypi.util_sources, ".", "util") sources = rebase_path(util_gypi.util_sources, ".", "util")
if (is_win) { if (is_win) {
...@@ -514,10 +514,6 @@ shared_library("angle_util") { ...@@ -514,10 +514,6 @@ shared_library("angle_util") {
if (is_mac) { if (is_mac) {
sources += rebase_path(util_gypi.util_osx_sources, ".", "util") sources += rebase_path(util_gypi.util_osx_sources, ".", "util")
libs = [
"AppKit.framework",
"QuartzCore.framework",
]
} }
if (use_x11) { if (use_x11) {
...@@ -542,7 +538,6 @@ shared_library("angle_util") { ...@@ -542,7 +538,6 @@ shared_library("angle_util") {
defines = [ defines = [
"GL_GLEXT_PROTOTYPES", "GL_GLEXT_PROTOTYPES",
"EGL_EGLEXT_PROTOTYPES", "EGL_EGLEXT_PROTOTYPES",
"LIBANGLE_UTIL_IMPLEMENTATION",
] ]
configs += [ configs += [
......
...@@ -10,15 +10,13 @@ ...@@ -10,15 +10,13 @@
#define LIBGLESV2_EXPORT_H_ #define LIBGLESV2_EXPORT_H_
#if defined(_WIN32) #if defined(_WIN32)
#if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION) || \ # if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION)
defined(LIBANGLE_UTIL_IMPLEMENTATION)
# define ANGLE_EXPORT __declspec(dllexport) # define ANGLE_EXPORT __declspec(dllexport)
# else # else
# define ANGLE_EXPORT __declspec(dllimport) # define ANGLE_EXPORT __declspec(dllimport)
# endif # endif
#elif defined(__GNUC__) #elif defined(__GNUC__)
#if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION) || \ # if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION)
defined(LIBANGLE_UTIL_IMPLEMENTATION)
# define ANGLE_EXPORT __attribute__((visibility ("default"))) # define ANGLE_EXPORT __attribute__((visibility ("default")))
# else # else
# define ANGLE_EXPORT # define ANGLE_EXPORT
......
...@@ -303,7 +303,6 @@ if (build_angle_deqp_tests) { ...@@ -303,7 +303,6 @@ if (build_angle_deqp_tests) {
shared_library(shared_library_name) { shared_library(shared_library_name) {
deps = [ deps = [
":angle_deqp_libtester", ":angle_deqp_libtester",
"//third_party/angle:angle_util",
] ]
configs -= deqp_undefine_configs configs -= deqp_undefine_configs
......
...@@ -12,7 +12,6 @@ ...@@ -12,7 +12,6 @@
#include <stdint.h> #include <stdint.h>
#include <string> #include <string>
#include <export.h>
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
#include <GLES2/gl2ext.h> #include <GLES2/gl2ext.h>
#include <GLES3/gl3.h> #include <GLES3/gl3.h>
...@@ -29,7 +28,7 @@ class OSWindow; ...@@ -29,7 +28,7 @@ class OSWindow;
#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_NULL_ANGLE 0x6AC0 #define EGL_PLATFORM_ANGLE_DEVICE_TYPE_NULL_ANGLE 0x6AC0
#endif #endif
struct ANGLE_EXPORT EGLPlatformParameters struct EGLPlatformParameters
{ {
EGLint renderer; EGLint renderer;
EGLint majorVersion; EGLint majorVersion;
...@@ -47,10 +46,10 @@ struct ANGLE_EXPORT EGLPlatformParameters ...@@ -47,10 +46,10 @@ struct ANGLE_EXPORT EGLPlatformParameters
EGLint presentPath); EGLint presentPath);
}; };
ANGLE_EXPORT bool operator<(const EGLPlatformParameters &a, const EGLPlatformParameters &b); bool operator<(const EGLPlatformParameters &a, const EGLPlatformParameters &b);
ANGLE_EXPORT bool operator==(const EGLPlatformParameters &a, const EGLPlatformParameters &b); bool operator==(const EGLPlatformParameters &a, const EGLPlatformParameters &b);
class ANGLE_EXPORT EGLWindow : angle::NonCopyable class EGLWindow : angle::NonCopyable
{ {
public: public:
EGLWindow(EGLint glesMajorVersion, EGLWindow(EGLint glesMajorVersion,
......
...@@ -10,11 +10,9 @@ ...@@ -10,11 +10,9 @@
#ifndef UTIL_MATRIX_H #ifndef UTIL_MATRIX_H
#define UTIL_MATRIX_H #define UTIL_MATRIX_H
#include <export.h>
#include "Vector.h" #include "Vector.h"
struct ANGLE_EXPORT Matrix4 struct Matrix4
{ {
float data[16]; float data[16];
...@@ -51,13 +49,13 @@ struct ANGLE_EXPORT Matrix4 ...@@ -51,13 +49,13 @@ struct ANGLE_EXPORT Matrix4
static Vector3 transform(const Matrix4 &mat, const Vector4 &pt); static Vector3 transform(const Matrix4 &mat, const Vector4 &pt);
}; };
ANGLE_EXPORT Matrix4 operator*(const Matrix4 &a, const Matrix4 &b); Matrix4 operator*(const Matrix4 &a, const Matrix4 &b);
ANGLE_EXPORT Matrix4 &operator*=(Matrix4 &a, const Matrix4 &b); Matrix4 &operator*=(Matrix4 &a, const Matrix4 &b);
ANGLE_EXPORT Matrix4 operator*(const Matrix4 &a, float b); Matrix4 operator*(const Matrix4 &a, float b);
ANGLE_EXPORT Matrix4 &operator*=(Matrix4 &a, float b); Matrix4 &operator*=(Matrix4 &a, float b);
ANGLE_EXPORT Vector4 operator*(const Matrix4 &a, const Vector4 &b); Vector4 operator*(const Matrix4 &a, const Vector4 &b);
ANGLE_EXPORT bool operator==(const Matrix4 &a, const Matrix4 &b); bool operator==(const Matrix4 &a, const Matrix4 &b);
ANGLE_EXPORT bool operator!=(const Matrix4 &a, const Matrix4 &b); bool operator!=(const Matrix4 &a, const Matrix4 &b);
#endif // UTIL_MATRIX_H #endif // UTIL_MATRIX_H
...@@ -11,13 +11,12 @@ ...@@ -11,13 +11,12 @@
#include <stdlib.h> #include <stdlib.h>
#include <export.h>
#include <EGL/egl.h> #include <EGL/egl.h>
#include <EGL/eglext.h> #include <EGL/eglext.h>
#include "Event.h" #include "Event.h"
class ANGLE_EXPORT OSPixmap class OSPixmap
{ {
public: public:
OSPixmap() {} OSPixmap() {}
...@@ -28,6 +27,6 @@ class ANGLE_EXPORT OSPixmap ...@@ -28,6 +27,6 @@ class ANGLE_EXPORT OSPixmap
virtual EGLNativePixmapType getNativePixmap() const = 0; virtual EGLNativePixmapType getNativePixmap() const = 0;
}; };
ANGLE_EXPORT OSPixmap *CreateOSPixmap(); OSPixmap *CreateOSPixmap();
#endif // SAMPLE_UTIL_PIXMAP_H_ #endif // SAMPLE_UTIL_PIXMAP_H_
...@@ -11,13 +11,12 @@ ...@@ -11,13 +11,12 @@
#include <stdint.h> #include <stdint.h>
#include <string> #include <string>
#include <export.h>
#include <EGL/egl.h> #include <EGL/egl.h>
#include <EGL/eglext.h> #include <EGL/eglext.h>
#include "Event.h" #include "Event.h"
class ANGLE_EXPORT OSWindow class OSWindow
{ {
public: public:
OSWindow(); OSWindow();
...@@ -64,6 +63,6 @@ class ANGLE_EXPORT OSWindow ...@@ -64,6 +63,6 @@ class ANGLE_EXPORT OSWindow
std::list<Event> mEvents; std::list<Event> mEvents;
}; };
ANGLE_EXPORT OSWindow *CreateOSWindow(); OSWindow *CreateOSWindow();
#endif // SAMPLE_UTIL_WINDOW_H #endif // SAMPLE_UTIL_WINDOW_H
...@@ -7,9 +7,7 @@ ...@@ -7,9 +7,7 @@
#ifndef SAMPLE_UTIL_TIMER_H #ifndef SAMPLE_UTIL_TIMER_H
#define SAMPLE_UTIL_TIMER_H #define SAMPLE_UTIL_TIMER_H
#include <export.h> class Timer
class ANGLE_EXPORT Timer
{ {
public: public:
virtual ~Timer() {} virtual ~Timer() {}
...@@ -18,6 +16,6 @@ class ANGLE_EXPORT Timer ...@@ -18,6 +16,6 @@ class ANGLE_EXPORT Timer
virtual double getElapsedTime() const = 0; virtual double getElapsedTime() const = 0;
}; };
ANGLE_EXPORT Timer *CreateTimer(); Timer *CreateTimer();
#endif // SAMPLE_UTIL_TIMER_H #endif // SAMPLE_UTIL_TIMER_H
...@@ -12,9 +12,7 @@ ...@@ -12,9 +12,7 @@
#include <ostream> #include <ostream>
#include <export.h> struct Vector2
struct ANGLE_EXPORT Vector2
{ {
Vector2(); Vector2();
Vector2(float x, float y); Vector2(float x, float y);
...@@ -33,9 +31,9 @@ struct ANGLE_EXPORT Vector2 ...@@ -33,9 +31,9 @@ struct ANGLE_EXPORT Vector2
float x, y; float x, y;
}; };
ANGLE_EXPORT std::ostream &operator<<(std::ostream &stream, const Vector2 &vec); std::ostream &operator<<(std::ostream &stream, const Vector2 &vec);
struct ANGLE_EXPORT Vector3 struct Vector3
{ {
Vector3(); Vector3();
Vector3(float x, float y, float z); Vector3(float x, float y, float z);
...@@ -54,14 +52,14 @@ struct ANGLE_EXPORT Vector3 ...@@ -54,14 +52,14 @@ struct ANGLE_EXPORT Vector3
float x, y, z; float x, y, z;
}; };
ANGLE_EXPORT Vector3 operator*(const Vector3 &a, const Vector3 &b); Vector3 operator*(const Vector3 &a, const Vector3 &b);
ANGLE_EXPORT Vector3 operator*(const Vector3 &a, const float &b); Vector3 operator*(const Vector3 &a, const float &b);
ANGLE_EXPORT Vector3 operator/(const Vector3 &a, const Vector3 &b); Vector3 operator/(const Vector3 &a, const Vector3 &b);
ANGLE_EXPORT Vector3 operator/(const Vector3 &a, const float &b); Vector3 operator/(const Vector3 &a, const float &b);
ANGLE_EXPORT Vector3 operator+(const Vector3 &a, const Vector3 &b); Vector3 operator+(const Vector3 &a, const Vector3 &b);
ANGLE_EXPORT Vector3 operator-(const Vector3 &a, const Vector3 &b); Vector3 operator-(const Vector3 &a, const Vector3 &b);
struct ANGLE_EXPORT Vector4 struct Vector4
{ {
Vector4(); Vector4();
Vector4(float x, float y, float z, float w); Vector4(float x, float y, float z, float w);
......
...@@ -13,12 +13,10 @@ ...@@ -13,12 +13,10 @@
// TODO(jmadill): Rework this if Chromium decides to ban <random> // TODO(jmadill): Rework this if Chromium decides to ban <random>
#include <random> #include <random>
#include <export.h>
namespace angle namespace angle
{ {
class ANGLE_EXPORT RNG class RNG
{ {
public: public:
// Seed from clock // Seed from clock
......
...@@ -7,7 +7,6 @@ ...@@ -7,7 +7,6 @@
#ifndef SAMPLE_UTIL_SHADER_UTILS_H #ifndef SAMPLE_UTIL_SHADER_UTILS_H
#define SAMPLE_UTIL_SHADER_UTILS_H #define SAMPLE_UTIL_SHADER_UTILS_H
#include <export.h>
#include <GLES3/gl3.h> #include <GLES3/gl3.h>
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
#include <GLES2/gl2ext.h> #include <GLES2/gl2ext.h>
...@@ -19,15 +18,15 @@ ...@@ -19,15 +18,15 @@
#define SHADER_SOURCE(...) #__VA_ARGS__ #define SHADER_SOURCE(...) #__VA_ARGS__
ANGLE_EXPORT GLuint CompileShader(GLenum type, const std::string &source); GLuint CompileShader(GLenum type, const std::string &source);
ANGLE_EXPORT GLuint CompileShaderFromFile(GLenum type, const std::string &sourcePath); GLuint CompileShaderFromFile(GLenum type, const std::string &sourcePath);
ANGLE_EXPORT GLuint GLuint CompileProgramWithTransformFeedback(
CompileProgramWithTransformFeedback(const std::string &vsSource, const std::string &vsSource,
const std::string &fsSource, const std::string &fsSource,
const std::vector<std::string> &transformFeedbackVaryings, const std::vector<std::string> &transformFeedbackVaryings,
GLenum bufferMode); GLenum bufferMode);
ANGLE_EXPORT GLuint CompileProgram(const std::string &vsSource, const std::string &fsSource); GLuint CompileProgram(const std::string &vsSource, const std::string &fsSource);
ANGLE_EXPORT GLuint CompileProgramFromFiles(const std::string &vsPath, const std::string &fsPath); GLuint CompileProgramFromFiles(const std::string &vsPath, const std::string &fsPath);
#endif // SAMPLE_UTIL_SHADER_UTILS_H #endif // SAMPLE_UTIL_SHADER_UTILS_H
...@@ -11,33 +11,31 @@ ...@@ -11,33 +11,31 @@
#include <string> #include <string>
#include <export.h>
#include "common/angleutils.h" #include "common/angleutils.h"
namespace angle namespace angle
{ {
ANGLE_EXPORT std::string GetExecutablePath(); std::string GetExecutablePath();
ANGLE_EXPORT std::string GetExecutableDirectory(); std::string GetExecutableDirectory();
ANGLE_EXPORT std::string GetSharedLibraryExtension(); std::string GetSharedLibraryExtension();
// Cross platform equivalent of the Windows Sleep function // Cross platform equivalent of the Windows Sleep function
ANGLE_EXPORT void Sleep(unsigned int milliseconds); void Sleep(unsigned int milliseconds);
ANGLE_EXPORT void SetLowPriorityProcess(); void SetLowPriorityProcess();
// Write a debug message, either to a standard output or Debug window. // Write a debug message, either to a standard output or Debug window.
ANGLE_EXPORT void WriteDebugMessage(const char *format, ...); void WriteDebugMessage(const char *format, ...);
class ANGLE_EXPORT Library : angle::NonCopyable class Library : angle::NonCopyable
{ {
public: public:
virtual ~Library() {} virtual ~Library() {}
virtual void *getSymbol(const std::string &symbolName) = 0; virtual void *getSymbol(const std::string &symbolName) = 0;
}; };
ANGLE_EXPORT Library *loadLibrary(const std::string &libraryName); Library *loadLibrary(const std::string &libraryName);
} // namespace angle } // namespace angle
......
...@@ -14,11 +14,9 @@ ...@@ -14,11 +14,9 @@
#include <X11/Xutil.h> #include <X11/Xutil.h>
#include <X11/Xresource.h> #include <X11/Xresource.h>
#include <export.h>
#include "OSWindow.h" #include "OSWindow.h"
class ANGLE_EXPORT X11Window : public OSWindow class X11Window : public OSWindow
{ {
public: public:
X11Window(); X11Window();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment