unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Ben Key <bkey76@gmail.com>
To: Emacs Development <Emacs-devel@gnu.org>
Subject: Compilation error caused by SPARE_MEMORY
Date: Sun, 5 Jun 2011 16:10:30 -0500	[thread overview]
Message-ID: <BANLkTi=jtSrz5VdOrhPCRyCS2Y+axk5rTw@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1175 bytes --]

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.

[-- Attachment #2: Type: text/html, Size: 1512 bytes --]

             reply	other threads:[~2011-06-05 21:10 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-05 21:10 Ben Key [this message]
2011-06-05 21:54 ` Compilation error caused by SPARE_MEMORY Glenn Morris
2011-06-06  4:59   ` Paul Eggert
2011-06-06 12:02     ` Donald Ephraim Curtis
2011-06-06 16:42       ` bug#8800: " Paul Eggert
2011-06-06  2:50 ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='BANLkTi=jtSrz5VdOrhPCRyCS2Y+axk5rTw@mail.gmail.com' \
    --to=bkey76@gmail.com \
    --cc=Emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).