Wednesday, March 06, 2019

Re: UPDATE: netcdf-3.6.2 -> 4.6.3

On Tue, Mar 05, 2019 at 09:57:13PM +0100, Landry Breuil wrote:
>
> So, comments portswise:
> - no need for DIST_SUBDIR=${DISTNAME} (remember to regen distinfo)
> - no need for the complicated DISTNAME/DISTFILES/WRKDIST dance
>
> DISTNAME = ${NAME}-c-${V}
> PKGNAME = ${NAME}-${V}
>
> is enought and seems to work fine here
>
> - i think you forgot to cvs rm patch-cxx_ncvalues_cpp &
> patch-ncgen_ncgen_1 in your diff :)
> - all tests indeed pass, testing on non-x86 would be nice.
> - major should probably be bumped as its a major version
>
> and what matters for me, i can build MDAL fine with this update.
> let's hear what MAINTAINER thinks about it.. maybe the c++ & fortran bits
> should be ported too, but if nothing needs them.. .

Bugged by the failing remote tests I came up with a new diff, which also
includes your comments. Tests all pass on amd64 now.

-m


Index: Makefile
===================================================================
RCS file: /cvs/ports/math/netcdf/Makefile,v
retrieving revision 1.33
diff -u -p -u -p -r1.33 Makefile
--- Makefile 28 Oct 2018 07:31:29 -0000 1.33
+++ Makefile 6 Mar 2019 13:00:28 -0000
@@ -1,45 +1,52 @@
-# $OpenBSD: Makefile,v 1.33 2018/10/28 07:31:29 bentley Exp $
+# $OpenBSD: Makefile,v 1.33 2018/10/28 07:31:29 bentley Exp $

-BROKEN-powerpc= fails to build
-BROKEN-hppa = fails to configure
+# let's give it a chance?
+#BROKEN-powerpc= fails to build
+#BROKEN-hppa = fails to configure

COMMENT= library for machine-independent, array-oriented data access

-DISTNAME= netcdf-3.6.2
-REVISION = 7
+V= 4.6.3
+NAME= netcdf
+DISTNAME= ${NAME}-c-${V}
+PKGNAME= ${NAME}-${V}
+
CATEGORIES= math

-SHARED_LIBS= netcdf 4.0 \
- netcdff 4.0 \
- netcdf_c++ 4.0
+SHARED_LIBS= netcdf 5.0 # 4.0

HOMEPAGE= http://www.unidata.ucar.edu/software/netcdf/

MAINTAINER= Tom Knienieder <tom@knienieder.com>
-MODULES = fortran
-MODFORTRAN_COMPILER = g77
-BUILD_DEPENDS = ${MODFORTRAN_BUILD_DEPENDS}

-# BSD-like
+# BSD
PERMIT_PACKAGE_CDROM= Yes

-WANTLIB= c m ${COMPILER_LIBCXX}
+WANTLIB= c m z pthread
+WANTLIB+= curl crypto nghttp2 ssl
+WANTLIB+= hdf5 hdf5_hl
+
+LIB_DEPENDS = net/curl \
+ math/hdf5
+
+TEST_DEPENDS= shells/bash \
+ textproc/gdiff

COMPILER = base-clang ports-gcc base-gcc

MASTER_SITES= ftp://ftp.unidata.ucar.edu/pub/netcdf/

CONFIGURE_STYLE= gnu
-CONFIGURE_ENV= CPPFLAGS="-Df2cFortran"
+CONFIGURE_ENV+= LDFLAGS="-L${LOCALBASE}/lib" \
+ CPPFLAGS="-I${LOCALBASE}/include"
+
CONFIGURE_ARGS+= --enable-shared \
- --disable-f90
+ --disable-doxygen \
+ --enable-netcdf-4 \
+ --enable-dap \
+ --prefix=${PREFIX}

