View Single Post
  #5  
Old 05-14-2005, 02:09 AM
Sarepean
Discordant
 
Join Date: Sep 2004
Posts: 253
Default

Every single winsock2.h error I receive in ANY compile comes from 5 or 6 files and they all start with this "perl_". For example, "perl_client" and stuff like that.

I think I've found the reason why those error out, but I can't find a way to fix it. The devs say that it was fixed in the development branch, but even that compiles with the same errors I was getting before. =/

Here's the post (I can't find quote, otherwise I'd quote it)

-----------------------------------------------------------------

After some code inspection, I found out that both Apache-1.3.20 (os.h) and
mod_perl-1.26 (mod_perl.h) include <winsock2.h> BUT Perl-5.6.1
(/usr/perl/lib/CORE/sys/socket.h) includes <winsock.h>
As the result, compilation failed because of these 2 conflicting header file
inclusion. The include hierachy looks something like this:

Icon.h -> mod_perl.h -> winsock2.h and perl.h
perl.h -> sys/socket.h (in /perl/lib/CORE) -> winsock.h!!

In general, any mod_perl Apache modules (eg: Apache::Icon and FileMan) with C code would fail to compile due to the exact reason.

Any suggestions on how to get around this?

---------------------------------------------------------------------


None of my other files have a problem with any winsock2.h or winsock.h complications. The way I understand it is that to fix this, I would either have to #define WIN_LEAN_AND_MEAN or have the #include winsock2.h call before any calls to icon.h or perl.h

I've installed my platform SDK as recommended by another thread and that didn't do anything for my problem. =/ I'm also running the latest service pack for Visual Studio 2003 .NET Pro.

Please Advise.
-Sarepean
Reply With Quote