Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 12 Nov 2017 20:44:50 +0000 (UTC)
From:      Thierry Thomas <thierry@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r454081 - in head/science/hdf5-18: . files
Message-ID:  <201711122044.vACKiobN019773@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: thierry
Date: Sun Nov 12 20:44:50 2017
New Revision: 454081
URL: https://svnweb.freebsd.org/changeset/ports/454081

Log:
  Fix libhdf5-18.settings and suffix usage in tools.

Added:
  head/science/hdf5-18/files/patch-c++_src_h5c++.in   (contents, props changed)
  head/science/hdf5-18/files/patch-fortran_src_h5fc.in   (contents, props changed)
  head/science/hdf5-18/files/patch-tools_misc_h5cc.in   (contents, props changed)
  head/science/hdf5-18/files/patch-tools_misc_h5redeploy.in   (contents, props changed)
Modified:
  head/science/hdf5-18/Makefile
  head/science/hdf5-18/files/patch-c++_test_Makefile.in   (contents, props changed)
  head/science/hdf5-18/files/patch-fortran_src_Makefile.in   (contents, props changed)
  head/science/hdf5-18/files/patch-fortran_test_Makefile.in   (contents, props changed)
  head/science/hdf5-18/files/patch-hl_c++_test_Makefile.in   (contents, props changed)
  head/science/hdf5-18/files/patch-hl_fortran_test_Makefile.in   (contents, props changed)
  head/science/hdf5-18/files/patch-src-H5FDdirect.c   (contents, props changed)
  head/science/hdf5-18/files/patch-tools_misc_Makefile.in   (contents, props changed)
  head/science/hdf5-18/pkg-plist

Modified: head/science/hdf5-18/Makefile
==============================================================================
--- head/science/hdf5-18/Makefile	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/Makefile	Sun Nov 12 20:44:50 2017	(r454081)
@@ -2,8 +2,8 @@
 # $FreeBSD$
 
 PORTNAME=	hdf5
-PORTVERSION=	1.8.19
-PORTREVISION=	1
+PORTVERSION=	1.8.19 # When PORTVERSION changes, please update french/med/files/patch-configure
+PORTREVISION=	2
 CATEGORIES=	science archivers graphics
 MASTER_SITES=	https://support.hdfgroup.org/ftp/HDF5/current18/src/	\
 		http://support.hdfgroup.org/ftp/HDF5/current18/src/	\
@@ -16,20 +16,26 @@ COMMENT=	Hierarchical Data Format library (from NCSA) 
 LICENSE=	BSD4CLAUSE
 LICENSE_FILE=	${WRKSRC}/COPYING
 
+BROKEN_sparc64=		Does not compile on ${ARCH}
+
 OPTIONS_DEFINE=	DEBUG EXAMPLES FORTRAN SZIP
 
-USES=		libtool:keepla tar:bzip2
+USES=		libtool:keepla localbase tar:bzip2
 USE_LDCONFIG=	yes
 GNU_CONFIGURE=	yes
+PORTSUFF=	${PORTNAME}${PKGNAMESUFFIX}
 CONFIGURE_ARGS=	--enable-cxx \
 		--enable-instrument \
 		--enable-strict-format-checks \
 		--with-pthread=/usr \
 		--with-zlib=/usr \
 		--program-suffix=${PKGNAMESUFFIX} \
-		--includedir=${PREFIX}/include/${PORTNAME}${PKGNAMESUFFIX}
-EXAMPLESDIR=	${PREFIX}/share/examples/${PORTNAME}${PKGNAMESUFFIX}
+		--includedir=${PREFIX}/include/${PORTSUFF}
+EXAMPLESDIR=	${PREFIX}/share/examples/${PORTSUFF}
 
+SUFF2FIX=	tools/misc/h5cc.in tools/misc/h5redeploy.in	\
+		c++/src/h5c++.in fortran/src/h5fc.in
+
 .include <bsd.port.options.mk>
 
 .if ${PORT_OPTIONS:MDEBUG}
@@ -52,12 +58,6 @@ LIB_DEPENDS+=	libsz.so:science/szip
 CONFIGURE_ARGS+=--with-szlib=${LOCALBASE}
 .endif
 
