Source: gcc-mingw-w64
Version: 4.9.2-21+15.4
Severity: normal

Hi,

I was investigating why some code that probably should have built
cleanly with this toolchain didn't, and the reason is it turns out
to not be defining _REENTRANT when the -pthread option is passed.

Which is a little bit weirder because at first blush it looks like
it had intended to.  Compare:

 $ gcc -dumpspecs | grep -B1 _REENTRANT
 *cpp:
 %{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}

 $ x86_64-w64-mingw32-gcc -dumpspecs | grep -B1 _REENTRANT
 *cpp:
 %{posix:-D_POSIX_SOURCE} %{mthreads:-D_MT} %{municode:-DUNICODE} 
%{pthread:-D_REENTRANT} %{!no-pthread:-U_REENTRANT}


 $ g++ -pthread -dM -E - < /dev/null | grep _REENTRANT
 #define _REENTRANT 1

 $ x86_64-w64-mingw32-gcc -pthread -dM -E - < /dev/null | grep _REENTRANT
 <crickets>


The "!no-pthread" part there, looks to me like either a typo or
something that has outsmarted itself :)

  Cheers,
  Ron


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to