diff options
author | Andy Cedilnik <andy.cedilnik@kitware.com> | 2005-12-28 19:58:07 (GMT) |
---|---|---|
committer | Andy Cedilnik <andy.cedilnik@kitware.com> | 2005-12-28 19:58:07 (GMT) |
commit | 18d31fd97c3305b54a6d1d56b6ef8600089ef6da (patch) | |
tree | fad65ce7d2ba37095405c27df79a9c7a5883f448 /Utilities/cmtar/handle.c | |
parent | d715d52a11fbcbc3310412ae7c7ec1e71e5bcbed (diff) | |
download | CMake-18d31fd97c3305b54a6d1d56b6ef8600089ef6da.zip CMake-18d31fd97c3305b54a6d1d56b6ef8600089ef6da.tar.gz CMake-18d31fd97c3305b54a6d1d56b6ef8600089ef6da.tar.bz2 |
COMP: Several borland fixes
Diffstat (limited to 'Utilities/cmtar/handle.c')
-rw-r--r-- | Utilities/cmtar/handle.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/Utilities/cmtar/handle.c b/Utilities/cmtar/handle.c index 1fe053e..5238e03 100644 --- a/Utilities/cmtar/handle.c +++ b/Utilities/cmtar/handle.c @@ -34,7 +34,22 @@ const char libtar_version[] = PACKAGE_VERSION; +#define libtar_symbol(name, ret, args, callargs) \ + static ret libtar_##name args \ + { \ + return name callargs; \ + } + +#if defined(__BORLANDC__) +libtar_symbol(open, int, (const char* pathname, int flags, mode_t mode), (pathname, flags, mode)); +libtar_symbol(close, int, (int fd), (fd)); +libtar_symbol(read, ssize_t, (int fd, void* buf, size_t count), (fd, buf, count)); +libtar_symbol(write, ssize_t, (int fd, void* buf, size_t count), (fd, buf, count)); + +static tartype_t default_type = { libtar_open, libtar_close, libtar_read, libtar_write }; +#else static tartype_t default_type = { open, close, read, write }; +#endif static int |