-.include <bsd.port.pre.mk>
-
-.if ${ARCH} == "sparc64"
-BROKEN=		Does not compile on ${ARCH}
-.endif
-
 pre-configure:
 	${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/configure
 	${REINPLACE_CMD} -e 's|-O3||g' ${WRKSRC}/config/gnu-flags
@@ -74,14 +74,21 @@ pre-configure:
 		${REINPLACE_CMD} -e 's|libhdf5|libhdf5${PKGNAMESUFFIX}|g'
 	${REINPLACE_CMD} -e 's|libhdf5|libhdf5${PKGNAMESUFFIX}|g'	\
 		${WRKSRC}/test/testlibinfo.sh.in
+.for pf in ${SUFF2FIX}
+	${REINPLACE_CMD} -e 's|%%SUFF%%|${PKGNAMESUFFIX}|g' ${WRKSRC}/${pf}
+.endfor
 
 post-configure:
 	${CP} -p ${WRKSRC}/src/libhdf5.settings.in	\
 		${WRKSRC}/src/libhdf5${PKGNAMESUFFIX}.settings.in
 	${CP} -p ${WRKSRC}/src/libhdf5.settings		\
 		${WRKSRC}/src/libhdf5${PKGNAMESUFFIX}.settings
+post-stage:
+.if ${PORT_OPTIONS:MFORTRAN}
+	${MV} ${STAGEDIR}${PREFIX}/bin/h5fc ${STAGEDIR}${PREFIX}/bin/h5fc${PKGNAMESUFFIX}
+.endif
 
 regression-test test: build
 	cd ${WRKSRC}/ && ${SETENV} ${MAKE_ENV} ${MAKE} check
 
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>

Added: head/science/hdf5-18/files/patch-c++_src_h5c++.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/hdf5-18/files/patch-c++_src_h5c++.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -0,0 +1,49 @@
+--- c++/src/h5c++.in.orig	2017-06-15 15:46:52 UTC
++++ c++/src/h5c++.in
+@@ -159,7 +159,7 @@ usage() {
+ # libhdf5.settings file reside in the lib directory.
+ showconfigure()
+ {
+-  cat ${libdir}/libhdf5.settings
++  cat ${libdir}/libhdf5%%SUFF%%.settings
+   status=$?
+ }
+ 
+@@ -313,9 +313,9 @@ if test "x$do_link" = "xyes"; then
+   shared_link=""
+   # conditionnaly link with the hl library  
+   if test "X$HL" = "Xhl"; then
+-   libraries=" $libraries -lhdf5_hl_cpp -lhdf5_cpp -lhdf5_hl -lhdf5 "
++   libraries=" $libraries -lhdf5%%SUFF%%_hl_cpp -lhdf5%%SUFF%%_cpp -lhdf5%%SUFF%%_hl -lhdf5%%SUFF%% "
+   else
+-   libraries=" $libraries -lhdf5_cpp -lhdf5 "
++   libraries=" $libraries -lhdf5%%SUFF%%_cpp -lhdf5%%SUFF%% "
+   fi
+   link_args="$link_args -L${libdir}"
+ 
+@@ -345,17 +345,17 @@ if test "x$do_link" = "xyes"; then
+     new_libraries=""
+     for lib in $libraries; do
+       case "$lib" in
+-        -lhdf5)
+-          new_libraries="$new_libraries ${libdir}/libhdf5.a"
++        -lhdf5%%SUFF%%)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%.a"
+           ;;
+-        -lhdf5_hl)
+-          new_libraries="$new_libraries ${libdir}/libhdf5_hl.a"
++        -lhdf5%%SUFF%%_hl)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%_hl.a"
+           ;;
+-        -lhdf5_cpp)
+-          new_libraries="$new_libraries ${libdir}/libhdf5_cpp.a"
++        -lhdf5%%SUFF%%_cpp)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%_cpp.a"
+           ;;
+-        -lhdf5_hl_cpp)
+-          new_libraries="$new_libraries ${libdir}/libhdf5_hl_cpp.a"
++        -lhdf5%%SUFF%%_hl_cpp)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%_hl_cpp.a"
+           ;;
+         *)
+           new_libraries="$new_libraries $lib"

