diff --git a/ChangeLog b/ChangeLog index 2558e3d..71c4f3c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2006-02-24 Jeremy Bettis + + * misc.c: Added some missing objc_DECLARE keywords on function pointer definitions. + * init.c: (objc_send_load): Removed the check for NXConstantString class to fix +load. + (again see:ChangeLog.GNUstep Tue Feb 11 17:11:00 2003) + 2006-02-21 Jeremy Bettis * thr-win32.c: (__objc_thread_detach): Removed duplicate definitions of thread_id and win32_handle. diff --git a/init.c b/init.c index 3387865..9d47ce2 100644 --- a/init.c +++ b/init.c @@ -731,12 +731,23 @@ objc_send_load (void) return; } - /* Special check to allow creating and sending messages to constant - strings in +load methods. If these classes are not yet known, - even if all the other classes are known, delay sending of +load. */ +#if 0 + /* Special check to allow creating and sending messages to constant strings + in +load methods. If these classes are not yet known, even if all the + other classes are known, delay sending of +load. */ if (! objc_lookup_class ("NXConstantString") || ! objc_lookup_class ("Object")) +#else + /* + * The above check prevents +load being called at all if NXConstantString + * is never created (common on modern systems). However, completely + * removing it causes the runtime test in the GNUstep base library + * configure to fail (for some unknown reason), so we retain the check for + * the existence of the Object class. + */ + if (!objc_lookup_class ("Object")) return; +#endif /* Iterate over all modules in the __objc_module_list and call on them the __objc_create_classes_tree function. This function diff --git a/misc.c b/misc.c index 972cff1..8cab508 100644 --- a/misc.c +++ b/misc.c @@ -165,21 +165,21 @@ noFree (void *p) { } -void *(*_objc_malloc) (size_t) = GC_malloc; -void *(*_objc_atomic_malloc) (size_t) = GC_malloc_atomic; -void *(*_objc_valloc) (size_t) = GC_malloc; -void *(*_objc_realloc) (void *, size_t) = GC_realloc; -void *(*_objc_calloc) (size_t, size_t) = GC_calloc; -void (*_objc_free) (void *) = noFree; +objc_DECLARE void *(*_objc_malloc) (size_t) = GC_malloc; +objc_DECLARE void *(*_objc_atomic_malloc) (size_t) = GC_malloc_atomic; +objc_DECLARE void *(*_objc_valloc) (size_t) = GC_malloc; +objc_DECLARE void *(*_objc_realloc) (void *, size_t) = GC_realloc; +objc_DECLARE void *(*_objc_calloc) (size_t, size_t) = GC_calloc; +objc_DECLARE void (*_objc_free) (void *) = noFree; #else /* !OBJC_WITH_GC */ -void *(*_objc_malloc) (size_t) = malloc; -void *(*_objc_atomic_malloc) (size_t) = malloc; -void *(*_objc_valloc) (size_t) = malloc; -void *(*_objc_realloc) (void *, size_t) = realloc; -void *(*_objc_calloc) (size_t, size_t) = calloc; -void (*_objc_free) (void *) = free; +objc_DECLARE void *(*_objc_malloc) (size_t) = malloc; +objc_DECLARE void *(*_objc_atomic_malloc) (size_t) = malloc; +objc_DECLARE void *(*_objc_valloc) (size_t) = malloc; +objc_DECLARE void *(*_objc_realloc) (void *, size_t) = realloc; +objc_DECLARE void *(*_objc_calloc) (size_t, size_t) = calloc; +objc_DECLARE void (*_objc_free) (void *) = free; #endif /* !OBJC_WITH_GC */