non-gcc kjs/ build fixes

Harri Porten porten at froglogic.com
Fri Dec 7 11:38:51 GMT 2007


Hi Adriaan,

On Fri, 7 Dec 2007, Adriaan de Groot wrote:

> I'd like to apply the following to get kjs/ to compile on non-gcc platforms.
> The patches are similar to earlier fixes I put in, but given the timeframe,
> I'd like to check for permission again. There is also a need to handle
> variants in munmap parameter types. Some munmap()s take a void *, some a char
> * -- I have the latter, so there are a bunch of reinterpret_cast<void *> that
> I need to remove. Would it be acceptable to introduce a macro
> MUNMAP_PTR_T_CAST that does the right thing?

If possible I'd prefer adding a new internal function (ourMunmap()?) that 
has a well-defined API and does the #ifdef/casting ugliness in one place.

> using std::max;
> +using std::memset;

So there are systems that lack the C memset() function - or is it disabled 
by some switch?

> +#if PLATFORM(SOLARIS_OS)
> +#include <strings.h>
> +#endif

Just curious: what was this needed for?

Harri.

P.S. kfm-devel might be a better list.






More information about the kde-core-devel mailing list