Subject: | Won't compile on Strawberry Perl 64 bit |
Date: | Fri, 07 Jan 2011 16:27:07 +0100 |
To: | bug-Win32-Daemon [...] rt.cpan.org |
From: | Haiko Strotbek <haiko [...] strotbek.com> |
Hi,
when I'm trying to compile Win32::Daemon on a 64 bit edition of
Strawberry Perl there are two errors preventing a successful installation:
Daemon.xs:1355: error: cast from 'void*' to 'DWORD' loses precision
Daemon.xs:2225: error: cast from 'SERVICE_STATUS_HANDLE__*' to 'DWORD'
loses precision
I was able to get around the problem by replacing
Daemon.xs:1355 by
RETVAL = PTR2IV(ghServiceThread);
and Daemon.xs:2225 by
RETVAL = PTR2IV(ghService);
It seems to work for me but I think the return type of functions should
also be changed to T_PTR or any other 64 bit capable type.
Regards
Haiko Strotbek