Fri Jan 21 15:24:17 2022 UTC ()
Pullup ticket #6570 - requested by gutteridge
www/webkit-gtk: NetBSD 9 build fix, PR pkg/56604

Revisions pulled up:
- www/webkit-gtk/Makefile                                       1.219
- www/webkit-gtk/buildlink3.mk                                  1.87

---
   Module Name:    pkgsrc
   Committed By:   gutteridge
   Date:           Thu Jan 13 03:57:28 UTC 2022

   Modified Files:
           pkgsrc/www/webkit-gtk: Makefile buildlink3.mk

   Log Message:
   webkit-gtk: fix builds on NetBSD 9.x

   The base GCC 7.5 on NetBSD 9.x is missing a C++17 feature expected by
   this package now. The pkgsrc GCC 7.5 includes that feature, but the
   build still fails later on with another unmet expectation. So GCC 8 is
   now the minimum viable version with which to build this package.

   This involves a bit of a kludge to deal with how GCC from pkgsrc ends
   up linking. This is obviously not ideal, and is part of a broader
   topic that needs revisiting. The present goal is to try and stabilize
   the 2021Q4 branch.

   Tested on 9.2_STABLE/amd64 with www/badwolf. Addresses PR pkg/56604.


(bsiegert)
diff -r1.217.2.1 -r1.217.2.2 pkgsrc/www/webkit-gtk/Makefile
diff -r1.85.2.1 -r1.85.2.2 pkgsrc/www/webkit-gtk/buildlink3.mk

cvs diff -r1.217.2.1 -r1.217.2.2 pkgsrc/www/webkit-gtk/Makefile (expand / switch to unified diff)

--- pkgsrc/www/webkit-gtk/Makefile 2022/01/01 16:49:10 1.217.2.1
+++ pkgsrc/www/webkit-gtk/Makefile 2022/01/21 15:24:17 1.217.2.2
@@ -1,44 +1,55 @@ @@ -1,44 +1,55 @@
1# $NetBSD: Makefile,v 1.217.2.1 2022/01/01 16:49:10 bsiegert Exp $ 1# $NetBSD: Makefile,v 1.217.2.2 2022/01/21 15:24:17 bsiegert Exp $
2 2
3DISTNAME= webkitgtk-2.34.3 3DISTNAME= webkitgtk-2.34.3
4PKGNAME= ${DISTNAME:S/webkitgtk/webkit-gtk/} 4PKGNAME= ${DISTNAME:S/webkitgtk/webkit-gtk/}
5PKGREVISION= 1 5PKGREVISION= 1
6CATEGORIES= www 6CATEGORIES= www
7MASTER_SITES= https://www.webkitgtk.org/releases/ 7MASTER_SITES= https://www.webkitgtk.org/releases/
8EXTRACT_SUFX= .tar.xz 8EXTRACT_SUFX= .tar.xz
9 9
10MAINTAINER= pkgsrc-users@NetBSD.org 10MAINTAINER= pkgsrc-users@NetBSD.org
11HOMEPAGE= https://www.webkitgtk.org/ 11HOMEPAGE= https://www.webkitgtk.org/
12COMMENT= GTK port of the WebKit browser engine 12COMMENT= GTK port of the WebKit browser engine
13LICENSE= 2-clause-bsd AND gnu-lgpl-v2 13LICENSE= 2-clause-bsd AND gnu-lgpl-v2
14 14
15# shm_open(3) and shm_unlink(3) appeared in NetBSD 7.0 15# shm_open(3) and shm_unlink(3) appeared in NetBSD 7.0
16NOT_FOR_PLATFORM= NetBSD-[1-6].*-* 16NOT_FOR_PLATFORM= NetBSD-[1-6].*-*
17 17
18TOOL_DEPENDS+= gettext-tools>=0.18:../../devel/gettext-tools 18TOOL_DEPENDS+= gettext-tools>=0.18:../../devel/gettext-tools
19TOOL_DEPENDS+= ${PYPKGPREFIX}-expat-[0-9]*:../../textproc/py-expat 19TOOL_DEPENDS+= ${PYPKGPREFIX}-expat-[0-9]*:../../textproc/py-expat
20 20
21USE_CMAKE= yes 21USE_CMAKE= yes
22USE_LANGUAGES= c c++11 22USE_LANGUAGES= c c++17
23USE_TOOLS+= automake bash bison flex gmake perl pkg-config msgfmt 23USE_TOOLS+= automake bash bison flex gmake perl pkg-config msgfmt
24 24
25# Enabling -gdwarf-2 hits GNU ar limits on file size. 25# Enabling -gdwarf-2 hits GNU ar limits on file size.
26CTF_SUPPORTED= no 26CTF_SUPPORTED= no
27 27
28# GCC >= 7.3.0 is required, checked via CMakeLists.txt 28# GCC >= 8 is required, it no longer builds with lower versions.
29GCC_REQD+= 7 29GCC_REQD+= 8
30USE_GCC_RUNTIME= yes 30USE_GCC_RUNTIME= yes
31 31
 32.include "../../mk/bsd.prefs.mk"
 33
 34# This package will link against libstdc++.so from the pkgsrc GCC when the
 35# base OS GCC doesn't meet the minimum requirement. Thus we do this so the
 36# appropriate gcc-libs package will be captured as a dependency, otherwise
 37# binary packages will be broken. See also PR pkg/56604.
 38.if ${OPSYS} == "NetBSD" && ${OPSYS_VERSION} < 099915
 39USE_PKGSRC_GCC= yes
 40USE_PKGSRC_GCC_RUNTIME= yes
 41.endif
 42
