pthreads on windows includes config.h
Attempting to compile Tor fails for me, because we use AM_CONFIG_HEADER(orconfig.h). This means that autofoo defines HAVE_CONFIG_H, and pthread.h attempts to include config.h when HAVE_CONFIG_H is defined.
There are a two solutions that I can see: We can just manually undefine HAVE_CONFIG_H (we don't use it anywhere), so that pthread won't include it. This doesn't seem to have negative side effects (orconfig.h is already included by our source anyways, so the definitions are available).
We could rename our config.[ch] files to something else and use config.h for the file generated during configure. This is a lot of work and doesn't mean a functional improvement that I can think of, so this is probably not what we want to do.
A third possible solution that I don't know how to make work is to stop configure from defining HAVE_CONFIG_H. Maybe that is easily possible and could be an alternative to the first idea.