Bug 269388 - www/webkit2-gtk4: build fails on 12.x/i386 after update to 2.38.3
Summary: www/webkit2-gtk4: build fails on 12.x/i386 after update to 2.38.3
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-gnome (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-02-07 15:39 UTC by John Hein
Modified: 2023-02-07 19:22 UTC (History)
2 users (show)

See Also:
nc: maintainer-feedback+
nc: maintainer-feedback+


Attachments
[patch] fix build for i386 (1.32 KB, patch)
2023-02-07 16:01 UTC, John Hein
jcfyecrayz: maintainer-approval? (nc)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description John Hein 2023-02-07 15:39:18 UTC
When you build www/webkit2-gtk4 on 12.x/i386, it fails with:

======================
 .
 .
/usr/ports/www/webkit2-gtk4/work/webkitgtk-2.38.3/Source/JavaScriptCore/API/glib/JSCOptions.cpp:87:13: error: redefinition of 'valueFromGValue'
static bool valueFromGValue(const GValue* gValue, size_t& value)
            ^
/usr/ports/www/webkit2-gtk4/work/webkitgtk-2.38.3/Source/JavaScriptCore/API/glib/JSCOptions.cpp:76:13: note: previous definition is here
static bool valueFromGValue(const GValue* gValue, unsigned& value)
            ^
/usr/ports/www/webkit2-gtk4/work/webkitgtk-2.38.3/Source/JavaScriptCore/API/glib/JSCOptions.cpp:93:13: error: redefinition of 'valueToGValue'
static void valueToGValue(size_t value, GValue* gValue)
            ^
/usr/ports/www/webkit2-gtk4/work/webkitgtk-2.38.3/Source/JavaScriptCore/API/glib/JSCOptions.cpp:82:13: note: previous definition is here
static void valueToGValue(unsigned value, GValue* gValue)
            ^
/usr/ports/www/webkit2-gtk4/work/webkitgtk-2.38.3/Source/JavaScriptCore/API/glib/JSCOptions.cpp:562:22: error: redefinition of 'jscOptionsType'
static JSCOptionType jscOptionsType(size_t)
                     ^
/usr/ports/www/webkit2-gtk4/work/webkitgtk-2.38.3/Source/JavaScriptCore/API/glib/JSCOptions.cpp:557:22: note: previous definition is here
static JSCOptionType jscOptionsType(unsigned)
                     ^
2 warnings and 3 errors generated.
==============
Comment 1 John Hein 2023-02-07 15:40:55 UTC
The culprit is the addition of files/patch-Source_JavaScriptCore_API_glib_JSCOptions.cpp

Why was this patch applied?  This patch removes an upstream change that was specifically committed to support 32-bit platforms back in 2019.  Why undo that?

I removed that patch file, and it now builds on i386.  It also builds on amd64 (with and without the patch).
Comment 2 John Hein 2023-02-07 16:01:55 UTC
Created attachment 239970 [details]
[patch] fix build for i386

Remove the patch file (patch-Source_JavaScriptCore_API_glib_JSCOptions.cpp) to get builds working on i386.

The patch file itself says 'Unbreak i386', but it seems to do just exactly the opposite.  So remove it.

p.s. portlint is now complaining about ~40 patch files that were regressed format-wise in the update to 2.38.3, for example:

WARN: /usr/ports/www/webkit2-gtk4/files/patch-Source_WebDriver_PlatformGTK.cmake: patch was not generated using ``make makepatch''.  It is recommended to use ``make makepatch'' when you need to [re-]generate a patch to ensure proper patch format.

It's not worth fixing that on its own (repo churn), but please consider using makepatch when making changes to patch files.
Comment 3 John Hein 2023-02-07 16:05:15 UTC
(In reply to John Hein from comment #2)
No need to bump PORTREVISION for attachment 239970 [details].  It changes nothing on amd64 packages, and i386 build were failing, so there should not be any i386 packages to change.
Comment 4 Neel Chauhan freebsd_committer freebsd_triage 2023-02-07 19:20:55 UTC
LGTM. Will push shortly.
Comment 5 Neel Chauhan freebsd_committer freebsd_triage 2023-02-07 19:22:04 UTC
Committed!
Comment 6 commit-hook freebsd_committer freebsd_triage 2023-02-07 19:22:54 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=98376a10ad6f3e2aac8709f3f58e14c9095e452e

commit 98376a10ad6f3e2aac8709f3f58e14c9095e452e
Author:     John Hein <jcfyecrayz@liamekaens.com>
AuthorDate: 2023-02-07 19:21:12 +0000
Commit:     Neel Chauhan <nc@FreeBSD.org>
CommitDate: 2023-02-07 19:22:08 +0000

    www/webkit2-gtk4: Fix build on 12.x/i386

    PR:     269388

 ...e_JavaScriptCore_API_glib_JSCOptions.cpp (gone) | 36 ----------------------
 1 file changed, 36 deletions(-)