Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Dec 2024 14:00:53 GMT
From:      Piotr Kubaj <pkubaj@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 0f3e16d9b5ba - main - devel/benchmark: fix build on powerpc
Message-ID:  <202412311400.4BVE0rPH053774@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by pkubaj:

URL: https://cgit.FreeBSD.org/ports/commit/?id=0f3e16d9b5baec882f0b5ca7742f31b4a25a3ae6

commit 0f3e16d9b5baec882f0b5ca7742f31b4a25a3ae6
Author:     Piotr Kubaj <pkubaj@FreeBSD.org>
AuthorDate: 2024-12-31 12:08:41 +0000
Commit:     Piotr Kubaj <pkubaj@FreeBSD.org>
CommitDate: 2024-12-31 14:00:04 +0000

    devel/benchmark: fix build on powerpc
    
    Issue in powerpc-specific code:
    In file included from /wrkdirs/usr/ports/devel/benchmark/work/benchmark-1.9.0/src/sysinfo.cc:78:
    /wrkdirs/usr/ports/devel/benchmark/work/benchmark-1.9.0/src/cycleclock.h:99:10: error: implicit conversion changes signedness: 'int32_t' (aka 'int') to 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-conversion]
       99 |   tbl &= -static_cast<int32_t>(tbu0 == tbu1);
          |       ~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    /wrkdirs/usr/ports/devel/benchmark/work/benchmark-1.9.0/src/cycleclock.h:101:46: error: implicit conversion changes signedness: 'uint64_t' (aka 'unsigned long long') to 'int64_t' (aka 'long long') [-Werror,-Wsign-conversion]
      101 |   return (static_cast<uint64_t>(tbu1) << 32) | tbl;
          |   ~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
    2 errors generated.
---
 devel/benchmark/Makefile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/devel/benchmark/Makefile b/devel/benchmark/Makefile
index a8d7f630e4e4..6a7c49430759 100644
--- a/devel/benchmark/Makefile
+++ b/devel/benchmark/Makefile
@@ -23,6 +23,7 @@ CMAKE_OFF=	BENCHMARK_ENABLE_TESTING
 CMAKE_TESTING_ON=	BENCHMARK_ENABLE_TESTING # BENCHMARK_DOWNLOAD_DEPENDENCIES
 CMAKE_TESTING_ARGS=	-DGOOGLETEST_PATH=${WRKSRC_googletest}
 
+CFLAGS+=	-Wno-error=sign-conversion
 CXXFLAGS+=	${CXXFLAGS_${CHOSEN_COMPILER_TYPE}}
 CXXFLAGS_gcc=	-Wno-stringop-truncation
 PIE_UNSAFE=	yes



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202412311400.4BVE0rPH053774>