head	1.3;
access;
symbols;
locks; strict;
comment	@# @;


1.3
date	2026.09.04.16.05.35;	author tnn;	state Exp;
branches;
next	1.2;
commitid	Zd09pg8646o8YjUG;

1.2
date	2026.08.31.09.44.25;	author wiz;	state Exp;
branches;
next	1.1;
commitid	s6x9C0bUpSl4ZLTG;

1.1
date	2026.08.30.14.25.04;	author wiz;	state Exp;
branches;
next	;
commitid	JBc39jPIQAWHzFTG;


desc
@@


1.3
log
@webkit-gtk41: add some new CHECK_PORTABILITY_SKIPs
@
text
@# $NetBSD: Makefile.common,v 1.2 2026/08/31 09:44:25 wiz Exp $
# used by www/webkit-gtk41/Makefile
# used by www/webkit-gtk60/Makefile

DISTNAME=	webkitgtk-2.52.6
CATEGORIES=	www
MASTER_SITES=	https://www.webkitgtk.org/releases/
EXTRACT_SUFX=	.tar.xz

MAINTAINER=	pkgsrc-users@@NetBSD.org
HOMEPAGE=	https://www.webkitgtk.org/
LICENSE=	2-clause-bsd AND gnu-lgpl-v2

PATCHDIR=	${.CURDIR}/../../www/webkit-gtk41/patches
DISTINFO_FILE=	${.CURDIR}/../../www/webkit-gtk41/distinfo

TOOL_DEPENDS+=	gettext-tools>=0.18:../../devel/gettext-tools
TOOL_DEPENDS+=	glib2-introspection-[0-9]*:../../devel/glib2-introspection
# uses 'unifdef -x1'
TOOL_DEPENDS+=	unifdef-[0-9]*:../../devel/unifdef
TOOL_DEPENDS+=	${PYPKGPREFIX}-gi-docgen-[0-9]*:../../devel/py-gi-docgen

USE_CXX_FEATURES=	c++17
USE_LANGUAGES=		c c++
GCC_REQD+=		11
USE_TOOLS+=		automake bash bison flex gdbus-codegen gmake perl pkg-config msgfmt

# this doesn't seem to be using the pkg-config file, which would add this
CXXFLAGS+=	-I${PREFIX}/include/gstreamer-1.0

# Avoid million warnings
CFLAGS+=		-Wno-unused-parameter -Wno-undef
CXXFLAGS+=		-Wno-unused-parameter -Wno-undef -Wno-narrowing

# g-ir-scanner dumps core with full RELRO
RELRO_SUPPORTED=	partial

# Enabling -gdwarf-2 hits GNU ar limits on file size.
CTF_SUPPORTED=	no

.include "../../mk/bsd.prefs.mk"

CMAKE_CONFIGURE_ARGS+=		-DPORT=GTK
CMAKE_CONFIGURE_ARGS+=		-DENABLE_X11_TARGET=ON
CMAKE_CONFIGURE_ARGS+=		-DENABLE_MINIBROWSER=ON
CMAKE_CONFIGURE_ARGS+=		-DENABLE_GAMEPAD=OFF
#CMAKE_CONFIGURE_ARGS+=		-DENABLE_GEOLOCATION=OFF
#CMAKE_CONFIGURE_ARGS+=		-DENABLE_INTROSPECTION=ON
CMAKE_CONFIGURE_ARGS+=		-DENABLE_JOURNALD_LOG=OFF
#CMAKE_CONFIGURE_ARGS+=		-DENABLE_BUBBLEWRAP_SANDBOX=OFF
#CMAKE_CONFIGURE_ARGS+=		-DENABLE_DOCUMENTATION=OFF
CMAKE_CONFIGURE_ARGS+=		-DUSE_SYSTEM_SYSPROF_CAPTURE=NO
CMAKE_CONFIGURE_ARGS+=		-DUSE_SYSPROF_CAPTURE=OFF
CMAKE_CONFIGURE_ARGS+=		-DUSE_GSTREAMER_GL=ON
#CMAKE_CONFIGURE_ARGS+=		-DUSE_LIBHYPHEN=OFF
#CMAKE_CONFIGURE_ARGS+=		-DUSE_OPENJPEG=OFF
CMAKE_CONFIGURE_ARGS+=		-DUSE_LIBBACKTRACE=OFF
.if ${OPSYS} == "Darwin"
CMAKE_CONFIGURE_ARGS+=		-DUSE_LIBDRM=OFF
.endif
# otherwise, libsqlite3.so from ${BUILDLINK_DIR} is hardcoded into some binaries
CMAKE_CONFIGURE_ARGS+=		-DSQLite3_LIBRARY=${BUILDLINK_PREFIX.sqlite3}/lib/libsqlite3.so

