MapServer and C math functions

Paul G. Allen pgallen at randomlogic.com
Fri Dec 3 17:21:23 EST 1999


"Paul G. Allen" wrote:

> Stephen Lime wrote:
>
> > Hmmm... Probably just pow, cos/acos, and sin/asin. Probably have more
> > effect in the Proj and freetype libraries.
> >
>
> Then the faster math library will definitely help these portions of mapserv. These
> are some of the slowest functions listed (and as a rule should always be avoided if
> possibly when code speed is an issue).

I couldn't get PROJ.4 to compile with the Compaq math library, but everything else did.
PROJ.4 wants to use __atan2() and the Compaq library only contains atan2(). I noticed
that libm (the Linux math library) contains both __atan2() and atan2(). I thought there
was a compiler switch that would remove leading "_" from library function names but I
couldn't find it. Maybe I was thinking of another compiler?

>
>
> >
> > BTW Did you try recompiling mapserv without your pointer mods after fixing
> > egcs. Seems strange not to allow int *, yet char * still works. I did talk to the
> > shapelib author and he had compiled his stuff on an alpha, but not with linux
> > worked without any mods.
> >
>
> I could easily do this. I will be recompiling anyway to try the Compaq math library
> and when you release another version of mapserv. It's simple enough to modify the
> header file to force POINTER = (int).

Tonight I will look at compiling again without the POINTER mod and also see if I can
track down the labeling problem. I was thinking, the labeling problem is similar to the
one that you fixed a version or two ago (another 3.3 alpha) where my Field Unit labels
would crash the CGI if I tried to display too many of them. If the map only has a couple
streets, streams, or whatever displayed, then the labels work fine. Any more and it
crashes with an error. Again, this is only on the Alpha.

PGA





More information about the mapserver-users mailing list