[Gc] Re: gcc-4.6 with gc-cvs = 'GC_CreateThread' was not declared in this scope

Dmitrijs Ledkovs dmitrij.ledkov at ubuntu.com
Mon Aug 16 13:51:26 PDT 2010


2010/8/16 Ivan Maidanski <ivmai at mail.ru>:
> Hi!
>
> Sun, 15 Aug 2010 14:39:46 +0300 Dmitrijs Ledkovs <dmitrij.ledkov at ubuntu.com>:
>
>> Ivan Maidanski <ivmai at mail.ru> writes:
>>
>> > Hello, Dima!
>> >
>> > 1. GC_CreateThread proto has not been changed in v7.
>> >
>>
>> Thanks for confirmation.
>>
>> > 2. compile win32-threads.cc with -E and examine the preprocessor output to see where GC_CreateThread is declared.
>> >
>>
>> It wasn't defined at all. I have changed the gcc/libjava/configure.ac to
>> define GC_WIN32_THREADS 1. After that everything worked =) it was simply
>> not managing to get through gc_config_macros heuristics.
>
> It's a bit more portable to define GC_THREADS instead.
>

Well part of libjava configure checks for platform and the thread
model used by the "to-be-compiled" gcc. And it better match on the
boehm-gc side =) hence I did this one for now.

I will use GC_THREADS when I do full bootstrap/cleanup of my hacked up
gcc & boehm.

>>
>> > 3. typically it's better to use _beginthreadex instead of CreateThread on Win32.
>> >
>>
>> What is the difference?
>
> There a lot of posts - e.g. http://stackoverflow.com/questions/331536/windows-threading-beginthread-vs-beginthreadex-vs-createthread-c
>
>>
>> > 4. GC_NOT_DLL is now meaningful only for MS Visual Studio (not mingw).
>> >
>>
>> Thanks. Removed.
>>
>> > Regards.
>> >
>>
>> Thanks a lot for the preprocessor hint, got me poking in the right
>> direction.
>>
>> Regards.
>
> Regards.
>


More information about the Gc mailing list