# required for faking a better user-agent
CMAKE_CONFIGURE_ARGS+=		-DUSER_AGENT_BRANDING="Linux ${MACHINE_ARCH}"

# From OpenBSD ports:
# we don't want an allocation of 1GB, it's above the "default" class ulimit
# see Source/JavaScriptCore/jit/ExecutableAllocator.cpp for default values
.if ${MACHINE_ARCH} == "x86_64"
CXXFLAGS+=		-DFIXED_EXECUTABLE_MEMORY_POOL_SIZE_IN_MB=512
.endif
# see Source/JavaScriptCore/runtime/StructureID.h for default values
CXXFLAGS+=		-DSTRUCTURE_HEAP_ADDRESS_SIZE_IN_MB=256

# For backtrace
LDFLAGS.NetBSD+=	-lexecinfo

PKGCONFIG_OVERRIDE+=	Source/JavaScriptCore/javascriptcoreglib.pc.in
PKGCONFIG_OVERRIDE+=	Source/JavaScriptCore/javascriptcoregtk.pc.in
PKGCONFIG_OVERRIDE+=	Source/WebKit/WPEPlatform/wpe-platform-uninstalled.pc.in
PKGCONFIG_OVERRIDE+=	Source/WebKit/WPEPlatform/wpe-platform.pc.in
PKGCONFIG_OVERRIDE+=	Source/WebKit/gtk/webkitgtk-web-process-extension.pc.in
PKGCONFIG_OVERRIDE+=	Source/WebKit/gtk/webkitgtk.pc.in

