From 9a8724cdd0832e9026908b64bba760e0257c64fd Mon Sep 17 00:00:00 2001 From: Alessandro Ranellucci Date: Fri, 6 Nov 2015 11:51:24 +0100 Subject: [PATCH] More compilation changes for Win32 --- xs/src/myinit.h | 26 +++++++++++++++++++++++++- xs/xsp/GCodeSender.xsp | 1 - 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/xs/src/myinit.h b/xs/src/myinit.h index f98d94020..fd7c5a07d 100644 --- a/xs/src/myinit.h +++ b/xs/src/myinit.h @@ -1,9 +1,33 @@ #ifndef _myinit_h_ #define _myinit_h_ -// this needs to be included early for MSVC (listing it in Build.PL is not enough) +// undef some macros set by Perl which cause compilation errors on Win32 #undef read #undef seekdir +#undef bind +#undef send +#undef connect +#undef wait +#undef accept +#undef close +#undef open +#undef write +#undef socket +#undef listen +#undef shutdown +#undef ioctl +#undef getpeername +#undef rect +#undef setsockopt +#undef getsockopt +#undef getsockname +#undef gethostname +#undef select +#undef socketpair +#undef recvfrom +#undef sendto + +// these need to be included early for Win32 (listing it in Build.PL is not enough) #include #include #include diff --git a/xs/xsp/GCodeSender.xsp b/xs/xsp/GCodeSender.xsp index 4559f8993..cef61128f 100644 --- a/xs/xsp/GCodeSender.xsp +++ b/xs/xsp/GCodeSender.xsp @@ -3,7 +3,6 @@ #ifdef BOOST_LIBS %{ -#include #include "libslic3r/GCodeSender.hpp" %}