From nobody Wed Mar 15 10:53:20 2023 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Pc6gj0gv0z3yMw8; Wed, 15 Mar 2023 10:53:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Pc6gh6t4Wz44vZ; Wed, 15 Mar 2023 10:53:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1678877601; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=na7JyeCCVMoZ/Ejb2bAQKHSWMicjgyCUVUWPbThmxPg=; b=QAhtx25gRfG+sTx6hRrBLNtIRzmlnGXeHN/xfTcd9YYGdtEqUotU2r7OSEoLD5LmKdIW5K ak/Z99czbuC/GG04VwGONphON7avW4OkRv0T4MV5ia0FEDB8WvR5FttMboJ23fVm4IrUSJ nXCOslb8L1MpTIBlKmyg0l2rTWCCcLvoKbhRCR19fJALyKqcqaDUTioO8NQTdT14LPukaB 4vy/O6XSTi8wS7YVRLzeRZM8g49ARlqKLqZsmYiPXV+Y9olgPn+dH6IBilB6tkhS+uK9cS 5JgC9kYvdCZUU0QbDVYB/Ok00YzVghPkMglz9DXmVhaSSa/W1WaUSANYwtQpSA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1678877601; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=na7JyeCCVMoZ/Ejb2bAQKHSWMicjgyCUVUWPbThmxPg=; b=VSl0XE4CvgFSngPOU2hBiRUlZq3KOHS7OG+WXKEFrlRhZnB8vvas1MeJcwq1osP+dx8NA1 pzQM6pPnYJiMzH8lnkTPgf7MVwz6FOzLskTVQGZC+kvcJyVEz9qclaDCgSpjr11M94GmvI k84CcgQRcjCH5oLLdyYbqEALBX1wEz9+9VMaR+apHIurd33bC/GM7xrkVMfdzZK5EvFUne AH1CGcFtcDHAeVK9FR6cQaulSf4puRudCcnzR63FcSFOsAUM3rnwrbj7axvglbhHFp4vGJ mXI/o2J3Xvcsl53Ua7OltfRz0eDs5Pcmyve5QZhh1K9GtfX+QUuQO8PhkWHm4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1678877601; a=rsa-sha256; cv=none; b=B4YskslOA42simPCt4/dWL3iMflSv9ae3abOhbh65jin9HxlfWLF7CGGhaQynKIwDHvtXr nFqB8+4yq0mcx0f4udooWKRXXM6cV2cY0deUK0aN/3LhmpEunmYWE3dVib+u387qZacqRm aE9rEFl1NQTzdg+MheWamjsxGMEfMYDlITEjJHsVjHKme61kEVmkB8g1STmkbwQl9iVlNE 3rn6Xgg54GuLofXkcGASHBFmCQxw4N7FQcFuX6kt2hcZeIFhEYYgFxhl7W3V7R/PkBuH6n 2ozmYUkUPwzv9iSTDh31mZWj/BfoLZTp/1kBdig9uGO1pxj6V+HkMgGB6sFxzg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Pc6gh5vY7z1DWJ; Wed, 15 Mar 2023 10:53:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 32FArKHB082511; Wed, 15 Mar 2023 10:53:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 32FArKbh082510; Wed, 15 Mar 2023 10:53:20 GMT (envelope-from git) Date: Wed, 15 Mar 2023 10:53:20 GMT Message-Id: <202303151053.32FArKbh082510@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Robert Nagy Subject: git: 23607969b871 - main - www/{*chromium,iridium}: restrict usage of preserve_most to clang 17 List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rnagy X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 23607969b871fab90e3f809183f6f9fcead30eda Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by rnagy: URL: https://cgit.FreeBSD.org/ports/commit/?id=23607969b871fab90e3f809183f6f9fcead30eda commit 23607969b871fab90e3f809183f6f9fcead30eda Author: Robert Nagy AuthorDate: 2023-03-15 07:55:45 +0000 Commit: Robert Nagy CommitDate: 2023-03-15 10:53:05 +0000 www/{*chromium,iridium}: restrict usage of preserve_most to clang 17 the preserve_most attribute usage < clang 17 is causing weird runtime issues in v8 and this commit backports a v8 commit that disables the usage of this attribute with such compilers Approved by: rene (mentor) Obtained from: https://chromium.googlesource.com/v8/v8/+/ab12885a59d86d43a624ffaf6d56ca0d34e8e8bb --- www/chromium/Makefile | 1 + www/chromium/files/patch-v8_include_v8config.h | 32 ++++++++++++++++------ www/iridium/Makefile | 1 + www/iridium/files/patch-v8_include_v8config.h | 32 ++++++++++++++++------ www/ungoogled-chromium/Makefile | 1 + .../files/patch-v8_include_v8config.h | 32 ++++++++++++++++------ 6 files changed, 75 insertions(+), 24 deletions(-) diff --git a/www/chromium/Makefile b/www/chromium/Makefile index 761ccbaee13c..ff80e68d4163 100644 --- a/www/chromium/Makefile +++ b/www/chromium/Makefile @@ -1,5 +1,6 @@ PORTNAME= chromium PORTVERSION= 111.0.5563.64 +PORTREVISION= 1 CATEGORIES= www wayland MASTER_SITES= https://commondatastorage.googleapis.com/chromium-browser-official/ \ https://nerd.hu/distfiles/:external diff --git a/www/chromium/files/patch-v8_include_v8config.h b/www/chromium/files/patch-v8_include_v8config.h index 1f906768877c..2731df78fdac 100644 --- a/www/chromium/files/patch-v8_include_v8config.h +++ b/www/chromium/files/patch-v8_include_v8config.h @@ -1,4 +1,4 @@ ---- v8/include/v8config.h.orig 2022-04-21 18:48:31 UTC +--- v8/include/v8config.h.orig 2023-03-15 07:46:50 UTC +++ v8/include/v8config.h @@ -183,6 +183,8 @@ path. Add it with -I to the command line && !defined(V8_TARGET_OS_FUCHSIA) \ @@ -18,12 +18,10 @@ || defined(V8_TARGET_OS_MACOS) \ || defined(V8_TARGET_OS_WIN) # error A target OS is defined but V8_HAVE_TARGET_OS is unset. -@@ -214,6 +218,16 @@ path. Add it with -I to the command line - - #ifdef V8_OS_LINUX +@@ -216,6 +220,16 @@ path. Add it with -I to the command line # define V8_TARGET_OS_LINUX -+#endif -+ + #endif + +#ifdef V8_OS_OPENBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD @@ -32,6 +30,24 @@ +#ifdef V8_OS_FREEBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD - #endif - ++#endif ++ #ifdef V8_OS_MACOS + # define V8_TARGET_OS_MACOS + #endif +@@ -351,10 +365,14 @@ path. Add it with -I to the command line + // - component builds fail because _dl_runtime_resolve clobbers registers, + // - we see crashes on arm64 on Windows (https://crbug.com/1409934), which can + // hopefully be fixed in the future. ++// Additionally, the initial implementation in clang <= 16 overwrote the return ++// register(s) in the epilogue of a preserve_most function, so we only use ++// preserve_most in clang >= 17 (see https://reviews.llvm.org/D143425). + #if (defined(_M_X64) || defined(__x86_64__) /* x64 (everywhere) */ \ + || ((defined(__AARCH64EL__) || defined(_M_ARM64)) /* arm64, but ... */ \ + && !defined(_WIN32))) /* not on windows */ \ +- && !defined(COMPONENT_BUILD) /* no component build */ ++ && !defined(COMPONENT_BUILD) /* no component build */\ ++ && __clang_major__ >= 17 /* clang >= 17 */ + # define V8_HAS_ATTRIBUTE_PRESERVE_MOST (__has_attribute(preserve_most)) + #endif + # define V8_HAS_ATTRIBUTE_VISIBILITY (__has_attribute(visibility)) diff --git a/www/iridium/Makefile b/www/iridium/Makefile index 760eac6e736e..dc187c797e34 100644 --- a/www/iridium/Makefile +++ b/www/iridium/Makefile @@ -1,5 +1,6 @@ PORTNAME= iridium PORTVERSION= 2023.03.111 +PORTREVISION= 1 CATEGORIES= www wayland MASTER_SITES= https://downloads.iridiumbrowser.de/source/ PKGNAMESUFFIX= -browser diff --git a/www/iridium/files/patch-v8_include_v8config.h b/www/iridium/files/patch-v8_include_v8config.h index 1fbdf5604eab..2731df78fdac 100644 --- a/www/iridium/files/patch-v8_include_v8config.h +++ b/www/iridium/files/patch-v8_include_v8config.h @@ -1,4 +1,4 @@ ---- v8/include/v8config.h.orig 2022-10-05 07:34:01 UTC +--- v8/include/v8config.h.orig 2023-03-15 07:46:50 UTC +++ v8/include/v8config.h @@ -183,6 +183,8 @@ path. Add it with -I to the command line && !defined(V8_TARGET_OS_FUCHSIA) \ @@ -18,12 +18,10 @@ || defined(V8_TARGET_OS_MACOS) \ || defined(V8_TARGET_OS_WIN) # error A target OS is defined but V8_HAVE_TARGET_OS is unset. -@@ -214,6 +218,16 @@ path. Add it with -I to the command line - - #ifdef V8_OS_LINUX +@@ -216,6 +220,16 @@ path. Add it with -I to the command line # define V8_TARGET_OS_LINUX -+#endif -+ + #endif + +#ifdef V8_OS_OPENBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD @@ -32,6 +30,24 @@ +#ifdef V8_OS_FREEBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD - #endif - ++#endif ++ #ifdef V8_OS_MACOS + # define V8_TARGET_OS_MACOS + #endif +@@ -351,10 +365,14 @@ path. Add it with -I to the command line + // - component builds fail because _dl_runtime_resolve clobbers registers, + // - we see crashes on arm64 on Windows (https://crbug.com/1409934), which can + // hopefully be fixed in the future. ++// Additionally, the initial implementation in clang <= 16 overwrote the return ++// register(s) in the epilogue of a preserve_most function, so we only use ++// preserve_most in clang >= 17 (see https://reviews.llvm.org/D143425). + #if (defined(_M_X64) || defined(__x86_64__) /* x64 (everywhere) */ \ + || ((defined(__AARCH64EL__) || defined(_M_ARM64)) /* arm64, but ... */ \ + && !defined(_WIN32))) /* not on windows */ \ +- && !defined(COMPONENT_BUILD) /* no component build */ ++ && !defined(COMPONENT_BUILD) /* no component build */\ ++ && __clang_major__ >= 17 /* clang >= 17 */ + # define V8_HAS_ATTRIBUTE_PRESERVE_MOST (__has_attribute(preserve_most)) + #endif + # define V8_HAS_ATTRIBUTE_VISIBILITY (__has_attribute(visibility)) diff --git a/www/ungoogled-chromium/Makefile b/www/ungoogled-chromium/Makefile index abc8d11c8a45..b8798fb02c32 100644 --- a/www/ungoogled-chromium/Makefile +++ b/www/ungoogled-chromium/Makefile @@ -1,5 +1,6 @@ PORTNAME= ungoogled-chromium PORTVERSION= 111.0.5563.64 +PORTREVISION= 1 UGVERSION= ${DISTVERSION}-1 CATEGORIES= www wayland MASTER_SITES= https://commondatastorage.googleapis.com/chromium-browser-official/ \ diff --git a/www/ungoogled-chromium/files/patch-v8_include_v8config.h b/www/ungoogled-chromium/files/patch-v8_include_v8config.h index 2b0ab6a4089c..2731df78fdac 100644 --- a/www/ungoogled-chromium/files/patch-v8_include_v8config.h +++ b/www/ungoogled-chromium/files/patch-v8_include_v8config.h @@ -1,4 +1,4 @@ ---- v8/include/v8config.h.orig 2022-10-01 07:40:07 UTC +--- v8/include/v8config.h.orig 2023-03-15 07:46:50 UTC +++ v8/include/v8config.h @@ -183,6 +183,8 @@ path. Add it with -I to the command line && !defined(V8_TARGET_OS_FUCHSIA) \ @@ -18,12 +18,10 @@ || defined(V8_TARGET_OS_MACOS) \ || defined(V8_TARGET_OS_WIN) # error A target OS is defined but V8_HAVE_TARGET_OS is unset. -@@ -214,6 +218,16 @@ path. Add it with -I to the command line - - #ifdef V8_OS_LINUX +@@ -216,6 +220,16 @@ path. Add it with -I to the command line # define V8_TARGET_OS_LINUX -+#endif -+ + #endif + +#ifdef V8_OS_OPENBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD @@ -32,6 +30,24 @@ +#ifdef V8_OS_FREEBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD - #endif - ++#endif ++ #ifdef V8_OS_MACOS + # define V8_TARGET_OS_MACOS + #endif +@@ -351,10 +365,14 @@ path. Add it with -I to the command line + // - component builds fail because _dl_runtime_resolve clobbers registers, + // - we see crashes on arm64 on Windows (https://crbug.com/1409934), which can + // hopefully be fixed in the future. ++// Additionally, the initial implementation in clang <= 16 overwrote the return ++// register(s) in the epilogue of a preserve_most function, so we only use ++// preserve_most in clang >= 17 (see https://reviews.llvm.org/D143425). + #if (defined(_M_X64) || defined(__x86_64__) /* x64 (everywhere) */ \ + || ((defined(__AARCH64EL__) || defined(_M_ARM64)) /* arm64, but ... */ \ + && !defined(_WIN32))) /* not on windows */ \ +- && !defined(COMPONENT_BUILD) /* no component build */ ++ && !defined(COMPONENT_BUILD) /* no component build */\ ++ && __clang_major__ >= 17 /* clang >= 17 */ + # define V8_HAS_ATTRIBUTE_PRESERVE_MOST (__has_attribute(preserve_most)) + #endif + # define V8_HAS_ATTRIBUTE_VISIBILITY (__has_attribute(visibility))