|
From: avlomwel <av...@fi...> - 2003-12-02 07:59:10
|
Odd, MAXFLOAT is allso in use somewhere. statslanguage.y
the typografy under windows is not POSIX compliant, since MAXFLOAT is
accepted. You might want to try MAX_INT instead of MAXINT.
Or go through the include files and find the right name for it.
Something else that goes wrong under dos is PI. The values there are
wrong. This will impact some planet info like headings etc.
Further the string.h instead of the strings.h library should be included under
dos. (Maybe the made it compliant nowadays, but trying it won't hurt.)
Last and that has probably something to do with the 17 planets. a compiler
swith need to be added to make int 4 bytes long. (Default is 2. This will
create a rollover in the extraction of the planet datafiles.)
greetings;
Alexander
PS:
When stats was still dos comlpiant there used to be a compiler directive. I
propose to introduce this again.
>gcc -D DOS
/* For example: stats.h */
#ifdef DOS
#define MAXINT 1000000
#include <string.h>
#eldef /* Not sure about this syntax */
#include <strings.h>
#endif
On Tue, 2 Dec 2003, Martijn Otten wrote:
> Date: Tue, 02 Dec 2003 05:54:19 +0100
> From: Martijn Otten <mo...@dd...>
> Reply-To: pla...@li...
> To: ma...@va...
> Cc: pla...@li...
> Subject: [Plantool-developer] Re: Stats.exe is working
>
> Maurits van Rees wrote:
>
> > Hello,
> >
> > I changed the stats 1.13 source a bit:
> > - stats.h: I removed the line #include values.h
> > - statsUnp.c: I added a line almost at the top: MAXINT = 1000000; This is
> > the only file that uses values.h and apparently only for the MAXINT. The
> > one million is probably not good.
> >
> > But with these changes I can get a compile of stats.exe!
> >
> > It doesn't seem to recognize all my planets though. I am quite sure that I
> > have more than 17! Maybe that's because it is an earlier version, but it
> > may be something that goes wrong in Windows only. Ships seem fine. Sanity
> > looks okay. No core dumps so far.
> >
> > But, Martijn: it would better to get the latest source from cvs and try it
> > with that. [I cc-ed this email to him.] I'll try that later as well.
> >
> > --
> > Maurits
>
>
> Maurits,
>
> thanx for compiling stats. It is working fine (although I may have some
> user interface suggestions).
>
> In my case stats is only showing 27 planets. In RL I'm the proud owner
> of 54 (and you 34). A possible reason for this behaviour might be: the
> usage of CR/LF (Windows) instead of a single LF (Unix?).
>
> MO
>
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: SF.net Giveback Program.
> Does SourceForge.net help you be more productive? Does it
> help you create better code? SHARE THE LOVE, and help us help
> YOU! Click Here: http://sourceforge.net/donate/
> _______________________________________________
> Plantool-developer mailing list
> Pla...@li...
> https://lists.sourceforge.net/lists/listinfo/plantool-developer
>
---------------------------------------------------------------------
Never be afraid to try something new. Remember, amateurs built the
ark; professionals built the Titanic.
---------------------------------------------------------------------
|