Modified: head/science/hdf5-18/files/patch-c++_test_Makefile.in
==============================================================================
--- head/science/hdf5-18/files/patch-c++_test_Makefile.in	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/files/patch-c++_test_Makefile.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -1,6 +1,6 @@
---- c++/test/Makefile.in.orig	2016-05-10 21:24:51 UTC
+--- c++/test/Makefile.in.orig	2017-06-15 17:14:28 UTC
 +++ c++/test/Makefile.in
-@@ -400,8 +400,7 @@ AMTAR = @AMTAR@
+@@ -408,8 +408,7 @@ AMTAR = @AMTAR@
  AM_CFLAGS = @AM_CFLAGS@ @H5_CFLAGS@
  
  # Include src, test, and c++/src directories

Modified: head/science/hdf5-18/files/patch-fortran_src_Makefile.in
==============================================================================
--- head/science/hdf5-18/files/patch-fortran_src_Makefile.in	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/files/patch-fortran_src_Makefile.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -1,6 +1,6 @@
---- fortran/src/Makefile.in.orig	2016-05-10 21:24:52 UTC
+--- fortran/src/Makefile.in.orig	2017-06-15 17:14:28 UTC
 +++ fortran/src/Makefile.in
-@@ -241,7 +241,7 @@ am__v_FC_1 = 
+@@ -244,7 +244,7 @@ am__v_FC_1 = 
  FCLD = $(FC)
  FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
  	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \

Added: head/science/hdf5-18/files/patch-fortran_src_h5fc.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/hdf5-18/files/patch-fortran_src_h5fc.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -0,0 +1,59 @@
+--- fortran/src/h5fc.in.orig	2017-06-15 15:46:52 UTC
++++ fortran/src/h5fc.in
+@@ -151,10 +151,10 @@ usage() {
+ }
+ 
+ # Show the configuration summary of the library recorded in the
+-# libhdf5.settings file reside in the lib directory.
++# libhdf5%%SUFF%%.settings file reside in the lib directory.
+ showconfigure()
+ {
+-  cat ${libdir}/libhdf5.settings
++  cat ${libdir}/libhdf5%%SUFF%%.settings
+   status=$?
+ }
+ 
+@@ -300,9 +300,9 @@ if test "x$do_link" = "xyes"; then
+   shared_link=""
+ # conditionnaly link with the hl library
+   if test "X$HL" = "Xhl"; then
+-   libraries=" $libraries -lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 "
++   libraries=" $libraries -lhdf5%%SUFF%%hl_fortran -lhdf5%%SUFF%%_hl -lhdf5%%SUFF%%_fortran -lhdf5%%SUFF%% "
+   else
+-   libraries=" $libraries -lhdf5_fortran -lhdf5 "
++   libraries=" $libraries -lhdf5%%SUFF%%_fortran -lhdf5%%SUFF%% "
+   fi
+   link_args="$link_args -L${libdir}"
+ 
+@@ -320,22 +320,22 @@ if test "x$do_link" = "xyes"; then
+   fi
+ 
+   if test "x$USE_SHARED_LIB" != "xyes"; then
+-    # The hdf5 library "-l" flags are in here already.  This is a static
++    # The hdf5%%SUFF%% library "-l" flags are in here already.  This is a static
+     # compile though, so change it to the static versions (.a) of the libraries.
+     new_libraries=""
+     for lib in $libraries; do
+       case "$lib" in
+-        -lhdf5)
+-          new_libraries="$new_libraries ${libdir}/libhdf5.a"
++        -lhdf5%%SUFF%%)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%.a"
+           ;;
+-        -lhdf5_hl)
+-          new_libraries="$new_libraries ${libdir}/libhdf5_hl.a"
++        -lhdf5%%SUFF%%_hl)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%_hl.a"
+           ;;
+-        -lhdf5_fortran)
+-          new_libraries="$new_libraries ${libdir}/libhdf5_fortran.a"
++        -lhdf5%%SUFF%%_fortran)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%_fortran.a"
+           ;;
+-        -lhdf5hl_fortran)
+-          new_libraries="$new_libraries ${libdir}/libhdf5hl_fortran.a"
++        -lhdf5%%SUFF%%hl_fortran)
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%hl_fortran.a"
+           ;;
+         *)
+           new_libraries="$new_libraries $lib"

