On Sat, Feb 19, 2022 at 02:40:24AM -0700, Kurt Mosiejczuk wrote:
> http://build-failures.rhaalovely.net/sparc64/2022-02-16/archivers/fuse-zip.log
> fuse-zip.cpp:492:17: error: 'ENODATA' was not declared in this scope
So ENODATA from /usr/include/c++/v1/errno.h is only defined with
base-clang (I didn't follow the header maze) and a few other ports
already replace ENOADATA with ENOENT or ENOATTR, so do the same except
just pass it along as flags to avoid further patching.
ENOENT is used in fuse-zip, ENOATTR is not, so pick the latter.
Builds and tests fine on sparc64.
Feedback? OK?
Index: Makefile
===================================================================
RCS file: /home/cvs/ports/archivers/fuse-zip/Makefile,v
retrieving revision 1.16
diff -u -p -r1.16 Makefile
--- Makefile 13 Oct 2021 08:49:03 -0000 1.16
+++ Makefile 21 Feb 2022 02:17:23 -0000
@@ -3,6 +3,7 @@
COMMENT = navigate zip archives through FUSE
DISTNAME = fuse-zip-0.7.2
+REVISION = 0
CATEGORIES = archivers
@@ -15,7 +16,14 @@ WANTLIB += ${COMPILER_LIBCXX} c fuse m
MASTER_SITES = https://bitbucket.org/agalanin/fuse-zip/downloads/
-COMPILER = base-clang ports-gcc base-gcc
+COMPILER = base-clang ports-gcc
+
+.include <bsd.port.arch.mk>
+.if !${PROPERTIES:Mclang}
+# fuse-zip.cpp:492:17: error: 'ENODATA' was not declared in this scope
+# only base-clang ends up defining this errno, so use an unused errno instead
+CXXFLAGS += -DENODATA=ENOATTR
+.endif
LIB_DEPENDS = archivers/libzip>=0.11.2