Compare commits

...

12 Commits

Author SHA1 Message Date
Orion Poplawski
aa4fa87940 Sync from devel 2010-03-02 20:55:00 +00:00
Bill Nottingham
3652f46dcf Fix typo that causes a failure to update the common directory. (releng
#2781)
2009-11-26 01:17:15 +00:00
Orion Poplawski
970fab88e4 Update to 4.2r4 synced from devel 2009-09-18 17:23:18 +00:00
Balint Cristian
59a2f49aeb - further fix for RHEL5
----------------------------------------------------------------------
    Modified Files: EL-4/hdf.spec
----------------------------------------------------------------------
2008-05-28 18:48:10 +00:00
Balint Cristian
870e8be3c1 - new bugfix upstream
----------------------------------------------------------------------
    Modified Files: EL-4/.cvsignore EL-4/hdf.spec EL-4/sources Added Files:
    EL-4/hdf-4.2r2-libm.patch EL-4/hdf-4.2r2-s390.patch
    EL-4/hdf-4.2r2-sparc.patch EL-4/hdf-4.2r3-ppc.patch Removed Files:
    EL-4/hdf-4.2r1-ppc.patch
----------------------------------------------------------------------
2008-05-28 17:47:31 +00:00
Orion Poplawski
f47bf1ea27 Remove unneeded netcdl-devel requires 2007-05-24 15:48:07 +00:00
Orion Poplawski
79f6cb183e - Use 4.2r1-hrepack-p4.tar.gz for hrepack patch
- Remove configure patch applied upstream
- Use --disable-production configure flag to avoid stripping -g compile
    flag
- Add patch to fix open file test when run under mock
2007-04-20 21:19:18 +00:00
Dennis Gilmore
762469f747 Initialize branch EL-4 for hdf 2007-04-19 23:21:48 +00:00
Orion Poplawski
d9c6255511 Remove empty post/postun scripts 2006-06-11 22:08:23 +00:00
Orion Poplawski
a3240c6b38 Add Requires netcdf-devel for hdf-devel (bug #189337) 2006-04-20 22:16:26 +00:00
pertusus
facb202caa Don't set explicitly F77 and FFLAGS 2006-02-24 23:51:25 +00:00
pertusus
1ae5fef006 - use gcc-g77 instead of gcc-gfortran
- sync with FC-4 spec file instead of devel
It is associated with a version lowering (from 9 to 6). A tag allready
    exists for the version 9.
2006-02-24 20:45:03 +00:00
11 changed files with 1694 additions and 137 deletions

View File

@ -1,2 +1 @@
4.2r1-hrepack-patch.tar
HDF4.2r1.tar.gz
hdf-4.2.5.tar.bz2

View File

@ -1,10 +1,10 @@
# Makefile for source rpm: hdf
# $Id$
# $Id: Makefile,v 1.1 2005/07/25 18:00:27 orion Exp $
NAME := hdf
SPECFILE = $(firstword $(wildcard *.spec))
define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef
MAKEFILE_COMMON := $(shell $(find-makefile-common))

1
branch Normal file
View File

@ -0,0 +1 @@
EL-4

1161
hdf-4.2.4-ppc.patch Normal file

File diff suppressed because it is too large Load Diff

348
hdf-4.2.4-s390.patch Normal file
View File

@ -0,0 +1,348 @@
diff -up hdf-4.2.4-snap8/hdf/src/hdfi.h.s390 hdf-4.2.4-snap8/hdf/src/hdfi.h
--- hdf-4.2.4-snap8/hdf/src/hdfi.h.s390 2010-02-01 13:28:25.387386871 -0700
+++ hdf-4.2.4-snap8/hdf/src/hdfi.h 2010-02-01 13:31:46.343387138 -0700
@@ -78,6 +78,7 @@
#define DFMT_POWERPC64 0x1111
#define DFMT_LINUXPPC 0x1111
#define DFMT_LINUXSPARC 0x1111
+#define DFMT_LINUX390 0x1111
/* I/O library constants */
#define UNIXUNBUFIO 1
@@ -1453,6 +1454,66 @@ typedef int hdf_pint_t;
#endif /* Linux Sparc32/64 */
+/* Linux s390/s390x */
+#if defined __s390__ || defined __s390x__
+
+#ifdef GOT_MACHINE
+If you get an error on this line more than one machine type has been defined.
+Please check your Makefile.
+#endif
+#define GOT_MACHINE
+
+#include <sys/file.h> /* for unbuffered i/o stuff */
+#include <sys/stat.h>
+#define DF_MT DFMT_LINUX390
+typedef void VOID;
+typedef void *VOIDP;
+typedef char *_fcd;
+typedef char char8;
+typedef unsigned char uchar8;
+typedef char int8;
+typedef unsigned char uint8;
+typedef short int int16;
+typedef unsigned short int uint16;
+#ifdef __s390x__ /* 64-bit environment */
+typedef int int32;
+typedef unsigned int uint32;
+#else /* 32-bit environment */
+typedef long int int32;
+typedef unsigned long int uint32;
+#endif
+typedef int intn;
+typedef unsigned int uintn;
+typedef int intf; /* size of INTEGERs in Fortran compiler */
+typedef float float32;
+typedef double float64;
+#ifdef __s390x__ /* 64-bit environment */
+typedef long hdf_pint_t; /* an integer the same size as a pointer */
+#else /* 32-bit environment */
+typedef int hdf_pint_t; /* an integer the same size as a pointer */
+#endif
+#define FNAME_POST_UNDERSCORE
+#define _fcdtocp(desc) (desc)
+#ifdef HAVE_FMPOOL
+#define FILELIB PAGEBUFIO /* enable page buffering */
+#else
+#define FILELIB UNIXBUFIO
+#endif
+
+/* JPEG #define's - Look in the JPEG docs before changing - (Q) */
+
+/* Determine the memory manager we are going to use. Valid values are: */
+/* MEM_DOS, MEM_ANSI, MEM_NAME, MEM_NOBS. See the JPEG docs for details on */
+/* what each does */
+#define JMEMSYS MEM_ANSI
+
+#ifdef __GNUC__
+#define HAVE_STDC
+#define INCLUDES_ARE_ANSI
+#endif
+
+#endif /* Linux s390/s390x */
+
/*-----------------------------------------------------*/
/* 64-bit Free BSD */
diff -up hdf-4.2.4-snap8/mfhdf/fortran/config/jackets-linux.c.s390 hdf-4.2.4-snap8/mfhdf/fortran/config/jackets-linux.c
--- hdf-4.2.4-snap8/mfhdf/fortran/config/jackets-linux.c.s390 2010-02-01 13:28:25.373389124 -0700
+++ hdf-4.2.4-snap8/mfhdf/fortran/config/jackets-linux.c 2010-02-01 13:28:25.419387130 -0700
@@ -34,7 +34,7 @@
struct ncfils { /* This will be a common block from Fortran */
double dd;
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
int ll;
#else
long ll;
@@ -65,7 +65,7 @@ struct ncfils { /* This will be a comm
struct ncfils { /* This will be a common block from Fortran */
double dd;
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
int ll;
#else
long ll;
@@ -430,7 +430,7 @@ stoig(shorts, ints, dims, basis, ndims)
}
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
/*
* Convert multi-dimensional array of NCLONGs stored in ints to packed
* array of longs, in malloc'ed space. Returns pointer to longs or NULL
@@ -916,7 +916,7 @@ nncvpt1(cdfid, varid, indices, value, rc
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) datatype == NC_LONG && handle->file_type!=HDF_FILE) {
long longs = *(int *)value;
@@ -1030,7 +1030,7 @@ nncvpt(cdfid, varid, start, count, value
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) datatype == NC_LONG && handle->file_type!=HDF_FILE) {
long *longs = itol (value, ncount, ndims);
@@ -1141,7 +1141,7 @@ nncvptg(cdfid, varid, start, count, stri
tmpbasis = nctypelen(NC_LONG);
else
#endif
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
if (datatype == NC_LONG)
tmpbasis = sizeof(int);
else
@@ -1198,7 +1198,7 @@ nncvptg(cdfid, varid, start, count, stri
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) datatype == NC_LONG && handle->file_type!=HDF_FILE) {
long *longs = itolg (value, ncount, nbasis, ndims);
@@ -1334,7 +1334,7 @@ nncvgt1(cdfid, varid, indices, value, rc
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) datatype == NC_LONG && handle->file_type!=HDF_FILE) {
long longs;
@@ -1476,7 +1476,7 @@ nncvgt(cdfid, varid, start, count, value
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) datatype == NC_LONG && handle->file_type!=HDF_FILE) {
long iocount = dimprod (ncount, ndims); /* product of dimensions */
@@ -1614,7 +1614,7 @@ nncvgtg(cdfid, varid, start, count, stri
tmpbasis = nctypelen(NC_LONG);
else
#endif
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
if (datatype == NC_LONG)
tmpbasis = sizeof(int);
else
@@ -1685,7 +1685,7 @@ nncvgtg(cdfid, varid, start, count, stri
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) datatype == NC_LONG && handle->file_type!=HDF_FILE) {
long iocount = dimprod (ncount, ndims); /* product of dimensions */
@@ -1851,7 +1851,7 @@ nncapt(cdfid, varid, attname, datatype,
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) *datatype == NC_LONG && handle->file_type!=HDF_FILE) {
long *longs = itol (value, attlen, 1);
@@ -2016,7 +2016,7 @@ nncagt(cdfid, varid, attname, value, rco
return;
} /* else */
#endif /* FORTRAN_HAS_NO_SHORT */
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
#ifdef HDF
if ((nc_type) datatype == NC_LONG && handle->file_type!=HDF_FILE) {
/* EIP We need to use int buffer to read data in on the platforms where long is 8 bytes
diff -up hdf-4.2.4-snap8/mfhdf/libsrc/array.c.s390 hdf-4.2.4-snap8/mfhdf/libsrc/array.c
--- hdf-4.2.4-snap8/mfhdf/libsrc/array.c.s390 2010-01-17 21:24:53.000000000 -0700
+++ hdf-4.2.4-snap8/mfhdf/libsrc/array.c 2010-02-01 13:28:25.422387595 -0700
@@ -622,7 +622,7 @@ xdr_NC_array(xdrs, app)
case NC_LONG :
#if defined _CRAYMPP
xdr_NC_fnct = xdr_short;
-#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
xdr_NC_fnct = xdr_int ;
#else
xdr_NC_fnct = xdr_long ;
diff -up hdf-4.2.4-snap8/mfhdf/libsrc/cdf.c.s390 hdf-4.2.4-snap8/mfhdf/libsrc/cdf.c
--- hdf-4.2.4-snap8/mfhdf/libsrc/cdf.c.s390 2010-01-17 21:24:53.000000000 -0700
+++ hdf-4.2.4-snap8/mfhdf/libsrc/cdf.c 2010-02-01 13:28:25.424387272 -0700
@@ -3657,7 +3657,7 @@ NC_var *vp ;
alen /= 4 ;
#if defined _CRAYMPP
xdr_NC_fnct = xdr_short;
-#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
xdr_NC_fnct = xdr_int ;
#else
xdr_NC_fnct = xdr_long ;
diff -up hdf-4.2.4-snap8/mfhdf/libsrc/config/netcdf-linux.h.s390 hdf-4.2.4-snap8/mfhdf/libsrc/config/netcdf-linux.h
--- hdf-4.2.4-snap8/mfhdf/libsrc/config/netcdf-linux.h.s390 2010-02-01 13:28:25.380387278 -0700
+++ hdf-4.2.4-snap8/mfhdf/libsrc/config/netcdf-linux.h 2010-02-01 13:28:25.418387640 -0700
@@ -304,7 +304,7 @@ typedef double ncdouble;
*/
#if defined _CRAYMPP
typedef short nclong;
-#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined __x86_64__ || defined __powerpc64__
+#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
typedef int nclong;
#else
typedef long nclong; /* default, compatible type */
diff -up hdf-4.2.4-snap8/mfhdf/libsrc/netcdf.h.in.s390 hdf-4.2.4-snap8/mfhdf/libsrc/netcdf.h.in
--- hdf-4.2.4-snap8/mfhdf/libsrc/netcdf.h.in.s390 2010-02-01 13:28:25.380387278 -0700
+++ hdf-4.2.4-snap8/mfhdf/libsrc/netcdf.h.in 2010-02-01 13:28:25.417387775 -0700
@@ -295,7 +295,7 @@ typedef double ncdouble;
*/
#if defined _CRAYMPP
typedef short nclong;
-#elif defined __alpha || (_MIPS_SZLONG == 64) || defined IA64 || (defined __sun__ && defined _LP64) || defined AIX5L64 || defined __powerpc64__
+#elif defined __alpha || (_MIPS_SZLONG == 64) || defined IA64 || (defined __sun__ && defined _LP64) || defined AIX5L64 || defined __powerpc64__ || defined __s390x__
typedef int nclong;
#else
typedef long nclong; /* default, compatible type */
diff -up hdf-4.2.4-snap8/mfhdf/libsrc/putget.c.s390 hdf-4.2.4-snap8/mfhdf/libsrc/putget.c
--- hdf-4.2.4-snap8/mfhdf/libsrc/putget.c.s390 2010-01-17 21:24:53.000000000 -0700
+++ hdf-4.2.4-snap8/mfhdf/libsrc/putget.c 2010-02-01 13:28:25.421386028 -0700
@@ -652,7 +652,7 @@ Void *values ;
case NC_LONG :
#if defined _CRAYMPP
return( xdr_short(xdrs, (nclong *)values) ) ;
-#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
return( xdr_int(xdrs, (nclong *)values) ) ;
#else
return( xdr_long(xdrs, (nclong *)values) ) ;
@@ -1966,7 +1966,7 @@ Void *values ;
case NC_LONG :
#if defined _CRAYMPP
xdr_NC_fnct = xdr_short;
-#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#elif defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
xdr_NC_fnct = xdr_int ;
#else
xdr_NC_fnct = xdr_long ;
diff -up hdf-4.2.4-snap8/mfhdf/libsrc/xdrposix.c.s390 hdf-4.2.4-snap8/mfhdf/libsrc/xdrposix.c
--- hdf-4.2.4-snap8/mfhdf/libsrc/xdrposix.c.s390 2010-01-17 21:24:53.000000000 -0700
+++ hdf-4.2.4-snap8/mfhdf/libsrc/xdrposix.c 2010-02-01 13:28:25.425387348 -0700
@@ -283,7 +283,7 @@ int nbytes;
static bool_t xdrposix_getlong();
static bool_t xdrposix_putlong();
-#if (_MIPS_SZLONG == 64) || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if (_MIPS_SZLONG == 64) || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
static bool_t xdrposix_getint();
static bool_t xdrposix_putint();
#endif
@@ -300,7 +300,7 @@ static long * xdrposix_inline();
#if (defined __sun && defined _LP64)
static rpc_inline_t * xdrposix_inline();
#else
-#if ((defined __x86_64__ ) && !(defined __sun && defined _LP64)) || defined __powerpc64__
+#if ((defined __x86_64__ ) && !(defined __sun && defined _LP64)) || defined __powerpc64__ || defined __s390x__
static int32_t * xdrposix_inline();
#else
#if (defined __alpha )
@@ -331,9 +331,9 @@ static struct xdr_ops xdrposix_ops = {
xdrposix_getpos, /* get offset in the stream */
xdrposix_setpos, /* set offset in the stream */
xdrposix_inline, /* prime stream for inline macros */
-#if (defined __sun && defined _LP64) || defined __x86_64__ || defined __powerpc64__
+#if (defined __sun && defined _LP64) || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
xdrposix_destroy, /* destroy stream */
-#if !(defined __x86_64__) && !(defined __powerpc64__) || (defined __sun && defined _LP64) /* i.e. we are on SUN/Intel in 64-bit mode */
+#if !(defined __s390x__) && !(defined __x86_64__) && !(defined __powerpc64__) || (defined __sun && defined _LP64) /* i.e. we are on SUN/Intel in 64-bit mode */
NULL, /* no xdr_control function defined */
#endif
/* Solaris 64-bit (arch=v9 and arch=amd64) has 64 bits long and 32 bits int. */
@@ -468,7 +468,7 @@ xdrposix_getlong(xdrs, lp)
#endif
{
unsigned char *up = (unsigned char *)lp ;
-#if (defined CRAY || defined AIX5L64 || defined __powerpc64__ || (defined __hpux && __LP64__))
+#if (defined CRAY || defined AIX5L64 || defined __powerpc64__ || defined __s390x__ || (defined __hpux && __LP64__))
*lp = 0 ;
up += (sizeof(long) - 4) ;
#endif
@@ -495,7 +495,7 @@ xdrposix_putlong(xdrs, lp)
netlong mycopy = htonl(*lp);
up = (unsigned char *)&mycopy;
#endif
-#if (defined CRAY || defined AIX5L64 || defined __powerpc64__ || (defined __hpux && __LP64__))
+#if (defined CRAY || defined AIX5L64 || defined __powerpc64__ || defined __s390x__ || (defined __hpux && __LP64__))
up += (sizeof(long) - 4) ;
#endif
@@ -592,7 +592,7 @@ static rpc_inline_t *
#if (defined __alpha)
static int*
#else
-#if ((defined __x86_64__) && !(defined __sun && defined _LP64)) || defined __powerpc64__
+#if ((defined __x86_64__) && !(defined __sun && defined _LP64)) || defined __powerpc64__ || defined __s390x__
static int32_t *
#else
static netlong *
@@ -621,7 +621,7 @@ int
return (NULL);
}
-#if (_MIPS_SZLONG == 64) || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if (_MIPS_SZLONG == 64) || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
static bool_t
xdrposix_getint(xdrs, lp)
diff -up hdf-4.2.4-snap8/mfhdf/ncgen/ncgen.l.s390 hdf-4.2.4-snap8/mfhdf/ncgen/ncgen.l
--- hdf-4.2.4-snap8/mfhdf/ncgen/ncgen.l.s390 2010-02-01 13:28:25.381387100 -0700
+++ hdf-4.2.4-snap8/mfhdf/ncgen/ncgen.l 2010-02-01 13:28:25.420387234 -0700
@@ -134,7 +134,7 @@ FloatInf|Infinity|Inf { /* float miss
yyerror(errstr);
}
-#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__
+#if defined __alpha || (_MIPS_SZLONG == 64) || defined __ia64 || (defined __sun && defined _LP64) || defined AIX5L64 || defined __x86_64__ || defined __powerpc64__ || defined __s390x__
if (dd < INT_MIN || dd > INT_MAX)
#else
#if defined (_CRAYMPP)

View File

@ -1,19 +1,20 @@
--- HDF4.2r1/hdf/src/hdfi.h.orig 2005-01-24 20:36:44.000000000 -0700
+++ HDF4.2r1/hdf/src/hdfi.h 2006-02-02 21:54:59.347516688 -0700
@@ -72,6 +72,7 @@
#define DFMT_CRAYMPP 0x1171
#define DFMT_IA64 0x4441
diff -up hdf-4.2.4-snap8/hdf/src/hdfi.h.sparc hdf-4.2.4-snap8/hdf/src/hdfi.h
--- hdf-4.2.4-snap8/hdf/src/hdfi.h.sparc 2010-02-01 13:28:25.361387271 -0700
+++ hdf-4.2.4-snap8/hdf/src/hdfi.h 2010-02-01 13:31:46.343387138 -0700
@@ -77,6 +77,7 @@
#define DFMT_LINUX64 0x4441
+#define DFMT_LINUXPPC 0x1111
#define DFMT_POWERPC64 0x1111
#define DFMT_LINUXPPC 0x1111
+#define DFMT_LINUXSPARC 0x1111
/* I/O library constants */
#define UNIXUNBUFIO 1
@@ -1326,6 +1327,57 @@
@@ -1392,6 +1393,66 @@ typedef long hdf_pint_t;
#endif /*Linux 64 */
#endif /*Linux PPC */
+/* Linux PPC */
+#if defined __PPC__
+/* Linux Sparc32/64 */
+#if defined __sparc__ || defined __sparc64__
+
+#ifdef GOT_MACHINE
+If you get an error on this line more than one machine type has been defined.
@ -33,14 +34,23 @@
+typedef unsigned char uint8;
+typedef short int int16;
+typedef unsigned short int uint16;
+#ifdef _LP64 /* 64-bit environment */
+typedef int int32;
+typedef unsigned int uint32;
+#else /* 32-bit environment */
+typedef long int int32;
+typedef unsigned long int uint32;
+#endif
+typedef int intn;
+typedef unsigned int uintn;
+typedef int intf; /* size of INTEGERs in Fortran compiler */
+typedef float float32;
+typedef double float64;
+#ifdef _LP64 /* 64-bit environment */
+typedef long hdf_pint_t; /* an integer the same size as a pointer */
+#else /* 32-bit environment */
+typedef int hdf_pint_t; /* an integer the same size as a pointer */
+#endif
+#define FNAME_POST_UNDERSCORE
+#define _fcdtocp(desc) (desc)
+#ifdef HAVE_FMPOOL
@ -61,8 +71,8 @@
+#define INCLUDES_ARE_ANSI
+#endif
+
+#endif /*Linux PPC */
+#endif /* Linux Sparc32/64 */
+
/*#ifndef GOT_MACHINE
No machine type has been defined. Your Makefile needs to have someing like
-DSUN or -DUNICOS in order for the HDF internal structures to be defined
/*-----------------------------------------------------*/
/* 64-bit Free BSD */

View File

@ -0,0 +1,11 @@
--- hdf-4.2.5-pre1/mfhdf/libsrc/file.c.maxavailfiles 2010-02-06 10:40:42.000000000 -0700
+++ hdf-4.2.5-pre1/mfhdf/libsrc/file.c 2010-02-09 13:53:09.600285597 -0700
@@ -51,7 +51,7 @@
be in hlimits.h file in the future. EIP 2010-02-01*/
#define H4_MAX_AVAIL_OPENFILES 20000
-#define MAX_AVAIL_OPENFILES (((MAX_SYS_OPENFILES - 3) > H4_MAX_AVAIL_OPENFILES) ? H4_MAX_AVAIL_OPENFILES : (MAX_SYS_OPENFILES - 3))
+#define MAX_AVAIL_OPENFILES (((MAX_SYS_OPENFILES - 10) > H4_MAX_AVAIL_OPENFILES) ? H4_MAX_AVAIL_OPENFILES : (MAX_SYS_OPENFILES - 10))
static int _curr_opened = 0 ; /* the number of files currently opened */
/* NOTE: _ncdf might have been the number of files currently opened, yet it

View File

@ -1,92 +0,0 @@
--- HDF4.2r1/configure.ac.orig 2005-07-15 14:52:14.000000000 -0600
+++ HDF4.2r1/configure.ac 2005-07-15 14:53:35.000000000 -0600
@@ -528,7 +528,7 @@
dnl ======================================================================
AC_MSG_CHECKING([for math library support])
-AC_TRY_LINK([#include <math.h>], [sqrt(37.927)],
+AC_TRY_LINK([#include <math.h>], [sinh(37.927)],
[AC_MSG_RESULT([yes])],
[AC_MSG_RESULT([no]); LIBS="$LIBS -lm"])
--- HDF4.2r1/mfhdf/fortran/config/ftest-linux.f.orig 2005-02-08 20:04:07.000000000 -0700
+++ HDF4.2r1/mfhdf/fortran/config/ftest-linux.f 2005-07-15 15:37:22.000000000 -0600
@@ -138,13 +138,13 @@
integer*2 shval(2)
integer i, j, k
character*31 varnam, attname(2,7), gattnam(2)
- byte bytval(2)
+ integer*1 bytval(2)
common /atts/attname, gattnam
integer*2 svalidrg(2)
real rvalidrg(2)
integer lvalidrg(2)
double precision dvalidrg(2)
- byte bvalidrg(2)
+ integer*1 bvalidrg(2)
character*31 gavalue(2), cavalue(2)
real epsilon
@@ -337,7 +337,7 @@
real flval(2)
integer lngval(2)
integer*2 shval(2)
- byte bytval(2)
+ integer*1 bytval(2)
integer vartyp, nvdims, vdims(MAXVDIMS), nvatts
character*31 varnam, attname(2,7), gattnam(2)
@@ -346,7 +346,7 @@
real rvalidrg(2)
integer lvalidrg(2)
double precision dvalidrg(2)
- byte bvalidrg(2)
+ integer*1 bvalidrg(2)
character*31 gavalue(2), cavalue(2)
real epsilon
@@ -470,7 +470,7 @@
real rvalidrg(2)
integer lvalidrg(2)
double precision dvalidrg(2)
- byte bvalidrg(2)
+ integer*1 bvalidrg(2)
c variable ids
integer bid, sid, lid, fid, did, cid, chid
@@ -883,7 +883,7 @@
integer itime, ilev, ilat, ilon
c arrays of data values to be read
- byte barray(times), byval(times)
+ integer*1 barray(times), byval(times)
integer*2 sarray(times), shval(times)
integer larray(lats)
real farray(levels, lats, lons, times)
@@ -1009,7 +1009,7 @@
integer bid, sid, lid, fid, did, cid, chid
common /vars/bid, sid, lid, fid, did, cid, chid
- byte bvalue
+ integer*1 bvalue
integer*2 svalue
integer lvalue
real fvalue
@@ -1097,7 +1097,7 @@
integer count(MAXNCDIM)
c arrays of data values to be written
- byte barray(times)
+ integer*1 barray(times)
integer*2 sarray(times)
integer larray(lats)
real farray(levels, lats, lons, times)
@@ -1184,7 +1184,7 @@
integer lvalue
integer*2 svalue
- byte bvalue
+ integer*1 bvalue
double precision onethird
integer bid, sid, lid, fid, did, cid, chid
common /vars/bid, sid, lid, fid, did, cid, chid

168
hdf.spec
View File

@ -1,17 +1,23 @@
Name: hdf
Version: 4.2r1
Release: 9%{?dist}
Version: 4.2.5
Release: 1%{?dist}
Summary: A general purpose library and file format for storing scientific data
License: BSD-ish
License: BSD
Group: System Environment/Libraries
URL: http://hdf.ncsa.uiuc.edu/hdf4.html
Source0: ftp://ftp.ncsa.uiuc.edu/HDF/HDF/HDF_Current/src/HDF%{version}.tar.gz
Source1: ftp://ftp.ncsa.uiuc.edu/HDF/HDF/HDF_Current/src/patches/4.2r1-hrepack-patch.tar
Patch0: hdf-4.2r1-configure.patch
Patch1: hdf-4.2r1-ppc.patch
URL: http://hdfgroup.org/products/hdf4/index.html
Source0: ftp://ftp.hdfgroup.org/HDF/HDF_Current/src/%{name}-%{version}.tar.bz2
Patch0: hdf-4.2.5-maxavailfiles.patch
Patch1: hdf-4.2.4-ppc.patch
Patch2: hdf-4.2.4-sparc.patch
Patch3: hdf-4.2.4-s390.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: autoconf flex byacc libjpeg-devel zlib-devel
BuildRequires: flex byacc libjpeg-devel zlib-devel
%if "%{?dist}" != ".el4"
BuildRequires: gcc-gfortran
%else
BuildRequires: gcc-g77
%endif
%description
HDF is a general purpose library and file format for storing scientific data.
@ -22,49 +28,80 @@ objects, one can create and store almost any kind of scientific data
structure, such as images, arrays of vectors, and structured and unstructured
grids. You can also mix and match them in HDF files according to your needs.
%package devel
Summary: HDF development files
Group: Development/Libraries
Provides: %{name}-static = %{version}-%{release}
Requires: %{name} = %{version}-%{release}
Requires: libjpeg-devel zlib-devel
%description devel
HDF development headers and libraries.
%prep
%setup -q -n HDF%{version}
tar xf %{SOURCE1} --directory mfhdf/hrepack
mv mfhdf/hrepack/4.2r1-hrepack-patch/*.[ch] mfhdf/hrepack
rm -r mfhdf/hrepack/4.2r1-hrepack-patch
%patch0 -p1 -b .orig
%patch1 -p1 -b .orig
%setup -q
%patch0 -p1 -b .maxavailfiles
%patch1 -p1 -b .ppc
%patch2 -p1 -b .sparc
%patch3 -p1 -b .s390
chmod a-x *hdf/*/*.c hdf/*/*.h
# restore include file timestamps modified by patching
touch -c -r ./hdf/src/hdfi.h.ppc ./hdf/src/hdfi.h
touch -c -r ./mfhdf/libsrc/config/netcdf-linux.h.ppc ./mfhdf/libsrc/config/netcdf-linux.h
%build
autoconf
export CFLAGS="$RPM_OPT_FLAGS -fPIC -DHAVE_NETCDF"
%configure F77=gfortran FFLAGS=-ffixed-line-length-none
# avoid upstream compiler flags settings
rm config/*linux-gnu
export CFLAGS="$RPM_OPT_FLAGS -fPIC"
export FFLAGS="$RPM_OPT_FLAGS -fPIC -ffixed-line-length-none"
%configure --disable-production --disable-netcdf \
--includedir=%{_includedir}/%{name} --libdir=%{_libdir}/%{name}
make
# correct the timestamps based on files used to generate the header files
touch -c -r ./mfhdf/fortran/config/netcdf-linux.inc mfhdf/fortran/netcdf.inc
touch -c -r hdf/src/hdf.inc hdf/src/hdf.f90
touch -c -r hdf/src/dffunc.inc hdf/src/dffunc.f90
touch -c -r mfhdf/fortran/mffunc.inc mfhdf/fortran/mffunc.f90
# netcdf fortran include need same treatement, but they are not shipped
%install
rm -rf $RPM_BUILD_ROOT
%makeinstall includedir=${RPM_BUILD_ROOT}%{_includedir}/%{name} \
libdir=$RPM_BUILD_ROOT%{_libdir}/%{name}
make install DESTDIR=$RPM_BUILD_ROOT INSTALL='install -p'
#Don't conflict with netcdf
rm $RPM_BUILD_ROOT%{_bindir}/nc* $RPM_BUILD_ROOT%{_mandir}/man1/nc*
#rm $RPM_BUILD_ROOT%{_bindir}/nc* $RPM_BUILD_ROOT%{_mandir}/man1/nc*
for file in ncdump ncgen; do
mv $RPM_BUILD_ROOT%{_bindir}/$file $RPM_BUILD_ROOT%{_bindir}/h$file
# man pages are the same than netcdf ones
rm $RPM_BUILD_ROOT%{_mandir}/man1/${file}.1
done
# this is done to have the same timestamp on multiarch setups
touch -c -r README.txt $RPM_BUILD_ROOT/%{_includedir}/hdf/h4config.h
# Remove an autoconf conditional from the API that is unused and cause
# the API to be different on x86 and x86_64
pushd $RPM_BUILD_ROOT/%{_includedir}/hdf
grep -v 'H4_SIZEOF_INTP' h4config.h > h4config.h.tmp
touch -c -r h4config.h h4config.h.tmp
mv h4config.h.tmp h4config.h
popd
%check
make check
%clean
rm -rf $RPM_BUILD_ROOT
%post
%postun
%files
%defattr(-,root,root,0755)
%doc COPYING MANIFEST README release_notes/*.txt
%doc COPYING MANIFEST README.txt release_notes/*.txt
%{_bindir}/*
%{_mandir}/man1/*.gz
@ -73,7 +110,88 @@ rm -rf $RPM_BUILD_ROOT
%{_includedir}/%{name}/
%{_libdir}/%{name}/
%changelog
* Tue Mar 2 2010 Orion Poplawski <orion@cora.nwra.com> 4.2.5-1
- Update to 4.2.5
* Fri Sep 18 2009 Orion Poplawski <orion@cora.nwra.com> 4.2r4-5
- Add EL4 build conditionals
* Thu Aug 13 2009 Orion Poplawski <orion@cora.nwra.com> 4.2r4-4
- Add -fPIC to FFLAGS
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.2r4-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
* Tue Apr 7 2009 Orion Poplawski <orion@cora.nwra.com> 4.2r4-2
- Add Provides hdf-static to hdf-devel (bug #494529)
* Wed Feb 25 2009 Orion Poplawski <orion@cora.nwra.com> 4.2r4-1
- Update to 4.2r4
- Add patch to increase buffer size in test
- Drop upstreamed libm patch
* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.2r3-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Wed Oct 1 2008 Orion Poplawski <orion@cora.nwra.com> 4.2r3-4
- Rebase maxavailfiles patch
* Sun Sep 21 2008 Ville Skyttä <ville.skytta at iki.fi> - 4.2r3-3
- Fix Patch0:/%%patch mismatch.
* Sun Mar 2 2008 Patrice Dumas <pertusus@free.fr> 4.2r3-2
- don't ship an empty netcdf.h file. The related definitions are now
in hdf4_netcdf.h
* Tue Feb 5 2008 Orion Poplawski <orion@cora.nwra.com> 4.2.r3-1
- Update to 4.2r3
* Tue Feb 5 2008 Orion Poplawski <orion@cora.nwra.com> 4.2.r2-7
- Add patch to add -lm to hdiff link
* Tue Feb 5 2008 Orion Poplawski <orion@cora.nwra.com> 4.2.r2-6
- Add patch for s390 support (bug #431511)
* Mon Jan 7 2008 Orion Poplawski <orion@cora.nwra.com> 4.2.r2-5
- Add patches for sparc support (bug #427639)
* Mon Oct 29 2007 Patrice Dumas <pertusus@free.fr> 4.2r2-4
- install the netcdf.h file that describes the netcdf2 hdf enabled
API
* Mon Oct 29 2007 Patrice Dumas <pertusus@free.fr> 4.2r2-3
- ship hdf enabled nc* utils as hnc*
- add --disable-netcdf that replaces HAVE_NETCDF
- keep include files timestamps, and have the same accross arches
- fix multiarch difference in include files (#341491)
* Wed Oct 17 2007 Patrice Dumas <pertusus@free.fr> 4.2r2-2
- update to 4.2r2
* Fri Aug 24 2007 Orion Poplawski <orion@cora.nwra.com> 4.2r1-15
- Update license tag to BSD
- Rebuild for BuildID
* Thu May 10 2007 Balint Cristian <cbalint@redhat.com> 4.2r1-14
- Fix ppc64 too.
* Thu May 10 2007 Orion Poplawski <orion@cora.nwra.com> 4.2r1-13
- Remove netcdf-devel requires. (bug #239631)
* Fri Apr 20 2007 Orion Poplawski <orion@cora.nwra.com> 4.2r1-12
- Use 4.2r1-hrepack-p4.tar.gz for hrepack patch
- Remove configure patch applied upstream
- Use --disable-production configure flag to avoid stripping -g compile flag
- Add patch to fix open file test when run under mock
* Tue Aug 29 2006 Orion Poplawski <orion@cora.nwra.com> 4.2r1-11
- Rebuild for FC6
* Thu Apr 20 2006 Orion Poplawski <orion@cora.nwra.com> 4.2r1-10
- Add Requires netcdf-devel for hdf-devel (bug #189337)
* Mon Feb 13 2006 Orion Poplawski <orion@cora.nwra.com> 4.2r1-9
- Rebuild for gcc/glibc changes

2
import.log Normal file
View File

@ -0,0 +1,2 @@
hdf-4_2r4-5_fc12:EL-4:hdf-4.2r4-5.fc12.src.rpm:1253294536
hdf-4_2_5-1_fc14:EL-4:hdf-4.2.5-1.fc14.src.rpm:1267563289

View File

@ -1,2 +1 @@
d172631b6e6f32c4f93f647a09862011 4.2r1-hrepack-patch.tar
9082c6fa913b9188452fa6c5217e1573 HDF4.2r1.tar.gz
91bc17ec735b52736507570a530fe8a9 hdf-4.2.5.tar.bz2