Modified: head/science/hdf5-18/files/patch-fortran_test_Makefile.in
==============================================================================
--- head/science/hdf5-18/files/patch-fortran_test_Makefile.in	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/files/patch-fortran_test_Makefile.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -1,6 +1,6 @@
---- fortran/test/Makefile.in.orig	2016-05-10 21:24:52 UTC
+--- fortran/test/Makefile.in.orig	2017-06-15 17:14:28 UTC
 +++ fortran/test/Makefile.in
-@@ -150,7 +150,7 @@ fortranlib_test_DEPENDENCIES = libh5test
+@@ -153,7 +153,7 @@ fortranlib_test_DEPENDENCIES = libh5test
  	$(LIBH5F) $(LIBHDF5)
  fortranlib_test_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC \
  	$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(FCLD) \
@@ -9,7 +9,7 @@
  	-o $@
  am_fortranlib_test_1_8_OBJECTS = tH5O.$(OBJEXT) tH5A_1_8.$(OBJEXT) \
  	tH5G_1_8.$(OBJEXT) tH5MISC_1_8.$(OBJEXT) tHDF5_1_8.$(OBJEXT) \
-@@ -219,7 +219,7 @@ am__v_FC_1 = 
+@@ -222,7 +222,7 @@ am__v_FC_1 = 
  FCLD = $(FC)
  FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
  	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \

Modified: head/science/hdf5-18/files/patch-hl_c++_test_Makefile.in
==============================================================================
--- head/science/hdf5-18/files/patch-hl_c++_test_Makefile.in	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/files/patch-hl_c++_test_Makefile.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -1,6 +1,6 @@
---- hl/c++/test/Makefile.in.orig	2016-05-10 21:24:53 UTC
+--- hl/c++/test/Makefile.in.orig	2017-06-15 17:14:28 UTC
 +++ hl/c++/test/Makefile.in
-@@ -395,10 +395,11 @@ AMTAR = @AMTAR@
+@@ -404,10 +404,11 @@ AMTAR = @AMTAR@
  AM_CFLAGS = @AM_CFLAGS@ @H5_CFLAGS@
  
  # Include directories

Modified: head/science/hdf5-18/files/patch-hl_fortran_test_Makefile.in
==============================================================================
--- head/science/hdf5-18/files/patch-hl_fortran_test_Makefile.in	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/files/patch-hl_fortran_test_Makefile.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -1,6 +1,6 @@
---- hl/fortran/test/Makefile.in.orig	2016-05-10 21:24:53 UTC
+--- hl/fortran/test/Makefile.in.orig	2017-06-15 17:14:28 UTC
 +++ hl/fortran/test/Makefile.in
-@@ -160,7 +160,7 @@ am__v_FC_1 = 
+@@ -165,7 +165,7 @@ am__v_FC_1 = 
  FCLD = $(FC)
  FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
  	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \

Modified: head/science/hdf5-18/files/patch-src-H5FDdirect.c
==============================================================================
--- head/science/hdf5-18/files/patch-src-H5FDdirect.c	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/files/patch-src-H5FDdirect.c	Sun Nov 12 20:44:50 2017	(r454081)
@@ -1,6 +1,6 @@
---- ./src/H5FDdirect.c.orig	2011-11-07 14:11:30.000000000 -0800
-+++ ./src/H5FDdirect.c	2011-12-21 16:50:03.000000000 -0800
-@@ -29,6 +29,8 @@
+--- src/H5FDdirect.c.orig	2017-06-15 15:47:13 UTC
++++ src/H5FDdirect.c
+@@ -27,6 +27,8 @@
   * this file. */
  /* #define _XOPEN_SOURCE 600 */
  

Modified: head/science/hdf5-18/files/patch-tools_misc_Makefile.in
==============================================================================
--- head/science/hdf5-18/files/patch-tools_misc_Makefile.in	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/files/patch-tools_misc_Makefile.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -1,6 +1,6 @@
---- tools/misc/Makefile.in.orig	2016-05-10 21:24:56 UTC
+--- tools/misc/Makefile.in.orig	2017-06-15 17:14:30 UTC
 +++ tools/misc/Makefile.in
-@@ -674,7 +674,7 @@ LIBH5CPP_HL = $(top_builddir)/hl/c++/src
+@@ -684,7 +684,7 @@ LIBH5CPP_HL = $(top_builddir)/hl/c++/src
  # Scripts used to build examples
  # If only shared libraries have been installed, have h5cc build examples with
  # shared libraries instead of static libraries
