- Add patches to support sparc (bug #427651)
parent
f659110776
commit
dd0dbfa5b7
@ -0,0 +1,45 @@
|
||||
--- hdf5-1.6.5/src/H5detect.c.orig 2005-09-12 19:18:23.000000000 +0200
|
||||
+++ hdf5-1.6.5/src/H5detect.c 2005-11-15 18:25:36.030721792 +0100
|
||||
@@ -106,7 +106,7 @@
|
||||
static void detect_C99_integers64(void);
|
||||
static void detect_alignments(void);
|
||||
static size_t align_g[] = {1, 2, 4, 8, 16};
|
||||
-static jmp_buf jbuf_g;
|
||||
+static sigjmp_buf jbuf_g;
|
||||
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
@@ -360,7 +360,7 @@
|
||||
void (*_handler2)(int) = signal(SIGSEGV, sigsegv_handler); \
|
||||
\
|
||||
_buf = (char*)malloc(sizeof(TYPE)+align_g[NELMTS(align_g)-1]); \
|
||||
- if (setjmp(jbuf_g)) _ano++; \
|
||||
+ if (sigsetjmp(jbuf_g, 1)) _ano++; \
|
||||
if (_ano<NELMTS(align_g)) { \
|
||||
*((TYPE*)(_buf+align_g[_ano])) = _val; /*possible SIGBUS or SEGSEGV*/ \
|
||||
_val2 = *((TYPE*)(_buf+align_g[_ano])); /*possible SIGBUS or SEGSEGV*/ \
|
||||
@@ -376,7 +376,7 @@
|
||||
memcpy(_buf+align_g[_ano]+(INFO.offset/8),((char *)&_val)+(INFO.offset/8),(size_t)(INFO.precision/8)); \
|
||||
_val2 = *((TYPE*)(_buf+align_g[_ano])); \
|
||||
if(_val!=_val2) \
|
||||
- longjmp(jbuf_g, 1); \
|
||||
+ siglongjmp(jbuf_g, 1); \
|
||||
/* End Cray Check */ \
|
||||
(INFO.align)=align_g[_ano]; \
|
||||
} else { \
|
||||
@@ -460,7 +460,7 @@
|
||||
sigsegv_handler(int UNUSED signo)
|
||||
{
|
||||
signal(SIGSEGV, sigsegv_handler);
|
||||
- longjmp(jbuf_g, 1);
|
||||
+ siglongjmp(jbuf_g, 1);
|
||||
}
|
||||
|
||||
|
||||
@@ -485,7 +485,7 @@
|
||||
sigbus_handler(int UNUSED signo)
|
||||
{
|
||||
signal(SIGBUS, sigbus_handler);
|
||||
- longjmp(jbuf_g, 1);
|
||||
+ siglongjmp(jbuf_g, 1);
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
--- hdf5-1.6.6.orig/fortran/src/H5f90i.h 2008-01-06 11:51:45.000000000 +0200
|
||||
+++ hdf5-1.6.6/fortran/src/H5f90i.h 2008-01-06 12:15:59.000000000 +0200
|
||||
@@ -116,6 +116,15 @@
|
||||
typedef int size_t_f;
|
||||
#define FNAME_POST_UNDERSCORE
|
||||
|
||||
+/* sparc32/64 specific definitions */
|
||||
+#elif (defined __sparc__ || defined __sparc64__)
|
||||
+
|
||||
+typedef long long haddr_t_f;
|
||||
+typedef long long hsize_t_f;
|
||||
+typedef long long hssize_t_f;
|
||||
+typedef int size_t_f;
|
||||
+#define FNAME_POST_UNDERSCORE
|
||||
+
|
||||
/* IA64 specific definitions */
|
||||
#elif defined __ia64
|
||||
|
Loading…
Reference in new issue