REPLACE_PERL+=		Source/JavaScriptCore/Scripts/*.pl
REPLACE_PERL+=		Source/JavaScriptCore/create_hash_table
REPLACE_PERL+=		Source/WebCore/Scripts/*.pl
REPLACE_PERL+=		Source/WebCore/bindings/scripts/*.pl
REPLACE_PERL+=		Source/WebCore/bindings/scripts/*.pm
REPLACE_PERL+=		Source/WebCore/css/*.pl
REPLACE_PERL+=		Source/WebCore/dom/*.pl
REPLACE_PERL+=		Source/WebCore/make-hash-tools.pl
REPLACE_PERL+=		Source/WebInspectorUI/Scripts/*.pl
REPLACE_PERL+=		Source/WebKit/Scripts/*.pl

REPLACE_PYTHON+=	Source/JavaScriptCore/Scripts/*.py
REPLACE_PYTHON+=	Source/JavaScriptCore/Scripts/wkbuiltins/*.py
REPLACE_PYTHON+=	Source/JavaScriptCore/inspector/scripts/*.py
REPLACE_PYTHON+=	Source/JavaScriptCore/inspector/scripts/codegen/*.py
REPLACE_PYTHON+=	Source/JavaScriptCore/wasm/*.py
REPLACE_PYTHON+=	Source/JavaScriptCore/yarr/*.py
REPLACE_PYTHON+=	Source/JavaScriptCore/yarr/create_regex_tables
REPLACE_PYTHON+=	Source/JavaScriptCore/yarr/generateYarrCanonicalizeUnicode
REPLACE_PYTHON+=	Source/ThirdParty/ANGLE/src/compiler/translator/*.py
REPLACE_PYTHON+=	Source/ThirdParty/ANGLE/src/libANGLE/*.py
REPLACE_PYTHON+=	Source/ThirdParty/gtest/test/*.py
REPLACE_PYTHON+=	Source/WebCore/html/parser/create-html-entity-table
REPLACE_PYTHON+=	Source/WebCore/platform/network/create-http-header-name-table
REPLACE_PYTHON+=	Source/WebKit/Scripts/*.py
REPLACE_PYTHON+=	Tools/glib/*.py

REPLACE_BASH+=		Source/JavaScriptCore/postprocess-headers.sh
REPLACE_BASH+=		Source/ThirdParty/ANGLE/adjust-angle-include-paths-rule
REPLACE_BASH+=		Source/ThirdParty/gtest/xcode/Samples/FrameworkSample/runtests.sh
REPLACE_BASH+=		Source/ThirdParty/gtest/xcode/Scripts/runtests.sh
REPLACE_BASH+=		Source/WebKit/Scripts/copy-webcontent-resources-to-private-headers.sh
REPLACE_BASH+=		Source/WebKit/Scripts/process-entitlements.sh
REPLACE_BASH+=		Tools/gtk/install-dependencies

REPLACE_RUBY+=		Source/JavaScriptCore/Scripts/postprocess-asm
REPLACE_RUBY+=		Source/JavaScriptCore/Scripts/resolve-asm-file-conflicts.rb
REPLACE_RUBY+=		Source/JavaScriptCore/b3/air/*.rb
REPLACE_RUBY+=		Source/JavaScriptCore/offlineasm/*.rb
REPLACE_RUBY+=		Source/WTF/Scripts/GeneratePreferences.rb
REPLACE_RUBY+=		Source/WebCore/Scripts/GenerateSettings.rb
REPLACE_RUBY+=		Source/WebCore/domjit/*.rb
REPLACE_RUBY+=		Source/WebInspectorUI/Scripts/*.rb
REPLACE_RUBY+=		Source/bmalloc/libpas/export.rb

SUBST_CLASSES+=		python
SUBST_FILES.python+=	Source/WebInspectorUI/Scripts/copy-user-interface-resources.pl
SUBST_SED.python+=	-e 's,"python3","${PYTHONBIN}",'
SUBST_STAGE.python=	pre-configure
SUBST_MESSAGE.python=	Fixing path to python binary.

SUBST_CLASSES+=		ruby
SUBST_FILES.ruby+=	Source/bmalloc/libpas/scripts/tally_verifier_output
SUBST_FILES.ruby+=	Tools/TestWebKitAPI/Scripts/generate-unified-sources.sh
SUBST_FILES.ruby+=	Source/JavaScriptCore/Scripts/generate-unified-sources.sh
SUBST_FILES.ruby+=	Source/WebCore/Scripts/generate-unified-sources.sh
SUBST_FILES.ruby+=	Source/WebKit/Scripts/generate-unified-sources.sh
SUBST_SED.ruby+=	-e 's,env ruby,env ${RUBY},'
SUBST_STAGE.ruby=	pre-configure
SUBST_MESSAGE.ruby=	Fixing path to ruby binary.

.include "../../lang/ruby/rubyversion.mk"
.include "../../lang/ruby/replace.mk"
TOOL_DEPENDS+=	${RUBY_BASE}>=${RUBY_VERSION}:${RUBY_SRCDIR}
CMAKE_CONFIGURE_ARGS+=	-DRUBY_EXECUTABLE=${RUBY}

PYTHON_FOR_BUILD_ONLY=	yes
.include "../../lang/python/application.mk"
CMAKE_CONFIGURE_ARGS+=	-DPYTHON_EXECUTABLE=${PYTHONBIN}

CXXFLAGS.SunOS+=	-fpermissive

# TODO: fix shell portability issues in these files
CHECK_PORTABILITY_SKIP+=	Source/JavaScriptCore/Scripts/check-xcfilelists.sh
CHECK_PORTABILITY_SKIP+=	Source/JavaScriptCore/Scripts/create-symlink-to-altroot.sh
CHECK_PORTABILITY_SKIP+=	Source/JavaScriptCore/Scripts/create-symlink-to-cryptex.sh
CHECK_PORTABILITY_SKIP+=	Source/JavaScriptCore/Scripts/generate-unified-sources.sh
CHECK_PORTABILITY_SKIP+=	Source/WTF/Scripts/audit-spi-if-needed.sh
CHECK_PORTABILITY_SKIP+=	Source/WebCore/Scripts/check-xcfilelists.sh
CHECK_PORTABILITY_SKIP+=	Source/WebCore/Scripts/create-symlink-to-altroot.sh
CHECK_PORTABILITY_SKIP+=	Source/WebCore/Scripts/create-symlink-to-cryptex.sh
CHECK_PORTABILITY_SKIP+=	Source/WebCore/Scripts/generate-unified-sources.sh
CHECK_PORTABILITY_SKIP+=	Source/WebGPU/Scripts/create-symlink-to-cryptex.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/check-xcfilelists.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/compile-sandbox.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/create-symlink-to-altroot.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/create-symlink-to-cryptex.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/copy-binary-plists.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/copy-launchd-plist-and-create-symlink.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/generate-feature-flags-plist.sh
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/generate-swift-availability-macros
CHECK_PORTABILITY_SKIP+=	Source/WebKit/Scripts/generate-unified-sources.sh
CHECK_PORTABILITY_SKIP+=	Tools/TestWebKitAPI/Scripts/check-xcfilelists.sh
CHECK_PORTABILITY_SKIP+=	Tools/TestWebKitAPI/Scripts/generate-unified-sources.sh

.include "options.mk"

# geoclue2
#.include "../../sysutils/libnotify/buildlink3.mk"
.include "../../audio/flite/buildlink3.mk"
.include "../../databases/sqlite3/buildlink3.mk"
.include "../../devel/cmake/build.mk"
# when gettext-lib is installed, it links against it,
# so force dependency on it.
PREFER.gettext=	pkgsrc
.include "../../devel/gettext-lib/buildlink3.mk"
.include "../../devel/glib2/buildlink3.mk"
.include "../../devel/gobject-introspection/buildlink3.mk"
.include "../../devel/gperf/buildlink3.mk"
.if ${PKGSRC_COMPILER:Mgcc}
.include "../../devel/libatomic/buildlink3.mk"
.endif
.include "../../devel/pango/buildlink3.mk"
.include "../../devel/zlib/buildlink3.mk"
.include "../../fonts/harfbuzz-icu/buildlink3.mk"
.include "../../fonts/woff2/buildlink3.mk"
.include "../../graphics/cairo/buildlink3.mk"
.include "../../graphics/freetype2/buildlink3.mk"
.include "../../graphics/gdk-pixbuf2/buildlink3.mk"
.include "../../graphics/graphene/buildlink3.mk"
.include "../../graphics/gst-plugins1-gl/buildlink3.mk"
.include "../../graphics/lcms2/buildlink3.mk"
.include "../../graphics/libavif/buildlink3.mk"
.include "../../graphics/libjxl/buildlink3.mk"
.include "../../graphics/libwebp/buildlink3.mk"
.include "../../graphics/png/buildlink3.mk"
# SkJpegCodec.cpp:210:58: error: 'JCS_RGB565' was not declared in this scope; did you mean 'JCS_RGB'?
JPEG_ACCEPTED=		libjpeg-turbo
.include "../../mk/jpeg.buildlink3.mk"
.include "../../multimedia/gst-plugins1-base/buildlink3.mk"
.include "../../multimedia/gst-plugins1-good/buildlink3.mk"
.include "../../multimedia/gstreamer1/buildlink3.mk"
.include "../../net/libsoup3/buildlink3.mk"
.include "../../security/libgcrypt/buildlink3.mk"
.include "../../security/libgpg-error/buildlink3.mk"
.include "../../security/libsecret/buildlink3.mk"
.include "../../security/libtasn1/buildlink3.mk"
.include "../../textproc/enchant2/buildlink3.mk"
.include "../../textproc/hyphen/buildlink3.mk"
.include "../../textproc/icu/buildlink3.mk"
.include "../../textproc/libxml2/buildlink3.mk"
.include "../../textproc/libxslt/buildlink3.mk"
.include "../../x11/libX11/buildlink3.mk"
@


1.2
log
@webkit-gtk*: force gettext-lib from pkgsrc

pkgsrc libintl is installed during the build, and the pkgsrc
version is preferred when linking, leading to missing library
errors when pkg_add(1)ing.

Force gettext-lib from pkgsrc to avoid this.

Bump PKGREVISION.
@
text
@d1 1
a1 1
# $NetBSD: Makefile.common,v 1.1 2026/08/30 14:25:04 wiz Exp $
d161 1
d163 1
d166 1
d168 1
d170 1
d172 3
d176 1
@


1.1
log
@www/webkit-gtk41: import webkit-gtk41-2.52.6

WebKit is an open source web browser engine. WebKit is also the name of
the Mac OS X system framework version of the engine that's used by
Safari, Dashboard, Mail, and many other OS X applications. WebKit's HTML
and JavaScript code began as a branch of the KHTML and KJS libraries
from KDE.

This is the GTK3 port of the engine, API version 4.1.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.240 2022/11/23 16:19:06 adam Exp $
d179 3
@

