[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Trying to use GNUstep and libdispatch in an ARC based objective-C progra

From: Mathias Bauer
Subject: Trying to use GNUstep and libdispatch in an ARC based objective-C program
Date: Wed, 08 Jan 2014 00:11:19 +0100
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.2.0


I've set up a build environment with the lastest trunk versions of GNUstep, clang and libobjc2 on Ubuntu 12.04.

In my program (compiled with ARC) I tried to dispatch a block with

   dispatch_async(dispatch_get_global_queue( DISPATCH_QUEUE_PRIORITY_DEFAULT, 
0), ^ ...

This crashes immediately when the dispatch_get_global_queue call returns. The stack shows that the compiler executes a "retain" call on the returned object, but libdispatch does not seem to be compiled with objc support at all, so I assume that the returned object just is a c struct.

I used

./configure --enable-debug-by-default --enable-objc-nonfragile-abi --with-layout=gnustep

for the GNUstep make build and

./configure --disable-mixedabi

for building GNUstep base.

For libdispatch I used the configure provided by the repository at


I assume that the culprit is in the libdispatch build. I manually patched the generated config.h file to support OBJC, but this obviously isn't enough.

From reading posts from this list I concluded that there are people here that used GNUstep with libdispatch and ARC successfully, so perhaps someone can give me a hint how I can solve my problem.

Thanks in advance,

reply via email to

[Prev in Thread] Current Thread [Next in Thread]