Bug 223067

Summary: [GTK] Bump API version when building with libsoup3
Product: WebKit Reporter: Carlos Garcia Campos <cgarcia>
Component: WebKitGTKAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: annulen, aperez, bugs-noreply, ews-watchlist, gyuyoung.kim, keith_miller, mark.lam, msaboff, pnormand, ryuan.choi, saam, sergio, tzagallo
Priority: P2    
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 220508    
Attachments:
Description Flags
Patch aperez: review+

Description Carlos Garcia Campos 2021-03-11 05:57:01 PST
Use 4.1 for soup3, since the API hasn't actually changed and keep using 5.0 for GTK4 where the API will change.
Comment 1 Carlos Garcia Campos 2021-03-11 06:03:41 PST
Created attachment 422926 [details]
Patch
Comment 2 Adrian Perez 2021-03-11 09:20:51 PST
Comment on attachment 422926 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=422926&action=review

> Source/cmake/OptionsGTK.cmake:221
> +    set(WEBKITGTK_API_DOC_VERSION 4.0)

We are going to need something similar for the WPE port when building
with libsoup3, but let's do it in a separate patch.
Comment 3 Carlos Garcia Campos 2021-03-12 01:33:03 PST
Committed r274330 (235218@main): <https://commits.webkit.org/235218@main>
Comment 4 Philippe Normand 2021-03-12 04:16:38 PST
Comment on attachment 422926 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=422926&action=review

> Source/cmake/OptionsGTK.cmake:70
> +WEBKIT_OPTION_DEFINE(ENABLE_QUARTZ_TARGET "Whether to enable support for the Quartz windowing target." PUBLIC ON)

Why is this unconditionally enabled now?
Comment 5 Carlos Garcia Campos 2021-03-12 04:44:53 PST
Comment on attachment 422926 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=422926&action=review

>> Source/cmake/OptionsGTK.cmake:70
>> +WEBKIT_OPTION_DEFINE(ENABLE_QUARTZ_TARGET "Whether to enable support for the Quartz windowing target." PUBLIC ON)
> 
> Why is this unconditionally enabled now?

Because we don't have GTK_SUPPORTS_QUARTZ yet here. The GTK4 was wrong, we can't use build variables before WEBKIT_OPTION_END(). So I moved the find_package for GTK after that to check what gtk version to check for. So, targets options and enabled by default, but disabled below if GTK doesn't support them.