From owner-dev-commits-ports-main@freebsd.org Wed Sep 15 07:55:12 2021 Return-Path: Delivered-To: dev-commits-ports-main@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 6232867A708; Wed, 15 Sep 2021 07:55:12 +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 4H8XZ81wNYz4kN0; Wed, 15 Sep 2021 07:55:12 +0000 (UTC) (envelope-from git@FreeBSD.org) 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 22BE51E50; Wed, 15 Sep 2021 07:55:12 +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 18F7tCh4032329; Wed, 15 Sep 2021 07:55:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 18F7tC4g032328; Wed, 15 Sep 2021 07:55:12 GMT (envelope-from git) Date: Wed, 15 Sep 2021 07:55:12 GMT Message-Id: <202109150755.18F7tC4g032328@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Dimitry Andric Subject: git: 9a10eff03e91 - main - misc/rump: fix or suppress clang 13 warnings MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dim X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9a10eff03e919e71578cdb66d588b756a0cd1bb6 Auto-Submitted: auto-generated X-BeenThere: dev-commits-ports-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commits to the main branch of the FreeBSD ports repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Sep 2021 07:55:12 -0000 The branch main has been updated by dim (src committer): URL: https://cgit.FreeBSD.org/ports/commit/?id=9a10eff03e919e71578cdb66d588b756a0cd1bb6 commit 9a10eff03e919e71578cdb66d588b756a0cd1bb6 Author: Dimitry Andric AuthorDate: 2021-09-14 21:30:40 +0000 Commit: Dimitry Andric CommitDate: 2021-09-15 07:54:56 +0000 misc/rump: fix or suppress clang 13 warnings Fix a null pointer subtraction bug reported by clang 13, and suppress the new clang 13 -Wunused-but-set-variable warning, as it triggers quite often in the NetBSD src tree. PR: 258508 Approved by: vanilla (maintainer) MFH: 2021Q3 --- misc/rump/Makefile | 10 +++++++--- .../patch-src_sys_crypto_nist__ctr__drbg_nist__ctr__drbg.c | 11 +++++++++++ 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/misc/rump/Makefile b/misc/rump/Makefile index 800233ef0741..3753ec20b7f6 100644 --- a/misc/rump/Makefile +++ b/misc/rump/Makefile @@ -2,7 +2,7 @@ PORTNAME= rump PORTVERSION= 20170822 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= misc MAINTAINER= vanilla@FreeBSD.org @@ -19,6 +19,7 @@ GH_PROJECT= buildrump.sh GH_TAGNAME= b914579 GH_TUPLE= rumpkernel:src-netbsd:82f3a69:netbsd/src USE_LDCONFIG= yes +USES= compiler .include @@ -28,10 +29,13 @@ PLIST_SUB+= X8664="" PLIST_SUB+= X8664="@comment " .endif -CFLAGS+= -Wno-address-of-packed-member +CWARNFLAGS+= -Wno-address-of-packed-member +.if ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 130 +CWARNFLAGS+= -Wno-unused-but-set-variable +.endif do-build: - cd ${WRKSRC}; ${SETENV} CC=${CC} AR=${AR} NM=${NM} OBJCOPY=${OBJCOPY} ./buildrump.sh -F CFLAGS="${CFLAGS}" -r fullbuild + cd ${WRKSRC}; ${SETENV} CC=${CC} AR=${AR} NM=${NM} OBJCOPY=${OBJCOPY} ./buildrump.sh -F CFLAGS="${CFLAGS}" -F CWARNFLAGS="${CWARNFLAGS}" -r fullbuild do-install: cd ${WRKSRC}/rump; ${PAX} -wr lib include ${STAGEDIR}${PREFIX}/ diff --git a/misc/rump/files/patch-src_sys_crypto_nist__ctr__drbg_nist__ctr__drbg.c b/misc/rump/files/patch-src_sys_crypto_nist__ctr__drbg_nist__ctr__drbg.c new file mode 100644 index 000000000000..197b981cebeb --- /dev/null +++ b/misc/rump/files/patch-src_sys_crypto_nist__ctr__drbg_nist__ctr__drbg.c @@ -0,0 +1,11 @@ +--- src/sys/crypto/nist_ctr_drbg/nist_ctr_drbg.c.orig 2016-08-02 11:51:10 UTC ++++ src/sys/crypto/nist_ctr_drbg/nist_ctr_drbg.c +@@ -153,7 +153,7 @@ typedef struct { + static inline int + check_int_alignment(const void *p) + { +- intptr_t ip = (const char *)p - (const char *)0; ++ intptr_t ip = (intptr_t)p; + + if (ip & (sizeof(int) - 1)) + return 0;