USE_GMAKE= Yes
SEPARATE_BUILD= Yes
-
-post-install:
- ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/netcdf
- @cd ${WRKSRC}/man && ${INSTALL_DATA} *.txt *.pdf \
- ${PREFIX}/share/doc/netcdf

.include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /cvs/ports/math/netcdf/distinfo,v
retrieving revision 1.6
diff -u -p -u -p -r1.6 distinfo
--- distinfo 18 Jan 2015 03:14:28 -0000 1.6
+++ distinfo 6 Mar 2019 13:00:28 -0000
@@ -1,2 +1,2 @@
-SHA256 (netcdf-3.6.2.tar.gz) = /qp2c/Np5ftX/MUUJuK+aUIo3cwUH8P9IDmSaftrkxE=
-SIZE (netcdf-3.6.2.tar.gz) = 5312882
+SHA256 (netcdf-c-4.6.3.tar.gz) = M1/fFtdTH0MK115zLtGpo/yDrT75H7M6cBGaVV3VQVw=
+SIZE (netcdf-c-4.6.3.tar.gz) = 5961248
Index: patches/patch-cxx_ncvalues_cpp
===================================================================
RCS file: patches/patch-cxx_ncvalues_cpp
diff -N patches/patch-cxx_ncvalues_cpp
--- patches/patch-cxx_ncvalues_cpp 28 Oct 2018 07:31:29 -0000 1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,13 +0,0 @@
-$OpenBSD: patch-cxx_ncvalues_cpp,v 1.1 2018/10/28 07:31:29 bentley Exp $
-
-Index: cxx/ncvalues.cpp
---- cxx/ncvalues.cpp.orig
-+++ cxx/ncvalues.cpp
-@@ -10,6 +10,7 @@
- #include <config.h>
- #include <iostream>
- #include <string>
-+#include <cstring>
-
- #include "ncvalues.h"
-
Index: patches/patch-dap4_test_test_data_sh
===================================================================
RCS file: patches/patch-dap4_test_test_data_sh
diff -N patches/patch-dap4_test_test_data_sh
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-dap4_test_test_data_sh 6 Mar 2019 13:00:28 -0000
@@ -0,0 +1,32 @@
+$OpenBSD$
+
+Index: dap4_test/test_data.sh
+--- dap4_test/test_data.sh.orig
++++ dap4_test/test_data.sh
+@@ -21,8 +21,8 @@ for f in $F ; do
+ fi
+ ${NCDUMP} ./results_test_data/${f}.nc > ./results_test_data/${f}.d4d
+ if test "x${TEST}" = x1 ; then
+- if ! diff -wBb ${BASELINE}/${f}.d4d ./results_test_data/${f}.d4d ; then
+- failure "diff -wBb ${BASELINE}/${f}.d4d ./results_test_data/${f}.d4d"
++ if ! gdiff -wBb ${BASELINE}/${f}.d4d ./results_test_data/${f}.d4d ; then
++ failure "gdiff -wBb ${BASELINE}/${f}.d4d ./results_test_data/${f}.d4d"
+ fi
+ elif test "x${RESET}" = x1 ; then
+ echo "${f}:"
+@@ -77,13 +77,13 @@ if test "x${CDLDIFF}" = x1 ; then
+ echo "Not found: ${CDLTESTFILES}/${STEM}.cdl"
+ continue
+ fi
+- echo "diff -wBb ${CDLTESTFILES}/${STEM}.cdl ./results_test_data/${f}.d4d"
++ echo "gdiff -wBb ${CDLTESTFILES}/${STEM}.cdl ./results_test_data/${f}.d4d"
+ rm -f ./b1 ./b2 ./r1 ./r2
+ trim ${CDLTESTFILES}/${STEM}.cdl ./b1
+ trim ./results_test_data/${f}.d4d ./r1
+ baseclean b1 b2
+ resultclean r1 r2
+- if ! diff -wBb ./b2 ./r2 ; then
++ if ! gdiff -wBb ./b2 ./r2 ; then
+ failure "${f}"
+ fi
+ done
Index: patches/patch-dap4_test_test_meta_sh
===================================================================
RCS file: patches/patch-dap4_test_test_meta_sh
diff -N patches/patch-dap4_test_test_meta_sh
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-dap4_test_test_meta_sh 6 Mar 2019 13:00:28 -0000
@@ -0,0 +1,32 @@
+$OpenBSD$
+
+Index: dap4_test/test_meta.sh
+--- dap4_test/test_meta.sh.orig
++++ dap4_test/test_meta.sh
+@@ -34,8 +34,8 @@ for f in ${F} ; do
+ fi
+ ${NCDUMP} ${DUMPFLAGS} -h ./results_test_meta/${f} > ./results_test_meta/${f}.d4m
+ if test "x${TEST}" = x1 ; then
+- if ! diff -wBb ${BASELINE}/${f}.d4m ./results_test_meta/${f}.d4m ; then
+- failure "diff -wBb ${BASELINE}/${f}.ncdump ./results_test_meta/${f}.d4m"
++ if ! gdiff -wBb ${BASELINE}/${f}.d4m ./results_test_meta/${f}.d4m ; then
++ failure "gdiff -wBb ${BASELINE}/${f}.ncdump ./results_test_meta/${f}.d4m"
+ fi
+ elif test "x${RESET}" = x1 ; then
+ echo "${f}:"
+@@ -45,12 +45,12 @@ done
+
+ if test "x${CDLDIFF}" = x1 ; then
+ for f in $CDL ; do
+- echo "diff -wBb ${CDLTESTFILES}/${f}.cdl ./results_test_meta/${f}.d4m"
++ echo "gdiff -wBb ${CDLTESTFILES}/${f}.cdl ./results_test_meta/${f}.d4m"
+ rm -f ./tmp
+ cat ${CDLTESTFILES}/${f}.cdl \
+ cat >./tmp
+- echo diff -wBbu ./tmp ./results_test_meta/${f}.d4m
+- if ! diff -wBbu ./tmp ./results_test_meta/${f}.d4m ; then
++ echo gdiff -wBbu ./tmp ./results_test_meta/${f}.d4m
++ if ! gdiff -wBbu ./tmp ./results_test_meta/${f}.d4m ; then
+ failure "${f}"
+ fi
+ done
Index: patches/patch-dap4_test_test_parse_sh
===================================================================
RCS file: patches/patch-dap4_test_test_parse_sh
diff -N patches/patch-dap4_test_test_parse_sh
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-dap4_test_test_parse_sh 6 Mar 2019 13:00:28 -0000
@@ -0,0 +1,27 @@
+$OpenBSD$
+
+Index: dap4_test/test_parse.sh
+--- dap4_test/test_parse.sh.orig
++++ dap4_test/test_parse.sh
+@@ -20,18 +20,18 @@ for f in $F ; do
+ failure "${f}"
+ fi
+ if test "x${TEST}" = x1 ; then
+- if ! diff -wBb ${BASELINE}/${f}.d4p ./results_test_parse/${f}.d4p ; then
++ if ! gdiff -wBb ${BASELINE}/${f}.d4p ./results_test_parse/${f}.d4p ; then
+ failure "${f}"
+ fi
+ elif test "x${DIFF}" = x1 ; then
+- echo "diff -wBb ${DMRTESTFILES}/${f}.dmr ./results_test_parse/${f}.d4p"
++ echo "gdiff -wBb ${DMRTESTFILES}/${f}.dmr ./results_test_parse/${f}.d4p"
+ rm -f ./tmp
+ cat ./results_test_parse/${f}.d4p \
+ | sed -e '/<Dimensions>/d' -e '/<Types>'/d -e '/<Variables>'/d -e '/<Groups>'/d \
+ | sed -e '/<\/Dimensions>/d' -e '/<\/Types>'/d -e '/<\/Variables>'/d -e '/<\/Groups>'/d \
+ | sed -e '/_edu.ucar.opaque.size/,+2d' \
+ | cat > ./tmp
+- if ! diff -wBb ${DMRTESTFILES}/${f}.dmr ./tmp ; then
++ if ! gdiff -wBb ${DMRTESTFILES}/${f}.dmr ./tmp ; then
+ failure "${f}"
+ fi
+ elif test "x${RESET}" = x1 ; then
Index: patches/patch-dap4_test_test_raw_sh
===================================================================
RCS file: patches/patch-dap4_test_test_raw_sh
diff -N patches/patch-dap4_test_test_raw_sh
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-dap4_test_test_raw_sh 6 Mar 2019 13:00:28 -0000
@@ -0,0 +1,27 @@
+$OpenBSD$
+
+Index: dap4_test/test_raw.sh
+--- dap4_test/test_raw.sh.orig
++++ dap4_test/test_raw.sh
+@@ -51,8 +51,8 @@ for f in $F ; do
+ failure "${URL}"
+ fi
+ if test "x${TEST}" = x1 ; then
+- if ! diff -wBb ${BASELINERAW}/${f}.dmp ${builddir}/results_test_raw/${f}.dmp ; then
+- failure "diff ${f}.dmp"
++ if ! gdiff -wBb ${BASELINERAW}/${f}.dmp ${builddir}/results_test_raw/${f}.dmp ; then
++ failure "gdiff ${f}.dmp"
+ fi
+ elif test "x${RESET}" = x1 ; then
+ echo "${f}:"
+@@ -60,8 +60,8 @@ for f in $F ; do
+ elif test "x${DIFF}" = x1 ; then
+ echo "hdrtest: ${f}"
+ baseclean
+- if ! diff -wBb ${BASELINERAW}/${f}.dmp ${BASELINE}/${f}.ncdump ; then
+- failure diff -wBb ${BASELINERAW}/${f}.dmp ${BASELINE}/${f}.ncdump
++ if ! gdiff -wBb ${BASELINERAW}/${f}.dmp ${BASELINE}/${f}.ncdump ; then
++ failure gdiff -wBb ${BASELINERAW}/${f}.dmp ${BASELINE}/${f}.ncdump
+ fi
+ fi
+ done
Index: patches/patch-dap4_test_test_remote_sh
===================================================================
RCS file: patches/patch-dap4_test_test_remote_sh
diff -N patches/patch-dap4_test_test_remote_sh
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-dap4_test_test_remote_sh 6 Mar 2019 13:00:28 -0000
@@ -0,0 +1,16 @@
+$OpenBSD$
+
+Index: dap4_test/test_remote.sh
+--- dap4_test/test_remote.sh.orig
++++ dap4_test/test_remote.sh
+@@ -77,8 +77,8 @@ for f in $F ; do
+ failure "${URL}"
+ fi
+ if test "x${TEST}" = x1 ; then
+- if ! diff -wBb "${BASELINEREM}/${f}.dmp" "${builddir}/results_test_remote/${f}.dmp" ; then
+- failure "diff ${f}.dmp"
++ if ! gdiff -wBb "${BASELINEREM}/${f}.dmp" "${builddir}/results_test_remote/${f}.dmp" ; then
++ failure "gdiff ${f}.dmp"
+ fi
+ elif test "x${RESET}" = x1 ; then
+ echo "${f}:"
Index: patches/patch-libdispatch_dfile_c
===================================================================
RCS file: patches/patch-libdispatch_dfile_c
diff -N patches/patch-libdispatch_dfile_c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-libdispatch_dfile_c 6 Mar 2019 13:00:28 -0000
@@ -0,0 +1,13 @@
+$OpenBSD$
+
+Index: libdispatch/dfile.c
+--- libdispatch/dfile.c.orig
++++ libdispatch/dfile.c
+@@ -32,7 +32,6 @@
+ #ifdef HAVE_STDIO_H
+ #include <stdio.h>
+

No comments:

Post a Comment