emacs-devel
[Top][All Lists]
Advanced

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

Compilation error caused by SPARE_MEMORY


From: Ben Key
Subject: Compilation error caused by SPARE_MEMORY
Date: Sun, 5 Jun 2011 16:10:30 -0500

Hello,

I am seeing a compilation error in alloc.c on line 3287 on Mac OS X due to SPARE_MEMORY being undeclared.

Starting on line 193 of alloc.c is the following code block that attempts to define
SPARE_MEMORY.

#ifndef SYSTEM_MALLOC
/* Amount of spare memory to keep in large reserve block.  */

#define SPARE_MEMORY (1 << 14)
#endif

The problem is that
SYSTEM_MALLOC is defined on Mac OS X but SPARE_MEMORY is not defined in any of the system header files (at least running 'grep -RnH SPARE_MEMORY *' in the /usr/include/ directory yields no results).  I believe that the above code block should be changed to the following but I am not certain how this change will affect other platforms.

#ifndef SPARE_MEMORY
/* Amount of spare memory to keep in large reserve block.  */

#define SPARE_MEMORY (1 << 14)
#endif

Note that
SPARE_MEMORY does not appear to be defined on Windows either.  At least I could not find it in any of the MinGW header files.

How is
SPARE_MEMORY defined on systems that do define it?  Is the above change the correct one?  It fixes the problem on Mac OS X but I do not want to make a change that will cause problems for other operating systems.
 


reply via email to

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