diff --git a/library/GNUmakefile.os4 b/library/GNUmakefile.os4 index 3db6715..3a7e071 100644 --- a/library/GNUmakefile.os4 +++ b/library/GNUmakefile.os4 @@ -1,5 +1,5 @@ # -# $Id: GNUmakefile.os4,v 1.45 2005-03-19 11:06:57 obarthel Exp $ +# $Id: GNUmakefile.os4,v 1.46 2005-03-20 11:18:06 obarthel Exp $ # # :ts=8 # @@ -111,9 +111,10 @@ WARNINGS = \ # -Wconversion -Wshadow INCLUDES = -Iinclude -I. -I$(SDK_INCLUDE) -OPTIONS = -D__THREAD_SAFE -DNDEBUG -DUSE_64_BIT_INTS -D__USE_INLINE__ -Wa,-mregnames -fno-common -OPTIMIZE = -O -fomit-frame-pointer -funroll-loops -#DEBUG = -g +#OPTIONS = -D__THREAD_SAFE -DNDEBUG -DUSE_64_BIT_INTS -D__USE_INLINE__ -Wa,-mregnames -fno-common + OPTIONS = -DNDEBUG -DUSE_64_BIT_INTS -D__USE_INLINE__ -Wa,-mregnames -fno-common +OPTIMIZE = -O3 -fomit-frame-pointer -funroll-loops +#DEBUG = -ggdb CFLAGS = $(WARNINGS) $(OPTIMIZE) $(DEBUG) $(OPTIONS) $(CODE_TYPE) $(INCLUDES) diff --git a/library/changes b/library/changes index a73ed5d..64f9466 100644 --- a/library/changes +++ b/library/changes @@ -113,6 +113,11 @@ data structures possibly not being in a well-defined and initialized state. +- Turns out that the constructor/destructor calling sequence + was still wrongish for the OS4 library. So I had to change + it *again*. Which probably means that the 68k library will + need further changes... + c.lib 1.189 (5.3.2005) diff --git a/library/stdio_protos.h b/library/stdio_protos.h index 61d37b8..e727df4 100644 --- a/library/stdio_protos.h +++ b/library/stdio_protos.h @@ -1,5 +1,5 @@ /* - * $Id: stdio_protos.h,v 1.15 2005-03-19 11:06:57 obarthel Exp $ + * $Id: stdio_protos.h,v 1.16 2005-03-20 11:18:06 obarthel Exp $ * * :ts=4 * @@ -54,6 +54,12 @@ /****************************************************************************/ +#ifndef _STDLIB_MEMORY_H +#include "stdlib_memory.h" +#endif /* _STDLIB_MEMORY_H */ + +/****************************************************************************/ + #ifndef _STDIO_HEADERS_H /* Forward declarations */ diff --git a/library/stdlib_constructor.h b/library/stdlib_constructor.h index 1aaf8ab..62e02a2 100644 --- a/library/stdlib_constructor.h +++ b/library/stdlib_constructor.h @@ -1,5 +1,5 @@ /* - * $Id: stdlib_constructor.h,v 1.1 2005-03-18 12:38:23 obarthel Exp $ + * $Id: stdlib_constructor.h,v 1.2 2005-03-20 11:18:06 obarthel Exp $ * * :ts=4 * @@ -112,32 +112,32 @@ constructors and the user-supplied destructors before the library destructors. */ -#define STDLIB_CONSTRUCTOR(name) CONSTRUCTOR(name, 1) -#define STDLIB_DESTRUCTOR(name) DESTRUCTOR(name, 1) +#define STDLIB_CONSTRUCTOR(name) CONSTRUCTOR(name, 9) +#define STDLIB_DESTRUCTOR(name) DESTRUCTOR(name, 9) -#define STK_CONSTRUCTOR(name) CONSTRUCTOR(name, 2) -#define STK_DESTRUCTOR(name) DESTRUCTOR(name, 2) +#define STK_CONSTRUCTOR(name) CONSTRUCTOR(name, 8) +#define STK_DESTRUCTOR(name) DESTRUCTOR(name, 8) -#define STDIO_CONSTRUCTOR(name) CONSTRUCTOR(name, 3) -#define STDIO_DESTRUCTOR(name) DESTRUCTOR(name, 3) +#define STDIO_CONSTRUCTOR(name) CONSTRUCTOR(name, 7) +#define STDIO_DESTRUCTOR(name) DESTRUCTOR(name, 7) -#define FILE_CONSTRUCTOR(name) CONSTRUCTOR(name, 4) -#define FILE_DESTRUCTOR(name) DESTRUCTOR(name, 4) +#define FILE_CONSTRUCTOR(name) CONSTRUCTOR(name, 6) +#define FILE_DESTRUCTOR(name) DESTRUCTOR(name, 6) #define MATH_CONSTRUCTOR(name) CONSTRUCTOR(name, 5) #define MATH_DESTRUCTOR(name) DESTRUCTOR(name, 5) -#define SOCKET_CONSTRUCTOR(name) CONSTRUCTOR(name, 6) -#define SOCKET_DESTRUCTOR(name) DESTRUCTOR(name, 6) +#define SOCKET_CONSTRUCTOR(name) CONSTRUCTOR(name, 4) +#define SOCKET_DESTRUCTOR(name) DESTRUCTOR(name, 4) -#define ARG_CONSTRUCTOR(name) CONSTRUCTOR(name, 7) -#define ARG_DESTRUCTOR(name) DESTRUCTOR(name, 7) +#define ARG_CONSTRUCTOR(name) CONSTRUCTOR(name, 3) +#define ARG_DESTRUCTOR(name) DESTRUCTOR(name, 3) -#define CLIB_CONSTRUCTOR(name) CONSTRUCTOR(name, 8) -#define CLIB_DESTRUCTOR(name) DESTRUCTOR(name, 8) +#define CLIB_CONSTRUCTOR(name) CONSTRUCTOR(name, 2) +#define CLIB_DESTRUCTOR(name) DESTRUCTOR(name, 2) -#define PROFILE_CONSTRUCTOR(name) CONSTRUCTOR(name, 9) -#define PROFILE_DESTRUCTOR(name) DESTRUCTOR(name, 9) +#define PROFILE_CONSTRUCTOR(name) CONSTRUCTOR(name, 1) +#define PROFILE_DESTRUCTOR(name) DESTRUCTOR(name, 1) /****************************************************************************/ diff --git a/library/stdlib_free.c b/library/stdlib_free.c index d839af6..675262b 100644 --- a/library/stdlib_free.c +++ b/library/stdlib_free.c @@ -1,5 +1,5 @@ /* - * $Id: stdlib_free.c,v 1.9 2005-03-18 12:38:24 obarthel Exp $ + * $Id: stdlib_free.c,v 1.10 2005-03-20 11:18:06 obarthel Exp $ * * :ts=4 * @@ -52,7 +52,7 @@ /****************************************************************************/ -STATIC CHAR +STATIC char get_hex_char(int n) { char result; diff --git a/library/stdlib_main.c b/library/stdlib_main.c index b6efba6..e88c7a4 100644 --- a/library/stdlib_main.c +++ b/library/stdlib_main.c @@ -1,5 +1,5 @@ /* - * $Id: stdlib_main.c,v 1.19 2005-03-19 11:06:57 obarthel Exp $ + * $Id: stdlib_main.c,v 1.20 2005-03-20 11:18:06 obarthel Exp $ * * :ts=4 * @@ -31,10 +31,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ -/*#define DEBUG*/ - -/****************************************************************************/ - #ifndef EXEC_EXECBASE_H #include #endif /* EXEC_EXECBASE_H */ diff --git a/library/stdlib_memory.h b/library/stdlib_memory.h index 76b5c13..9146c9d 100644 --- a/library/stdlib_memory.h +++ b/library/stdlib_memory.h @@ -1,5 +1,5 @@ /* - * $Id: stdlib_memory.h,v 1.1 2005-03-18 12:38:24 obarthel Exp $ + * $Id: stdlib_memory.h,v 1.2 2005-03-20 11:18:06 obarthel Exp $ * * :ts=4 * @@ -40,7 +40,7 @@ * Uncomment this to build a library which has the memory debugging features * enabled. */ -/*#define __MEM_DEBUG */ +/*#define __MEM_DEBUG*/ /****************************************************************************/ diff --git a/library/stdlib_protos.h b/library/stdlib_protos.h index ab7843b..46b57e0 100644 --- a/library/stdlib_protos.h +++ b/library/stdlib_protos.h @@ -1,5 +1,5 @@ /* - * $Id: stdlib_protos.h,v 1.13 2005-03-18 12:38:24 obarthel Exp $ + * $Id: stdlib_protos.h,v 1.14 2005-03-20 11:18:06 obarthel Exp $ * * :ts=4 * @@ -49,11 +49,7 @@ /****************************************************************************/ #ifndef _STDLIB_MEMORY_H - -/* Forward declarations */ -struct MemoryNode; -struct MemoryTree; - +#include "stdlib_memory.h" #endif /* _STDLIB_MEMORY_H */ /****************************************************************************/ diff --git a/library/stdlib_red_black.c b/library/stdlib_red_black.c index 56dd36f..a2f114b 100644 --- a/library/stdlib_red_black.c +++ b/library/stdlib_red_black.c @@ -1,5 +1,5 @@ /* - * $Id: stdlib_red_black.c,v 1.4 2005-03-18 12:38:24 obarthel Exp $ + * $Id: stdlib_red_black.c,v 1.5 2005-03-20 11:18:06 obarthel Exp $ * * :ts=4 * @@ -130,7 +130,7 @@ rotate_right (struct MemoryTree * tree, struct MemoryNode * y) /****************************************************************************/ -STATIC STRUCT MemoryNode * +STATIC struct MemoryNode * get_successor (struct MemoryTree * tree, struct MemoryNode * x) { struct MemoryNode *nil = &tree->mt_NullNode;