Hi,

I get errors when building gnustep trunk r30916, using libobjc2 from
the same revision. This does not happen with the gcc runtime because
the problematic code is then skipped by an #ifndef.

Making all for library libgnustep-base...
 Compiling file GSLocale.m ...
 Compiling file preface.m ...
 Compiling file cifframe.m ...
 Compiling file CXXException.m ...
...snip...
 Compiling file NSString.m ...
 Compiling file NSTask.m ...
 Compiling file NSThread.m ...
NSThread.m:288:20: error: static declaration of ‘objc_thread_add’
follows non-static declaration
/usr/lib/gcc/i686-pc-linux-gnu/4.5.0/include/objc/thr.h:91:6: note:
previous declaration of ‘objc_thread_add’ was here
make[4]: *** [obj/libgnustep-base.obj/NSThread.m.o] Error 1
make[3]: *** [internal-library-all_] Error 2
make[2]: *** [libgnustep-base.all.library.variables] Error 2
make[1]: *** [internal-all] Error 2
make: *** [internal-all] Error 2

Removing the static keyword in NSThread.m makes the library compile,
but it is not linkable so the build now stops on the first tool:

Making all in Tools ...
Making all for tool autogsdoc...
 Compiling file autogsdoc.m ...
 Compiling file AGSParser.m ...
 Compiling file AGSOutput.m ...
 Compiling file AGSIndex.m ...
 Compiling file AGSHtml.m ...
 Linking tool autogsdoc ...
../Source/./obj/libgnustep-base.so: undefined reference to
`__objc_is_multi_threaded'
../Source/./obj/libgnustep-base.so: undefined reference to `objc_mutex_unlock'
../Source/./obj/libgnustep-base.so: undefined reference to `objc_mutex_lock'
collect2: ld returned 1 exit status
make[4]: *** [obj/autogsdoc] Error 1
make[3]: *** [internal-tool-all_] Error 2
make[2]: *** [autogsdoc.all.tool.variables] Error 2
make[1]: *** [internal-all] Error 2
make: *** [internal-all] Error 2

The missing symbols are used by the implementation of objc_thread_add
from NSThread.m above, which is not compiled when configure finds that
libobjc already provides the function.

-Truls

_______________________________________________
Discuss-gnustep mailing list
Discuss-gnustep@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnustep

Reply via email to