@@ -9,7 +9,7 @@
  H5CC_PP = ${DESTDIR}$(bindir)/h5pcc
  H5FC = ${DESTDIR}$(bindir)/h5fc
  H5FC_PP = ${DESTDIR}$(bindir)/h5pfc
-@@ -715,11 +715,11 @@ DISTCLEANFILES = h5cc testh5repart.sh
+@@ -725,11 +725,11 @@ DISTCLEANFILES = h5cc testh5repart.sh
  
  # All programs rely on hdf5 library and h5tools library
  LDADD = $(LIBH5TOOLS) $(LIBHDF5)
@@ -21,5 +21,5 @@
 -@BUILD_PARALLEL_CONDITIONAL_TRUE@H5CC_NAME = h5pcc
 +@BUILD_PARALLEL_CONDITIONAL_TRUE@H5CC_NAME = h5pcc-18
  
- # Automake needs to be taught how to build lib, progs, and tests targets.
+ # Automake needs to be taught how to build lib, dyn, progs, and tests targets.
  # These will be filled in automatically for the most part (e.g.,

Added: head/science/hdf5-18/files/patch-tools_misc_h5cc.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/hdf5-18/files/patch-tools_misc_h5cc.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -0,0 +1,36 @@
+--- tools/misc/h5cc.in.orig	2017-06-15 15:47:13 UTC
++++ tools/misc/h5cc.in
+@@ -170,7 +170,7 @@ usage() {
+ # libhdf5.settings file reside in the lib directory.
+ showconfigure()
+ {
+-  cat ${libdir}/libhdf5.settings
++  cat ${libdir}/libhdf5%%SUFF%%.settings
+   status=$?
+ }
+ 
+@@ -327,9 +327,9 @@ if test "x$do_link" = "xyes"; then
+   shared_link=""
+ # conditionnaly link with the hl library  
+   if test "X$HL" = "Xhl"; then
+-   libraries=" $libraries -lhdf5_hl -lhdf5 "
++   libraries=" $libraries -lhdf5%%SUFF%%_hl -lhdf5%%SUFF%% "
+   else
+-   libraries=" $libraries  -lhdf5 "
++   libraries=" $libraries  -lhdf5%%SUFF%% "
+   fi
+   link_args="$link_args -L${libdir}"
+ 
+@@ -360,10 +360,10 @@ if test "x$do_link" = "xyes"; then
+     for lib in $libraries; do
+       case "$lib" in
+         -lhdf5)
+-          new_libraries="$new_libraries ${libdir}/libhdf5.a"
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%.a"
+           ;;
+         -lhdf5_hl)
+-          new_libraries="$new_libraries ${libdir}/libhdf5_hl.a"
++          new_libraries="$new_libraries ${libdir}/libhdf5%%SUFF%%_hl.a"
+           ;;
+         *)
+           new_libraries="$new_libraries $lib"

Added: head/science/hdf5-18/files/patch-tools_misc_h5redeploy.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/hdf5-18/files/patch-tools_misc_h5redeploy.in	Sun Nov 12 20:44:50 2017	(r454081)
@@ -0,0 +1,11 @@
+--- tools/misc/h5redeploy.in.orig	2017-06-15 15:47:13 UTC
++++ tools/misc/h5redeploy.in
+@@ -145,7 +145,7 @@ if [ -z "$includedir" ]; then
+     includedir='${prefix}'/include # use single quotes to prevent expansion of $
+ fi
+ 
+-for x in $h5tools; do
++for x in $h5tools%%SUFF%%; do
+     if [ -f $x ]; then
+ 	foundtools="$foundtools $x"
+ 	if [ ! -w $x ]; then

Modified: head/science/hdf5-18/pkg-plist
==============================================================================
--- head/science/hdf5-18/pkg-plist	Sun Nov 12 20:43:29 2017	(r454080)
+++ head/science/hdf5-18/pkg-plist	Sun Nov 12 20:44:50 2017	(r454081)
@@ -6,7 +6,7 @@ bin/h5copy-18
 bin/h5debug-18
 bin/h5diff-18
 bin/h5dump-18
-%%FORTRAN%%bin/h5fc
+%%FORTRAN%%bin/h5fc-18
 bin/h5import-18
 bin/h5jam-18
 bin/h5ls-18



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