build: [gn] COMPONENT_EXPORT some pepper flash classes (#664)
* build: [gn] COMPONENT_EXPORT some pepper flash classes * build: [gyp] convert pepper_flash target into a component
This commit is contained in:
Родитель
99c3a9966a
Коммит
5db50d4918
|
@ -434,7 +434,8 @@ if (is_electron_build && !is_component_build) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static_library("pepper_flash") {
|
component("pepper_flash") {
|
||||||
|
defines = [ "IS_PEPPER_FLASH_IMPL" ]
|
||||||
sources = [
|
sources = [
|
||||||
"//chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.cc",
|
"//chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.cc",
|
||||||
"//chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.h",
|
"//chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.h",
|
||||||
|
@ -466,6 +467,8 @@ static_library("pepper_flash") {
|
||||||
"//chrome/renderer/pepper/pepper_shared_memory_message_filter.h",
|
"//chrome/renderer/pepper/pepper_shared_memory_message_filter.h",
|
||||||
]
|
]
|
||||||
deps = [
|
deps = [
|
||||||
|
"//content/public/browser",
|
||||||
|
"//content/public/renderer",
|
||||||
"//media:media_features",
|
"//media:media_features",
|
||||||
"//ppapi/host",
|
"//ppapi/host",
|
||||||
"//ppapi/proxy",
|
"//ppapi/proxy",
|
||||||
|
@ -474,7 +477,7 @@ static_library("pepper_flash") {
|
||||||
"//services/device/public/mojom",
|
"//services/device/public/mojom",
|
||||||
"//skia",
|
"//skia",
|
||||||
"//third_party/adobe/flash:flapper_version_h",
|
"//third_party/adobe/flash:flapper_version_h",
|
||||||
"//third_party/WebKit/public:blink",
|
"//ui/base",
|
||||||
]
|
]
|
||||||
if (is_mac) {
|
if (is_mac) {
|
||||||
sources += [
|
sources += [
|
||||||
|
|
|
@ -29,6 +29,28 @@ index a5ea92f28784..5fd8f4525f83 100644
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
diff --git a/chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.h b/chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.h
|
||||||
|
index 735da93c3cab..533f53fbc423 100644
|
||||||
|
--- a/chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.h
|
||||||
|
+++ b/chrome/browser/renderer_host/pepper/chrome_browser_pepper_host_factory.h
|
||||||
|
@@ -5,6 +5,7 @@
|
||||||
|
#ifndef CHROME_BROWSER_RENDERER_HOST_PEPPER_CHROME_BROWSER_PEPPER_HOST_FACTORY_H_
|
||||||
|
#define CHROME_BROWSER_RENDERER_HOST_PEPPER_CHROME_BROWSER_PEPPER_HOST_FACTORY_H_
|
||||||
|
|
||||||
|
+#include "base/component_export.h"
|
||||||
|
#include "base/macros.h"
|
||||||
|
#include "ppapi/host/host_factory.h"
|
||||||
|
|
||||||
|
@@ -12,7 +13,8 @@ namespace content {
|
||||||
|
class BrowserPpapiHost;
|
||||||
|
} // namespace content
|
||||||
|
|
||||||
|
-class ChromeBrowserPepperHostFactory : public ppapi::host::HostFactory {
|
||||||
|
+class COMPONENT_EXPORT(PEPPER_FLASH) ChromeBrowserPepperHostFactory
|
||||||
|
+ : public ppapi::host::HostFactory {
|
||||||
|
public:
|
||||||
|
// Non-owning pointer to the filter must outlive this class.
|
||||||
|
explicit ChromeBrowserPepperHostFactory(content::BrowserPpapiHost* host);
|
||||||
diff --git a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc b/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc
|
diff --git a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc b/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc
|
||||||
index f4f1741a8ecf..103238cdd53f 100644
|
index f4f1741a8ecf..103238cdd53f 100644
|
||||||
--- a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc
|
--- a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc
|
||||||
|
@ -449,3 +471,23 @@ index 66a532e2cb41..e776d0e96c4a 100644
|
||||||
+#endif
|
+#endif
|
||||||
+ return PP_ERROR_FAILED;
|
+ return PP_ERROR_FAILED;
|
||||||
}
|
}
|
||||||
|
diff --git a/chrome/renderer/pepper/pepper_helper.h b/chrome/renderer/pepper/pepper_helper.h
|
||||||
|
index e021c964da3d..e035f0fb9e2b 100644
|
||||||
|
--- a/chrome/renderer/pepper/pepper_helper.h
|
||||||
|
+++ b/chrome/renderer/pepper/pepper_helper.h
|
||||||
|
@@ -6,12 +6,14 @@
|
||||||
|
#define CHROME_RENDERER_PEPPER_PEPPER_HELPER_H_
|
||||||
|
|
||||||
|
#include "base/compiler_specific.h"
|
||||||
|
+#include "base/component_export.h"
|
||||||
|
#include "base/macros.h"
|
||||||
|
#include "content/public/renderer/render_frame_observer.h"
|
||||||
|
|
||||||
|
// This class listens for Pepper creation events from the RenderFrame and
|
||||||
|
// attaches the parts required for Chrome-specific plugin support.
|
||||||
|
-class PepperHelper : public content::RenderFrameObserver {
|
||||||
|
+class COMPONENT_EXPORT(PEPPER_FLASH) PepperHelper
|
||||||
|
+ : public content::RenderFrameObserver {
|
||||||
|
public:
|
||||||
|
explicit PepperHelper(content::RenderFrame* render_frame);
|
||||||
|
~PepperHelper() override;
|
||||||
|
|
|
@ -26,9 +26,11 @@ STATIC_LIBRARY_SUFFIX = {
|
||||||
|
|
||||||
EXCLUDE_SHARED_LIBRARIES = {
|
EXCLUDE_SHARED_LIBRARIES = {
|
||||||
'darwin': [
|
'darwin': [
|
||||||
|
'libpepper_flash.dylib',
|
||||||
'libwidevinecdm.dylib',
|
'libwidevinecdm.dylib',
|
||||||
],
|
],
|
||||||
'linux': [
|
'linux': [
|
||||||
|
'libpepper_flash.so',
|
||||||
'libwidevinecdm.so',
|
'libwidevinecdm.so',
|
||||||
'libwidevinecdmadapter.so',
|
'libwidevinecdmadapter.so',
|
||||||
],
|
],
|
||||||
|
@ -36,6 +38,7 @@ EXCLUDE_SHARED_LIBRARIES = {
|
||||||
'd3dcompiler_47.dll',
|
'd3dcompiler_47.dll',
|
||||||
'libEGL.dll',
|
'libEGL.dll',
|
||||||
'libGLESv2.dll',
|
'libGLESv2.dll',
|
||||||
|
'pepper_flash.dll',
|
||||||
'widevinecdm.dll',
|
'widevinecdm.dll',
|
||||||
'widevinecdmadapter.dll',
|
'widevinecdmadapter.dll',
|
||||||
],
|
],
|
||||||
|
|
Загрузка…
Ссылка в новой задаче