Bug 221727 - [CMake] Bump cmake_minimum_required version to 3.12 or later
Summary: [CMake] Bump cmake_minimum_required version to 3.12 or later
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CMake (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Don Olmstead
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-02-10 16:24 PST by Don Olmstead
Modified: 2021-03-09 10:13 PST (History)
11 users (show)

See Also:


Attachments
Patch (2.26 KB, patch)
2021-03-05 07:19 PST, Don Olmstead
annulen: review-
don.olmstead: commit-queue+
Details | Formatted Diff | Diff
Patch (7.84 KB, patch)
2021-03-05 09:42 PST, Don Olmstead
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Don Olmstead 2021-02-10 16:24:18 PST
My understanding is Igalia can do this in April 2021.
Comment 1 Radar WebKit Bug Importer 2021-02-17 16:25:25 PST
<rdar://problem/74454980>
Comment 2 Don Olmstead 2021-03-05 07:19:02 PST
Created attachment 422370 [details]
Patch
Comment 3 Don Olmstead 2021-03-05 07:32:39 PST
Believe GTK has branched so this can potentially land.

This opens up GTK to build with hidden visibility turned on.
Comment 4 Adrian Perez 2021-03-05 08:34:38 PST
(In reply to Don Olmstead from comment #3)
> Believe GTK has branched so this can potentially land.

Yes, Carlos has created our 2.32.x release branch some days ago.

> This opens up GTK to build with hidden visibility turned on.

\o/
Comment 5 Konstantin Tokarev 2021-03-05 08:58:51 PST
Comment on attachment 422370 [details]
Patch

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

> CMakeLists.txt:9
> +cmake_minimum_required(VERSION 3.12)

cmake_minimum_required(VERSION 3.10) is also present in subprojects, such as Source/WTF/CMakeLists.txt
Comment 6 Don Olmstead 2021-03-05 09:31:21 PST
(In reply to Konstantin Tokarev from comment #5)
> Comment on attachment 422370 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=422370&action=review
> 
> > CMakeLists.txt:9
> > +cmake_minimum_required(VERSION 3.12)
> 
> cmake_minimum_required(VERSION 3.10) is also present in subprojects, such as
> Source/WTF/CMakeLists.txt

Good catch forgot about the AppleWin build doing that.
Comment 7 Don Olmstead 2021-03-05 09:42:44 PST
Created attachment 422376 [details]
Patch
Comment 8 Don Olmstead 2021-03-05 09:43:24 PST
Comment on attachment 422376 [details]
Patch

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

> CMakeLists.txt:13
> -cmake_minimum_required(VERSION 3.10)
> +# cmake_minimum_required is also set inside Source/${FRAMEWORK}/CMakeLists.txt
> +# in support of the AppleWin internal build so this version should be kept in
> +# sync across those files.
> +#
> +cmake_minimum_required(VERSION 3.12)

Added a note here about that annulen
Comment 9 Konstantin Tokarev 2021-03-05 10:39:11 PST
Comment on attachment 422376 [details]
Patch

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

>> CMakeLists.txt:13
>> +cmake_minimum_required(VERSION 3.12)
> 
> Added a note here about that annulen

Great idea, similar mistakes were made in the past too
Comment 10 EWS 2021-03-05 11:12:51 PST
Committed r273984: <https://commits.webkit.org/r273984>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 422376 [details].
Comment 11 Yury Semikhatsky 2021-03-08 12:35:36 PST
This broke compilation on Ubuntu 18.04 as it comes with cmake 3.10. I'd point to the Ububntu 1804 build bot but has been in a bad state for a different reason (https://build.webkit.org/#/builders/71).

Is it possible to keep the min cmake version at 3.10 while Ubuntu 1804 is an officially supported LTS?
Comment 12 Michael Catanzaro 2021-03-08 12:40:53 PST
Hi Yury, support for Ubuntu 18.04's toolchain ends in April according to https://trac.webkit.org/wiki/WebKitGTK/DependenciesPolicy. WebKitGTK 2.32 has already been branched so Ubuntu has until September, when WebKitGTK 2.34 will be released, to figure out what to do. You should still be able to build for Ubuntu 18.04 if you build your own CMake.
Comment 13 Yury Semikhatsky 2021-03-08 13:07:17 PST
Hi Michael, thanks for quick response and for the pointer to the policy! I ended up building cmake from source for now, should fix the problem.
Comment 14 Michael Catanzaro 2021-03-09 10:13:52 PST
Note that the patch in bug #181916 depends on cmake 3.12.