unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Re: Unable to bootstrap GNU Emacs 21.3 (SOLVED)
@ 2003-10-27 10:47 David PONCE
  2003-10-28 20:39 ` Richard Stallman
  0 siblings, 1 reply; 4+ messages in thread
From: David PONCE @ 2003-10-27 10:47 UTC (permalink / raw)


Hi All,

To solve this annoying problem, I also posted a bug report on the
Redhat Fedora mailing list.  And I got an explanation on what happened
and on how to solve the issue.  I think it could be worth to note that
somewhere, perhaps in the etc/PROBLEMS file.

In fact, in recent Linux kernels, there is a new "Exec-shield"
functionality:

"[...] Exec-shield is a security-enhancing modification to the Linux
kernel that makes large parts of specially-marked programs _ including
their stack _ not executable. This can reduce the potential damage of
some security holes. Exec-shield is related to the older "non-exec
stack patch" but has the potential to provide greater protection.

Exec-shield can also randomize the virtual memory addresses at which
certain binaries are loaded. This randomized VM mapping makes it more
difficult for a malicious application to improperly access code or
data based on knowledge of the code or data's virtual address.

[...]

Exec-shield functionality is available only to binaries that have been
built (and marked) using the toolchain (compiler, assembler, linker)
available with Fedora [...]"

The problem is that Exec-shield enables a different memory layout that
breaks the emacs dumper.

Notice that this potentially affects all versions of Emacs.  On my system
building both Emacs 21.3.1 and latest 21.3.50.1 failed with segfault on:

temacs --batch --load loadup [dump|bootstrap]

There are two solutions to build Emacs:

- Turn off Exec-shield:
  
  echo 0 > /proc/sys/kernel/exec-shield

- Temporarily disable Exec-shield while building Emacs, using the
  `setarch' command:

  setarch i386 ./configure ...
  setarch i386 make ...

Hope this will help.

David

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2003-10-30  4:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-27 10:47 Unable to bootstrap GNU Emacs 21.3 (SOLVED) David PONCE
2003-10-28 20:39 ` Richard Stallman
2003-10-28 22:11   ` David Ponce
2003-10-30  4:18     ` Richard Stallman

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).