webkitgtk/fix-installed-headers.patch
2023-03-08 14:06:21 -06:00

111 lines
4.8 KiB
Diff

From 53a8890833684fe813efd7b7a2b7417dbfa7b826 Mon Sep 17 00:00:00 2001
From: Adrian Perez de Castro <aperez@igalia.com>
Date: Wed, 8 Mar 2023 04:27:56 -0800
Subject: [PATCH] REGRESSION(261320@main): [GLib] Clean builds fail with
ENABLE_2022_GLIB_API https://bugs.webkit.org/show_bug.cgi?id=253563
Unreviewed build fix.
* Source/WebKit/UIProcess/API/glib/WebKitWebView.h.in: Guard the
inclusion of WebKitJavascriptResult.h with !ENABLE(2022_GLIB_API).
Canonical link: https://commits.webkit.org/261367@main
---
Source/WebKit/UIProcess/API/glib/WebKitWebView.h.in | 2 ++
1 file changed, 2 insertions(+)
diff --git a/Source/WebKit/UIProcess/API/glib/WebKitWebView.h.in b/Source/WebKit/UIProcess/API/glib/WebKitWebView.h.in
index cc60ef336afc..6f1afac40e2b 100644
--- a/Source/WebKit/UIProcess/API/glib/WebKitWebView.h.in
+++ b/Source/WebKit/UIProcess/API/glib/WebKitWebView.h.in
@@ -36,7 +36,9 @@
#include <@API_INCLUDE_PREFIX@/WebKitFormSubmissionRequest.h>
#include <@API_INCLUDE_PREFIX@/WebKitHitTestResult.h>
#include <@API_INCLUDE_PREFIX@/WebKitInputMethodContext.h>
+#if !ENABLE(2022_GLIB_API)
#include <@API_INCLUDE_PREFIX@/WebKitJavascriptResult.h>
+#endif
#include <@API_INCLUDE_PREFIX@/WebKitNavigationAction.h>
#include <@API_INCLUDE_PREFIX@/WebKitNotification.h>
#include <@API_INCLUDE_PREFIX@/WebKitOptionMenu.h>
From 10c9256883bf38b9fbcfbc91577783d4df90d1bd Mon Sep 17 00:00:00 2001
From: Adrian Perez de Castro <aperez@igalia.com>
Date: Wed, 8 Mar 2023 05:21:28 -0800
Subject: [PATCH] REGRESSION(261320@main): [GLib] Clean builds fail with
ENABLE_2022_GLIB_API https://bugs.webkit.org/show_bug.cgi?id=253563
Unreviewed build fix.
* Source/WebKit/UIProcess/API/glib/WebKitAutocleanups.h.in: Remove the
autocleanup for WebKitJavascriptResult when building with the new API.
* Source/WebKit/UIProcess/API/glib/WebKitUserContentManager.cpp:
Conditionally include WebKitJavascriptResultPrivate.h.
* Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp: Ditto.
Canonical link: https://commits.webkit.org/261368@main
---
Source/WebKit/UIProcess/API/glib/WebKitAutocleanups.h.in | 2 ++
.../WebKit/UIProcess/API/glib/WebKitUserContentManager.cpp | 5 ++++-
Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp | 3 ++-
3 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/Source/WebKit/UIProcess/API/glib/WebKitAutocleanups.h.in b/Source/WebKit/UIProcess/API/glib/WebKitAutocleanups.h.in
index b56fb3f302cc..f68ed748046f 100644
--- a/Source/WebKit/UIProcess/API/glib/WebKitAutocleanups.h.in
+++ b/Source/WebKit/UIProcess/API/glib/WebKitAutocleanups.h.in
@@ -87,7 +87,9 @@ G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitApplicationInfo, webkit_application_info_un
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitCredential, webkit_credential_free)
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitITPFirstParty, webkit_itp_first_party_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitITPThirdParty, webkit_itp_third_party_unref)
+#if !ENABLE(2022_GLIB_API)
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitJavascriptResult, webkit_javascript_result_unref)
+#endif
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitMemoryPressureSettings, webkit_memory_pressure_settings_free)
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitNavigationAction, webkit_navigation_action_free)
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WebKitNetworkProxySettings, webkit_network_proxy_settings_free)
diff --git a/Source/WebKit/UIProcess/API/glib/WebKitUserContentManager.cpp b/Source/WebKit/UIProcess/API/glib/WebKitUserContentManager.cpp
index 39a57d194c0d..af2d963bb3b3 100644
--- a/Source/WebKit/UIProcess/API/glib/WebKitUserContentManager.cpp
+++ b/Source/WebKit/UIProcess/API/glib/WebKitUserContentManager.cpp
@@ -23,7 +23,6 @@
#include "APISerializedScriptValue.h"
#include "InjectUserScriptImmediately.h"
#include "WebKitInitialize.h"
-#include "WebKitJavascriptResultPrivate.h"
#include "WebKitUserContentManagerPrivate.h"
#include "WebKitUserContentPrivate.h"
#include "WebKitWebContextPrivate.h"
@@ -32,6 +31,10 @@
#include <wtf/glib/GRefPtr.h>
#include <wtf/glib/WTFGType.h>
+#if !ENABLE(2022_GLIB_API)
+#include "WebKitJavascriptResultPrivate.h"
+#endif
+
#if PLATFORM(WPE)
#include "WPEView.h"
#endif
diff --git a/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp b/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp
index 1b3b6273bd14..837aa061fcab 100644
--- a/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp
+++ b/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp
@@ -46,7 +46,6 @@
#include "WebKitHitTestResultPrivate.h"
#include "WebKitIconLoadingClient.h"
#include "WebKitInputMethodContextPrivate.h"
-#include "WebKitJavascriptResultPrivate.h"
#include "WebKitNavigationClient.h"
#include "WebKitNotificationPrivate.h"
#include "WebKitPermissionStateQueryPrivate.h"
@@ -106,6 +105,8 @@
#if ENABLE(2022_GLIB_API)
#include "WebKitNetworkSessionPrivate.h"
+#else
+#include "WebKitJavascriptResultPrivate.h"
#endif
using namespace WebKit;