or use a define
#ifdef WINVER
#define rpcemu_sleep(_s) Sleep(_s*1000)
#else
#define rpcemu_sleep(_s) sleep(_s)
#endif
Joe
Date: Fri, 18 Jul 2008 18:01:26 +0200
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: [Rpcemu] Wtr.: Re: How to build RPCemu for Windows.
CC: [EMAIL PROTECTED]; [email protected]
Correct..
unix has usleep for microseconds.
so when taking into account the differences between the platforms perhaps
_sleep is a better solution..
Jan Rinze.
2008/7/18 Joe Burmeister <[EMAIL PROTECTED]>:
Hi Steffen, rpcemu
About Sleep()
http://msdn.microsoft.com/en-us/library/ms686298(VS.85).aspx
it works in milliseconds but POSIX sleep() is in seconds......
http://www.opengroup.org/onlinepubs/000095399/functions/sleep.html
at least that was my understanding....
Joe
> Date: Fri, 18 Jul 2008 00:00:57 +0200
> To: [email protected]
> From: [EMAIL PROTECTED]
> Subject: [Rpcemu] Wtr.: Re: How to build RPCemu for Windows.
>
> Hi David (and everybody else),
>
> I also don't know anything about C and using it on Windows, so I decided
> to just try and see how far I get...
>
> ...and, a few hours later, I now have
> - a seemingly working MinGW gcc environment
> - the Eclipse IDE along with CDT and the SVN client using the
> MinGW build environment
> - the current RPCemu sources from SVN
> - a successfully "built from latest sources" RPCemu.exe
>
> (Eclipse was chosen because I use it at work for Java development
> and so I'm familiar with it wrt using CVS and SVN)
>
> The most time consuming tasks for someone not familiar with
> this C stuff is
> 1.) how to get a makefile compatible with Windows
> (thankfully, the Eclipse IDE seems to be able to do that automatically)
> 2.) which libs are needed for linking
>
> A ready-to-use Windows build script would be great, as well
> as a "how-to" for people starting from scratch.
>
> > I assume this means MinGW http://www.mingw.org/ Following the downloads
> > link goes to a page with nothing to download.
>
> Use
> http://sourceforge.net/project/showfiles.php?group_id=2435
> and download the "Automated MinGW installer"
>
> I would suggest you download and install the Base set along
> with g++ and MinGW make.
>
> Then download the readily-built "allegro for mingw" libs package.
> http://sourceforge.net/project/showfiles.php?group_id=5665&package_id=168871
>
> You already seem to have the RPCemu sources. I needed
> to change rpc-win.c since linking failed with function "sleep"
> not being found - I just changed it to Sleep, which seems
> to be an equivalent one from the Win32 API.
>
> Libs to be linked against are mingw32, comdlg32 and alleg.
> Confusingly, these are called lib.a on your harddisc,
> but need to be passed as -l to the linker.
>
> Now you have everything to successfully build RPCemu from
> sources.
>
> Steffen
>
>
>
> _______________________________________________
> Rpcemu mailing list
> [email protected]
> http://www.riscos.info/cgi-bin/mailman/listinfo/rpcemu
Find out how to make Messenger your very own TV! Try it Now!
_______________________________________________
Rpcemu mailing list
[email protected]
http://www.riscos.info/cgi-bin/mailman/listinfo/rpcemu
_________________________________________________________________
Invite your Facebook friends to chat on Messenger
http://clk.atdmt.com/UKM/go/101719649/direct/01/
_______________________________________________
Rpcemu mailing list
[email protected]
http://www.riscos.info/cgi-bin/mailman/listinfo/rpcemu