about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2000-03-17 09:03:47 +0000
committerRoland McGrath <roland@gnu.org>2000-03-17 09:03:47 +0000
commitda28fa2a447b193788c0ad7a9b3d97e37fc3bf8b (patch)
treeeeea8a874d92e2d90e629319e20d4aea35305ef1
parent1b67abbbfd558ca7a47a84cb6c76ebf55db1c828 (diff)
downloadglibc-da28fa2a447b193788c0ad7a9b3d97e37fc3bf8b.tar.gz
glibc-da28fa2a447b193788c0ad7a9b3d97e37fc3bf8b.tar.xz
glibc-da28fa2a447b193788c0ad7a9b3d97e37fc3bf8b.zip
* sysdeps/mach/sched_yield.c: New file.
2000-03-13  Roland McGrath  <roland@baalperazim.frob.com>

	* sysdeps/generic/lockfile.c: Include <stdio.h>
	(_IO_flockfile, _IO_funlockfile, _IO_ftrylockfile): #undef these in
	case <libio.h> defined them.
	(__flockfile, __funlockfile, __ftrylockfile): Functions renamed
	from __internal_*.
	(flockfile, _IO_flockfile, funlockfile, _IO_funlockfile,
	ftrylockfile, _IO_ftrylockfile): Fix aliases accordingly.

	* sysdeps/generic/bits/stdio-lock.h (_IO_lock_initializer): Use ...
	for more pleasing parse error.

	* elf/Makefile: Add rules to compile and run constload1 test.
-rw-r--r--ChangeLog19
-rw-r--r--bits/stdio-lock.h2
-rw-r--r--sysdeps/generic/bits/stdio-lock.h2
-rw-r--r--sysdeps/mach/sched_yield.c31
4 files changed, 51 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index cf57b2fa1a..9bf64452e3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,10 +1,27 @@
+2000-03-17  Roland McGrath  <roland@baalperazim.frob.com>
+
+	* sysdeps/mach/sched_yield.c: New file.
+
+2000-03-13  Roland McGrath  <roland@baalperazim.frob.com>
+
+	* sysdeps/generic/lockfile.c: Include <stdio.h>
+	(_IO_flockfile, _IO_funlockfile, _IO_ftrylockfile): #undef these in
+	case <libio.h> defined them.
+	(__flockfile, __funlockfile, __ftrylockfile): Functions renamed
+	from __internal_*.
+	(flockfile, _IO_flockfile, funlockfile, _IO_funlockfile,
+	ftrylockfile, _IO_ftrylockfile): Fix aliases accordingly.
+
+	* sysdeps/generic/bits/stdio-lock.h (_IO_lock_initializer): Use ...
+	for more pleasing parse error.
+
 2000-03-16  Ulrich Drepper  <drepper@redhat.com>
 
 	* locale/lc-time.c (_nl_init_era_entries): Correct allocation of
 	memory for eras.
 	Patch by Shinya Hanataka <hanataka@abyss.rim.or.jp>.
 
-	* elf/Makefile: Add rules to compile and rune constload1 test.
+	* elf/Makefile: Add rules to compile and run constload1 test.
 	* elf/constload1.c: New file.
 	* elf/constload2.c: New file.
 	* elf/constload3.c: New file.
diff --git a/bits/stdio-lock.h b/bits/stdio-lock.h
index 39d5b0b9c9..bcf636de5d 100644
--- a/bits/stdio-lock.h
+++ b/bits/stdio-lock.h
@@ -25,7 +25,7 @@
 __libc_lock_define (typedef, _IO_lock_t)
 
 /* We need recursive (counting) mutexes.  */
-#define _IO_lock_initializer STUB_LOSER
+#define _IO_lock_initializer ...
 #error libio needs recursive mutexes for _IO_MTSAFE_IO
 
 
diff --git a/sysdeps/generic/bits/stdio-lock.h b/sysdeps/generic/bits/stdio-lock.h
index 39d5b0b9c9..bcf636de5d 100644
--- a/sysdeps/generic/bits/stdio-lock.h
+++ b/sysdeps/generic/bits/stdio-lock.h
@@ -25,7 +25,7 @@
 __libc_lock_define (typedef, _IO_lock_t)
 
 /* We need recursive (counting) mutexes.  */
-#define _IO_lock_initializer STUB_LOSER
+#define _IO_lock_initializer ...
 #error libio needs recursive mutexes for _IO_MTSAFE_IO
 
 
diff --git a/sysdeps/mach/sched_yield.c b/sysdeps/mach/sched_yield.c
new file mode 100644
index 0000000000..b4122b7912
--- /dev/null
+++ b/sysdeps/mach/sched_yield.c
@@ -0,0 +1,31 @@
+/* sched_yield -- yield the processor.  Mach version.
+   Copyright (C) 2000 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <errno.h>
+#include <sched.h>
+#include <mach.h>
+
+/* Yield the processor.  */
+int
+__sched_yield (void)
+{
+  (void) __swtch ();
+  return 0;
+}
+weak_alias (__sched_yield, sched_yield)