32# Using ld.gold subverts Pkgsrc wrappers, and this package also crashes buggy 43# Using ld.gold subverts Pkgsrc wrappers, and this package also crashes buggy
33# versions of ld.gold. 44# versions of ld.gold.
34CMAKE_ARGS+= -DUSE_LD_GOLD=OFF 45CMAKE_ARGS+= -DUSE_LD_GOLD=OFF
35 46
36PKGCONFIG_OVERRIDE+= Source/JavaScriptCore/javascriptcoregtk.pc.in 47PKGCONFIG_OVERRIDE+= Source/JavaScriptCore/javascriptcoregtk.pc.in
37PKGCONFIG_OVERRIDE+= Source/WebKit/gtk/webkit2gtk-web-extension.pc.in 48PKGCONFIG_OVERRIDE+= Source/WebKit/gtk/webkit2gtk-web-extension.pc.in
38PKGCONFIG_OVERRIDE+= Source/WebKit/gtk/webkit2gtk.pc.in 49PKGCONFIG_OVERRIDE+= Source/WebKit/gtk/webkit2gtk.pc.in
39 50
40CMAKE_ARGS+= -DCMAKE_BUILD_TYPE=Release 51CMAKE_ARGS+= -DCMAKE_BUILD_TYPE=Release
41CMAKE_ARGS+= -DPORT=GTK 52CMAKE_ARGS+= -DPORT=GTK
42CMAKE_ARGS+= -DENABLE_X11_TARGET=ON 53CMAKE_ARGS+= -DENABLE_X11_TARGET=ON
43CMAKE_ARGS+= -DENABLE_MINIBROWSER=ON 54CMAKE_ARGS+= -DENABLE_MINIBROWSER=ON
44CMAKE_ARGS+= -DENABLE_GAMEPAD=OFF 55CMAKE_ARGS+= -DENABLE_GAMEPAD=OFF

cvs diff -r1.85.2.1 -r1.85.2.2 pkgsrc/www/webkit-gtk/buildlink3.mk (expand / switch to unified diff)

--- pkgsrc/www/webkit-gtk/buildlink3.mk 2022/01/01 16:49:10 1.85.2.1
+++ pkgsrc/www/webkit-gtk/buildlink3.mk 2022/01/21 15:24:17 1.85.2.2
@@ -1,26 +1,26 @@ @@ -1,26 +1,26 @@
1# $NetBSD: buildlink3.mk,v 1.85.2.1 2022/01/01 16:49:10 bsiegert Exp $ 1# $NetBSD: buildlink3.mk,v 1.85.2.2 2022/01/21 15:24:17 bsiegert Exp $
2 2
3BUILDLINK_TREE+= webkit-gtk 3BUILDLINK_TREE+= webkit-gtk
4 4
5.if !defined(WEBKIT_GTK_BUILDLINK3_MK) 5.if !defined(WEBKIT_GTK_BUILDLINK3_MK)
6WEBKIT_GTK_BUILDLINK3_MK:= 6WEBKIT_GTK_BUILDLINK3_MK:=
7 7
8BUILDLINK_API_DEPENDS.webkit-gtk+= webkit-gtk>=2.8 8BUILDLINK_API_DEPENDS.webkit-gtk+= webkit-gtk>=2.8
9BUILDLINK_ABI_DEPENDS.webkit-gtk?= webkit-gtk>=2.34.2 9BUILDLINK_ABI_DEPENDS.webkit-gtk?= webkit-gtk>=2.34.2
10BUILDLINK_PKGSRCDIR.webkit-gtk?= ../../www/webkit-gtk 10BUILDLINK_PKGSRCDIR.webkit-gtk?= ../../www/webkit-gtk
11 11
12# This is necessary to match the package requirement. 12# This is necessary to match the package requirement.
13GCC_REQD+= 7.3 13GCC_REQD+= 8
14 14
15pkgbase := webkit-gtk 15pkgbase := webkit-gtk
16.include "../../mk/pkg-build-options.mk" 16.include "../../mk/pkg-build-options.mk"
17 17
18.if !empty(PKG_BUILD_OPTIONS.webkit-gtk:Menchant) 18.if !empty(PKG_BUILD_OPTIONS.webkit-gtk:Menchant)
19.include "../../textproc/enchant2/buildlink3.mk" 19.include "../../textproc/enchant2/buildlink3.mk"
20.endif 20.endif
21 21
22.include "../../databases/sqlite3/buildlink3.mk" 22.include "../../databases/sqlite3/buildlink3.mk"
23.include "../../devel/gperf/buildlink3.mk" 23.include "../../devel/gperf/buildlink3.mk"
24.include "../../graphics/freetype2/buildlink3.mk" 24.include "../../graphics/freetype2/buildlink3.mk"
25.include "../../mk/jpeg.buildlink3.mk" 25.include "../../mk/jpeg.buildlink3.mk"
26.include "../../graphics/lcms2/buildlink3.mk" 26.include "../../graphics/lcms2/buildlink3.mk"