X-Git-Url: https://git.brokenzipper.com/gitweb?a=blobdiff_plain;f=src%2Fport.h;h=4bf9d2c6b95eb7c06c5e6f896c5cf8658284c87e;hb=f9a11075d98cfd0336a325e7c293853d5736f12c;hp=481f36ab3f4aaefbf80e85e5fa37e5fc144b1543;hpb=b673b3f79454b66d0f4942cd93c790f941dc9235;p=chaz%2Ftar diff --git a/src/port.h b/src/port.h index 481f36a..4bf9d2c 100644 --- a/src/port.h +++ b/src/port.h @@ -1,5 +1,5 @@ /* Portability declarations. Requires sys/types.h. - Copyright (C) 1988 Free Software Foundation + Copyright (C) 1988, 1992 Free Software Foundation This file is part of GNU Tar. @@ -17,11 +17,22 @@ You should have received a copy of the GNU General Public License along with GNU Tar; see the file COPYING. If not, write to the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ -#include "pathmax.h" - +/* AIX requires this to be the first thing in the file. */ #ifdef __GNUC__ #define alloca __builtin_alloca -#endif +#else /* not __GNUC__ */ +#if HAVE_ALLOCA_H +#include +#else /* not HAVE_ALLOCA_H */ +#ifdef _AIX + #pragma alloca +#else /* not _AIX */ +char *alloca (); +#endif /* not _AIX */ +#endif /* not HAVE_ALLOCA_H */ +#endif /* not __GNUC__ */ + +#include "pathmax.h" #ifdef _POSIX_VERSION #include @@ -87,6 +98,12 @@ typedef long off_t; #if !defined(__MSDOS__) && !defined(STDC_HEADERS) #include #endif +#ifdef index +#undef index +#endif +#ifdef rindex +#undef rindex +#endif #define index strchr #define rindex strrchr #define bcopy(s, d, n) memcpy(d, s, n)