[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

GNUstep on Windows - libm5.dll caveat

From: Christopher Armstrong
Subject: GNUstep on Windows - libm5.dll caveat
Date: Thu, 29 Nov 2007 23:23:16 +1100
User-agent: Thunderbird (Windows/20071031)

Hi all

This is just a notice about a problem I've been having with GNUstep on
Windows. I wanted to post a description of the problem and the solution
in case it ever comes up again as a note of my experience with GNUstep.
I've been trying to integrate uxtheme with GNUstep and use this as an
example to develop the themeing API.

I use the gnuwin32 binary packages ( to provide
libtiff, libpng, zlib, etc. to provide the necessary libraries for
GNUstep on Windows. I compile my own libxml2 and disable libxslt2 (when
it gets linked into gnustep-base, it seems to clobber all the symbols
and results in libgnustep-base.dll containing only its symbols). The way
I download gnuwin32 was by telling it to get all the packages (I thought
this would be easier).

One of the packages it comes with is libm5.dll, which seems to be a math
library that utilises the x86 floating point instructions. This library
gets linked in by accident because GNUstep passes "-lm" to the command
line, which snags its import library. Somehow, its floating point
functions don't seem to work with GNUstep and it causes all sorts of
bizarre and unexpected behaviour. Some examples include:
* Scrolling tears in a NSScrollView, probably because the floating point
calculations for scrolling don't work out correctly.
* NSScanner -scanDouble: function fails when it calls pow() (this
returns junk). This affects things in unusual places, e.g. the GUI has a
white shade wherever it is supposed to use NSLightGray or NSDarkGray,
because NSColor sets up the System colorlist by scanning strings with
floating point values in them (and -[NSScanner scanFloat:] returns NaN).

I know this message is probably "noise", but couldn't think where else
to put it. Maybe useful as an example of one of those hairy and bizarre
problems that occurs. I've spent all week trying to figure it out.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]