diff options
author | H.J. Lu <hjl@gnu.ai.mit.edu> | 1997-10-23 01:17:58 +0000 |
---|---|---|
committer | Jeff Law <law@gcc.gnu.org> | 1997-10-22 19:17:58 -0600 |
commit | 1181d2d55377707551ac43b20ca7ebb4e253dddc (patch) | |
tree | 8a86fdd90a3b0a82e0d6c72cbc99059eaa1e6533 /libio | |
parent | 4966381af5a597dd1cf0f4f73b70d12f5d17be13 (diff) |
libio.h (_IO_LOCK_T): Handle glibc 2 when _IO_MTSAFE_IO is not defined.
* libio.h (_IO_LOCK_T): Handle glibc 2 when _IO_MTSAFE_IO is
not defined.
* iovsscanf.c (vsscanf): Make it weak alias of _IO_vsscanf if
__linux__ is defined instead of __ELF__
* config/linuxlibc1.mt (USER_INCLUDES): Add libio.h.
OK'd by Ulrich.
From-SVN: r16151
Diffstat (limited to 'libio')
-rw-r--r-- | libio/ChangeLog | 10 | ||||
-rw-r--r-- | libio/config/linuxlibc1.mt | 2 | ||||
-rw-r--r-- | libio/iovsscanf.c | 2 | ||||
-rw-r--r-- | libio/libio.h | 10 |
4 files changed, 18 insertions, 6 deletions
diff --git a/libio/ChangeLog b/libio/ChangeLog index 0ee838da096..6da6b9c5b91 100644 --- a/libio/ChangeLog +++ b/libio/ChangeLog @@ -1,3 +1,13 @@ +Wed Oct 22 19:19:32 1997 H.J. Lu (hjl@gnu.ai.mit.edu) + + * libio.h (_IO_LOCK_T): Handle glibc 2 when _IO_MTSAFE_IO is + not defined. + + * iovsscanf.c (vsscanf): Make it weak alias of _IO_vsscanf if + __linux__ is defined instead of __ELF__ + + * config/linuxlibc1.mt (USER_INCLUDES): Add libio.h. + 1997-10-15 Ulrich Drepper <drepper@cygnus.com> * configure.in: Create compatibility code in bits/libc-lock.h file. diff --git a/libio/config/linuxlibc1.mt b/libio/config/linuxlibc1.mt index 378a9c92ef0..09c4c83804e 100644 --- a/libio/config/linuxlibc1.mt +++ b/libio/config/linuxlibc1.mt @@ -20,7 +20,7 @@ STDIO_OBJECTS= USER_INCLUDES=PlotFile.h SFile.h builtinbuf.h editbuf.h fstream.h \ indstream.h iomanip.h iostream.h istream.h ostream.h \ parsestream.h pfstream.h procbuf.h stdiostream.h stream.h \ - streambuf.h strfile.h strstream.h + streambuf.h strfile.h strstream.h libio.h # A bad kludge MT_CFLAGS=-D_G_HAVE_MMAP diff --git a/libio/iovsscanf.c b/libio/iovsscanf.c index 0db195c8c58..beb0bc3a6b2 100644 --- a/libio/iovsscanf.c +++ b/libio/iovsscanf.c @@ -52,7 +52,7 @@ _IO_vsscanf (string, format, args) weak_alias (_IO_vsscanf, __vsscanf) weak_alias (_IO_vsscanf, vsscanf) #else -#ifdef __ELF__ +#ifdef __linux__ #pragma weak vsscanf = _IO_vsscanf #endif #endif diff --git a/libio/libio.h b/libio/libio.h index 98d98c3249b..eeee6ceeb0b 100644 --- a/libio/libio.h +++ b/libio/libio.h @@ -157,15 +157,17 @@ struct _IO_jump_t; struct _IO_FILE; # endif #else /* XXX This will go away as soon as comthread is finished. */ -# ifdef __linux__ +# if defined __GLIBC__ && __GLIBC__ >= 2 +# define _IO_LOCK_T void * +# else +# ifdef __linux__ struct _IO_lock_t { void *ptr; short int field1; short int field2; }; -# define _IO_LOCK_T struct _IO_lock_t -# else -typedef void _IO_lock_t; +# define _IO_LOCK_T struct _IO_lock_t +# endif # endif #endif |