summaryrefslogtreecommitdiffstats
path: root/src/H5private.h
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2001-06-29 19:49:53 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2001-06-29 19:49:53 (GMT)
commit8c2c4cd51cb8dd1393acad65e3f015d76bfd9563 (patch)
treea663d3ab5cc66e53485a66d973b55dbb571640be /src/H5private.h
parent098ed81ec88483581d08974f27a62bf42a836fc3 (diff)
downloadhdf5-8c2c4cd51cb8dd1393acad65e3f015d76bfd9563.zip
hdf5-8c2c4cd51cb8dd1393acad65e3f015d76bfd9563.tar.gz
hdf5-8c2c4cd51cb8dd1393acad65e3f015d76bfd9563.tar.bz2
[svn-r4088] Purpose:
Code cleanup Description: Recent CodeWarrior patches have broken the Unix builds and moved code around in non-portable ways. Solution: Patched things back up to try to accomodate CodeWarrior and still let the Unix builds work correctly. Platforms tested: FreeBSD 4.3 (hawkwind)
Diffstat (limited to 'src/H5private.h')
-rw-r--r--src/H5private.h48
1 files changed, 9 insertions, 39 deletions
diff --git a/src/H5private.h b/src/H5private.h
index 02c5bbf..b001d86 100644
--- a/src/H5private.h
+++ b/src/H5private.h
@@ -173,41 +173,9 @@ MS doesn't recognize it yet (as of April 2001)
typedef long off_t;
/* Metroworks does not define EINTR in <errno.h> */
# define EINTR 4
-#endif
-/*__MWERKS__*/
+#endif /*__MWERKS__*/
-#endif
-/*WIN32*/
-
-/*
- * This driver supports systems that have the lseek64() function by defining
- * some macros here so we don't have to have conditional compilations later
- * throughout the code.
- *
- * file_offset_t: The datatype for file offsets, the second argument of
- * the lseek() or lseek64() call.
- *
- * file_seek: The function which adjusts the current file position,
- * either lseek() or lseek64().
- *
- * adding for windows NT file system support.
- */
-
-#ifdef H5_HAVE_LSEEK64
-# define file_offset_t off64_t
-# define file_seek lseek64
-#elif defined (WIN32)
-# ifdef __MWERKS__
-# define file_offset_t off_t
-# define file_seek lseek
-# else /*MSVC*/
-# define file_offset_t __int64
-# define file_seek _lseeki64
-# endif
-#else
-# define file_offset_t off_t
-# define file_seek lseek
-#endif
+#endif /*WIN32*/
#ifndef F_OK
# define F_OK 00
@@ -215,9 +183,6 @@ typedef long off_t;
# define R_OK 04
#endif
-
-
-
/*
* Pablo support files.
*/
@@ -572,7 +537,12 @@ __DLL__ void H5_bandwidth(char *buf/*out*/, double nbytes, double nseconds);
#define HDexecve(S,AV,E) execve(S,AV,E)
#define HDexecvp(S,AV) execvp(S,AV)
#define HDexit(N) exit(N)
+#if defined __MWERKS__
+#include <abort_exit.h>
+#define HD_exit(N) __exit(N)
+#else /* __MWERKS __ */
#define HD_exit(N) _exit(N)
+#endif /* __MWERKS __ */
#define HDexp(X) exp(X)
#define HDfabs(X) fabs(X)
#define HDfclose(F) fclose(F)
@@ -796,9 +766,9 @@ __DLL__ int64_t HDstrtoll (const char *s, const char **rest, int base);
* And now for a couple non-Posix functions... Watch out for systems that
* define these in terms of macros.
*/
-#if defined (__MWERKS__)
+#ifdef WIN32
#define HDstrdup(S) _strdup(S)
-#else
+#else /* WIN32 */
#if !defined strdup && !defined H5_HAVE_STRDUP
extern char *strdup(const char *s);