Hi,
I've spotted this while lurking the sparc64 bulk, netcdf fails to build:
> libdispatch/dfilter.c:681:1: error: static declaration of 'byteswap8'
> follows non-static declaration
(and more)
A pull request has already been made to the upstream GitHub repo [0],
this fixes the build on macppc [1], and amd64 is still fine.
Some patches got regenerated as well :)
Test returns 1 failure on macppc in tst_netcdf4.sh, but this seems
harmless, from the log:
> *** Testing '-s' option for special attributes.
> *** creating special attributes test file tst_special_atts.nc...ok.
> *** Tests successful!
> *** comparing tst_special_atts.cdl with ref_tst_special_atts.cdl...
> 48c48
> < var6:_Endianness = "big" ;
> ---
> > var6:_Endianness = "little" ;
> 51c51
> < var7:_Endianness = "big" ;
> ---
> > var7:_Endianness = "little" ;
> FAIL tst_netcdf4.sh (exit status: 1)
Comments/feedback are welcome,
Charlène.
[0] https://github.com/Unidata/netcdf-c/pull/1688
[1] https://bin.charlenew.xyz/netcdf.log
Index: Makefile
===================================================================
RCS file: /cvs/ports/math/netcdf/Makefile,v
retrieving revision 1.41
diff -u -p -u -p -r1.41 Makefile
--- Makefile 31 Mar 2020 11:57:58 -0000 1.41
+++ Makefile 4 Apr 2020 15:51:38 -0000
@@ -6,7 +6,7 @@ V= 4.7.4
NAME= netcdf
DISTNAME= ${NAME}-c-${V}
PKGNAME= ${NAME}-${V}
-REVISION= 0
+REVISION= 1
CATEGORIES= math
Index: patches/patch-libdispatch_dfilter_c
===================================================================
RCS file: patches/patch-libdispatch_dfilter_c
diff -N patches/patch-libdispatch_dfilter_c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-libdispatch_dfilter_c 4 Apr 2020 15:51:38 -0000
@@ -0,0 +1,19 @@
+$OpenBSD$
+
+Fix build on BE_ARCHS, see:
+https://github.com/Unidata/netcdf-c/pull/1688
+
+Index: libdispatch/dfilter.c
+--- libdispatch/dfilter.c.orig
++++ libdispatch/dfilter.c
+@@ -40,6 +40,10 @@ Unified filter related code
+
+ /* Forward */
+ static int gettype(const int q0, const int q1, int* unsignedp);
++#ifdef WORDS_BIGENDIAN
++static void byteswap8(unsigned char* mem);
++static void byteswap4(unsigned char* mem);
++
No comments:
Post a Comment