<div dir="ltr">I think the problem with the commit was that setIOManagerControlFd() was defined for all OS types, whereas the prototype was defined only when mingw32_HOST_OS is not defined.I think the resolution is to only define setIOManagerControlFd when mingw32_HOST_OS is not defined, since if I understand correctly, on Windows we don't use the IO manager in GHC.Event anyway.<div>
<br></div><div>I created a Phab diff that reverts the revert of the original commit and also fixes it as explained above. I tried to update the previous diff (D129), but I couldn't because it is closed. So I created a new one (D174).</div>
<div><br></div><div>Austin: can you help me validate it on Windows? I don't have a Windows machine available. </div><div><br></div><div>The patch also avoids defining the io_manager_control_wr_fd field in Capability struct when mingw32_HOST_OS is not defined.</div>
<div><br></div><div>While we are at it, where should the prototype for setIOManagerControlFd be? It is currently in includes/rts/IOManager.h, whereas the function is defined in rts/Schedule.c. Should the prototype be moved to rts/Schedule.h? Or should the setIOManagerControlFd definition be moved somewhere else instead? </div>
<div><br></div><div>Andi</div><div><br></div><div><br></div><div><br></div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Aug 22, 2014 at 5:01 PM, Austin Seipp <span dir="ltr"><<a href="mailto:austin@well-typed.com" target="_blank">austin@well-typed.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I've reverted it in the mean time<br>
(4748f5936fe72d96edfa17b153dbfd84f2c4c053), sorry about that. I've<br>
spent some time working on a Windows Phabricator machine, so stay<br>
tuned!<br>
<br>
Andreas, if you need a Windows VM or something temporarily to test, do<br>
let me know.<br>
<div class="HOEnZb"><div class="h5"><br>
On Fri, Aug 22, 2014 at 4:00 PM, Andreas Voellmy<br>
<<a href="mailto:andreas.voellmy@gmail.com">andreas.voellmy@gmail.com</a>> wrote:<br>
> I'm just noticing this thread now... sorry about the delay and the problems!<br>
> I'll look into what happened here.<br>
><br>
><br>
> On Fri, Aug 22, 2014 at 8:04 AM, kyra <<a href="mailto:kyrab@mail.ru">kyrab@mail.ru</a>> wrote:<br>
>><br>
>> I've looked into this patch, it looks like this patch was intended to<br>
>> touch only linuxish IO Manager, but in fact it touched common (os unrelated)<br>
>> code here and there extensively and there are almost no chances somebody<br>
>> else (not the author) can fix the things.<br>
>><br>
>> So, almost the only way to unbreak the build it to revert the patch.<br>
>><br>
>> Regards,<br>
>> Kyra<br>
>><br>
>><br>
>> On 8/22/2014 16:07, Simon Peyton Jones wrote:<br>
>>><br>
>>> Friends<br>
>>><br>
>>> My Windows build is still broken, and has been since Andreas's patch<br>
>>>         commit f9f89b7884ccc8ee5047cf4fffdf2b36df6832df<br>
>>> on Tues 19th.<br>
>>><br>
>>> Please can someone help?  I'm begging.<br>
>>><br>
>>> I suppose that if I hear nothing I can simply revert his patch but that<br>
>>> seems like the Wrong Solution<br>
>>><br>
>>> Thanks<br>
>>><br>
>>> Simon<br>
>>><br>
>>> | -----Original Message-----<br>
>>> | From: Simon Peyton Jones<br>
>>> | Sent: 20 August 2014 23:48<br>
>>> | To: 'Gabor Greif'; '<a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a>'; 'Andreas Voellmy'<br>
>>> | Subject: RE: Windows build fails -- again!<br>
>>> |<br>
>>> | Help!  My Windows build is still falling over as below.<br>
>>> |<br>
>>> | Andreas, you seem to be the author of the commit that broke this.  I'd<br>
>>> | really appreciate a fix.  (From anyone!)<br>
>>> |<br>
>>> | thank you<br>
>>> |<br>
>>> | Simon<br>
>>> |<br>
>>> | | -----Original Message-----<br>
>>> | | From: Simon Peyton Jones<br>
>>> | | Sent: 20 August 2014 09:26<br>
>>> | | To: Gabor Greif; <a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a><br>
>>> | | Subject: RE: Windows build fails -- again!<br>
>>> | |<br>
>>> | | Thanks Gabor.  But it makes no difference.  Your change is inside an<br>
>>> | | #ifdef that checks for windows, and your change is in the no-windows<br>
>>> | | branch only.<br>
>>> | |<br>
>>> | | Also there are two IOManager.h file<br>
>>> | |     includes/rts/IOManager.h<br>
>>> | |     rts/win32/IOManager.h<br>
>>> | |<br>
>>> | | Should there be?  It seems terribly confusing, and I have no idea<br>
>>> which<br>
>>> | | will win when it is #included.<br>
>>> | |<br>
>>> | | Thanks<br>
>>> | |<br>
>>> | | Simon<br>
>>> | |<br>
>>> | | | -----Original Message-----<br>
>>> | | | From: Gabor Greif [mailto:<a href="mailto:ggreif@gmail.com">ggreif@gmail.com</a>]<br>
>>> | | | Sent: 19 August 2014 23:38<br>
>>> | | | To: Simon Peyton Jones<br>
>>> | | | Subject: Re: Windows build fails -- again!<br>
>>> | | |<br>
>>> | | | Simon,<br>
>>> | | |<br>
>>> | | | try this (attached) patch:<br>
>>> | | |<br>
>>> | | | $ git am 0001-Make-sure-that-a-prototype-is-included-for-<br>
>>> | | | setIOMana.patch<br>
>>> | | |<br>
>>> | | | Cheers,<br>
>>> | | |<br>
>>> | | |     Gabor<br>
>>> | | |<br>
>>> | | | PS: on MacOS all is good, so I could not test it at all<br>
>>> | | |<br>
>>> | | | On 8/20/14, Simon Peyton Jones <<a href="mailto:simonpj@microsoft.com">simonpj@microsoft.com</a>> wrote:<br>
>>> | | | > Aaargh!  My windows build is broken, again.<br>
>>> | | | > It's very painful that this keeps happening.<br>
>>> | | | > Can anyone help?<br>
>>> | | | > Simon<br>
>>> | | | ><br>
>>> | | | > "inplace/bin/ghc-stage1.exe" -optc-U__i686 -optc-march=i686<br>
>>> | | | > -optc-fno-stack-protector -optc-Werror -optc-Wall -optc-Wall<br>
>>> | | | > -optc-Wextra -optc-Wstrict-prototypes -optc-Wmissing-prototypes<br>
>>> | | | > -optc-Wmissing-declarations -optc-Winline -optc-Waggregate-return<br>
>>> | | | > -optc-Wpointer-arith -optc-Wmissing-noreturn<br>
>>> -optc-Wnested-externs<br>
>>> | | | > -optc-Wredundant-decls -optc-Iincludes -optc-Iincludes/dist<br>
>>> | | | > -optc-Iincludes/dist-derivedconstants/header<br>
>>> | | | > -optc-Iincludes/dist-ghcconstants/header -optc-Irts<br>
>>> | | | > -optc-Irts/dist/build -optc-DCOMPILING_RTS -optc-fno-strict-<br>
>>> | aliasing<br>
>>> | | | > -optc-fno-common -optc-O2 -optc-fomit-frame-pointer<br>
>>> | | | > -optc-DRtsWay=\"rts_v\" -static  -H32m -O -Werror -Wall -H64m -O0<br>
>>> | | | > -Iincludes -Iincludes/dist<br>
>>> -Iincludes/dist-derivedconstants/header<br>
>>> | | | > -Iincludes/dist-ghcconstants/header<br>
>>> | | | > -Irts -Irts/dist/build -DCOMPILING_RTS -this-package-key rts<br>
>>> | | | > -dcmm-lint -i -irts -irts/dist/build -irts/dist/build/autogen -<br>
>>> | | | Irts/dist/build<br>
>>> | | | > -Irts/dist/build/autogen           -O2    -c rts/Task.c -o<br>
>>> | | | > rts/dist/build/Task.o<br>
>>> | | | ><br>
>>> | | | > cc1.exe: warnings being treated as errors<br>
>>> | | | ><br>
>>> | | | ><br>
>>> | | | ><br>
>>> | | | > rts\Capability.c:1080:6:<br>
>>> | | | ><br>
>>> | | | >      error: no previous prototype for 'setIOManagerControlFd'<br>
>>> | | | ><br>
>>> | | | > rts/<a href="http://ghc.mk:236" target="_blank">ghc.mk:236</a>: recipe for target 'rts/dist/build/Capability.o'<br>
>>> | | | failed<br>
>>> | | | ><br>
>>> | | | > make[1]: *** [rts/dist/build/Capability.o] Error 1<br>
>>> | | | ><br>
>>> | | | > make[1]: *** Waiting for unfinished jobs....<br>
>>> | | | ><br>
>>> | | | > Makefile:71: recipe for target 'all' failed<br>
>>> | | | ><br>
>>> | | | > make: *** [all] Error 2<br>
>>> | | | ><br>
>>> | | | > HEAD (master)$<br>
>>> | | | ><br>
>>> | | | ><br>
>>> | | | ><br>
>>> _______________________________________________<br>
>>> ghc-devs mailing list<br>
>>> <a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a><br>
>>> <a href="http://www.haskell.org/mailman/listinfo/ghc-devs" target="_blank">http://www.haskell.org/mailman/listinfo/ghc-devs</a><br>
>>><br>
>><br>
>> _______________________________________________<br>
>> ghc-devs mailing list<br>
>> <a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a><br>
>> <a href="http://www.haskell.org/mailman/listinfo/ghc-devs" target="_blank">http://www.haskell.org/mailman/listinfo/ghc-devs</a><br>
><br>
><br>
><br>
> _______________________________________________<br>
> ghc-devs mailing list<br>
> <a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a><br>
> <a href="http://www.haskell.org/mailman/listinfo/ghc-devs" target="_blank">http://www.haskell.org/mailman/listinfo/ghc-devs</a><br>
><br>
<br>
<br>
<br>
</div></div><span class="HOEnZb"><font color="#888888">--<br>
Regards,<br>
<br>
Austin Seipp, Haskell Consultant<br>
Well-Typed LLP, <a href="http://www.well-typed.com/" target="_blank">http://www.well-typed.com/</a><br>
</font></span></blockquote></div><br></div>