Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Aug 2022 05:46:12 GMT
From:      Alexey Dokuchaev <danfe@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: c8cf818032ac - main - archivers/ccmix: unbreak the build against unsigned-by-default char
Message-ID:  <202208120546.27C5kCKu040817@gitrepo.freebsd.org>

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

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

commit c8cf818032ace38110dad09d664406f9d9ebbe92
Author:     Alexey Dokuchaev <danfe@FreeBSD.org>
AuthorDate: 2022-08-12 05:44:22 +0000
Commit:     Alexey Dokuchaev <danfe@FreeBSD.org>
CommitDate: 2022-08-12 05:44:22 +0000

    archivers/ccmix: unbreak the build against unsigned-by-default char
    
    On ARM, PowerPC, RISC-V (of the architectures supported by FreeBSD)
    char type is unsigned by default, which causes the following build
    error due to incorrect array declaration:
    
      mixkey/mix_dexoder.cpp:17:5: error: constant expression evaluates
      to -1 which cannot be narrowed to type 'char' [-Wc++11-narrowing]
---
 archivers/ccmix/Makefile | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/archivers/ccmix/Makefile b/archivers/ccmix/Makefile
index b6b43c06115e..cf79627df9af 100644
--- a/archivers/ccmix/Makefile
+++ b/archivers/ccmix/Makefile
@@ -26,6 +26,8 @@ post-patch:
 	@${REINPLACE_CMD} -e '/ccmix program usage/s,/n,\\n, ; \
 		/gmd_dir/s,/usr/share/ccmix,${DATADIR},' \
 			${WRKSRC}/src/ccmix.cpp
+	@${REINPLACE_CMD} -e '/char2num/s,const static,& signed,' \
+		${WRKSRC}/src/mixkey/mix_dexoder.cpp
 
 do-install:
 	${INSTALL_PROGRAM} ${INSTALL_WRKSRC}/build/* \



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