aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog8
-rw-r--r--src/deps.mk18
-rw-r--r--src/emacs.c4
-rw-r--r--src/unexaix.c2
-rw-r--r--src/unexcoff.c2
-rw-r--r--src/unexcw.c3
-rw-r--r--src/unexelf.c2
-rw-r--r--src/unexhp9k800.c3
-rw-r--r--src/unexmacosx.c3
-rw-r--r--src/unexsol.c2
-rw-r--r--src/unexw32.c1
11 files changed, 34 insertions, 14 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 7bc0a8fcc49..14d3e37a8ee 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,13 @@
12011-03-16 Paul Eggert <eggert@cs.ucla.edu> 12011-03-16 Paul Eggert <eggert@cs.ucla.edu>
2 2
3 New file unexec.h, the (simple) interface for unexec.
4 * deps.mk (emacs.o, unexaix.o, unexcw.o, unexcoff.o, unexelf.o):
5 (unexhp9k800.o, unexmacosx.o, unexsol.o, unexw32.o):
6 Depend on unexec.h.
7 * emacs.c [!defined CANNOT_DUMP]: Include unexec.h.
8 * unexaix.c, unexcoff.c, unexcw.c, unexelf.c, unexhp9k800.c:
9 * unexmacosx.c, unexsol.c, unexw32.c: Include unexec.h.
10
3 * syntax.c (Fforward_comment, scan_lists): Rename locals to avoid 11 * syntax.c (Fforward_comment, scan_lists): Rename locals to avoid
4 shadowing. 12 shadowing.
5 (back_comment, skip_chars): Mark vars as initialized. 13 (back_comment, skip_chars): Mark vars as initialized.
diff --git a/src/deps.mk b/src/deps.mk
index 80a5721cf39..c868ff0e3c0 100644
--- a/src/deps.mk
+++ b/src/deps.mk
@@ -93,7 +93,7 @@ editfns.o: editfns.c window.h buffer.h systime.h $(INTERVALS_H) character.h \
93emacs.o: emacs.c commands.h systty.h syssignal.h blockinput.h process.h \ 93emacs.o: emacs.c commands.h systty.h syssignal.h blockinput.h process.h \
94 termhooks.h buffer.h atimer.h systime.h $(INTERVALS_H) lisp.h $(config_h) \ 94 termhooks.h buffer.h atimer.h systime.h $(INTERVALS_H) lisp.h $(config_h) \
95 globals.h ../lib/unistd.h window.h dispextern.h keyboard.h keymap.h \ 95 globals.h ../lib/unistd.h window.h dispextern.h keyboard.h keymap.h \
96 frame.h coding.h gnutls.h msdos.h 96 frame.h coding.h gnutls.h msdos.h unexec.h
97fileio.o: fileio.c window.h buffer.h systime.h $(INTERVALS_H) character.h \ 97fileio.o: fileio.c window.h buffer.h systime.h $(INTERVALS_H) character.h \
98 coding.h msdos.h blockinput.h atimer.h lisp.h $(config_h) frame.h \ 98 coding.h msdos.h blockinput.h atimer.h lisp.h $(config_h) frame.h \
99 commands.h globals.h ../lib/unistd.h 99 commands.h globals.h ../lib/unistd.h
@@ -200,15 +200,15 @@ terminfo.o: terminfo.c lisp.h globals.h $(config_h)
200tparam.o: tparam.c tparam.h lisp.h $(config_h) 200tparam.o: tparam.c tparam.h lisp.h $(config_h)
201undo.o: undo.c buffer.h commands.h window.h dispextern.h msdos.h \ 201undo.o: undo.c buffer.h commands.h window.h dispextern.h msdos.h \
202 lisp.h globals.h $(config_h) 202 lisp.h globals.h $(config_h)
203unexaix.o: unexaix.c lisp.h $(config_h) 203unexaix.o: unexaix.c lisp.h unexec.h $(config_h)
204unexalpha.o: unexalpha.c $(config_h) 204unexalpha.o: unexalpha.c $(config_h)
205unexcw.o: unexcw.c lisp.h $(config_h) 205unexcw.o: unexcw.c lisp.h unexec.h $(config_h)
206unexcoff.o: unexcoff.c lisp.h $(config_h) 206unexcoff.o: unexcoff.c lisp.h unexec.h $(config_h)
207unexelf.o: unexelf.c ../lib/unistd.h $(config_h) 207unexelf.o: unexelf.c unexec.h ../lib/unistd.h $(config_h)
208unexhp9k800.o: unexhp9k800.c $(config_h) 208unexhp9k800.o: unexhp9k800.c unexec.h $(config_h)
209unexmacosx.o: unexmacosx.c $(config_h) 209unexmacosx.o: unexmacosx.c unexec.h $(config_h)
210unexsol.o: unexsol.c lisp.h $(config_h) 210unexsol.o: unexsol.c lisp.h unexec.h $(config_h)
211unexw32.o: unexw32.c $(config_h) 211unexw32.o: unexw32.c unexec.h $(config_h)
212w16select.o: w16select.c dispextern.h frame.h blockinput.h atimer.h systime.h \ 212w16select.o: w16select.c dispextern.h frame.h blockinput.h atimer.h systime.h \
213 msdos.h buffer.h charset.h coding.h composite.h lisp.h $(config_h) 213 msdos.h buffer.h charset.h coding.h composite.h lisp.h $(config_h)
214widget.o: widget.c xterm.h frame.h dispextern.h widgetprv.h \ 214widget.o: widget.c xterm.h frame.h dispextern.h widgetprv.h \
diff --git a/src/emacs.c b/src/emacs.c
index c49e38f7a67..d30d42f1ee4 100644
--- a/src/emacs.c
+++ b/src/emacs.c
@@ -2085,9 +2085,7 @@ shut_down_emacs (int sig, int no_x, Lisp_Object stuff)
2085 2085
2086#ifndef CANNOT_DUMP 2086#ifndef CANNOT_DUMP
2087 2087
2088/* FIXME: maybe this should go into header file, config.h seems the 2088#include "unexec.h"
2089 only one appropriate. */
2090extern int unexec (const char *, const char *);
2091 2089
2092DEFUN ("dump-emacs", Fdump_emacs, Sdump_emacs, 2, 2, 0, 2090DEFUN ("dump-emacs", Fdump_emacs, Sdump_emacs, 2, 2, 0,
2093 doc: /* Dump current state of Emacs into executable file FILENAME. 2091 doc: /* Dump current state of Emacs into executable file FILENAME.
diff --git a/src/unexaix.c b/src/unexaix.c
index fe9d13d3e47..612d7c1fecf 100644
--- a/src/unexaix.c
+++ b/src/unexaix.c
@@ -40,6 +40,8 @@ what you give them. Help stamp out software-hoarding! */
40 */ 40 */
41 41
42#include <config.h> 42#include <config.h>
43#include "unexec.h"
44
43#define PERROR(file) report_error (file, new) 45#define PERROR(file) report_error (file, new)
44#include <a.out.h> 46#include <a.out.h>
45/* Define getpagesize () if the system does not. 47/* Define getpagesize () if the system does not.
diff --git a/src/unexcoff.c b/src/unexcoff.c
index 4dafabab689..1efde1a9cbc 100644
--- a/src/unexcoff.c
+++ b/src/unexcoff.c
@@ -50,6 +50,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
50 */ 50 */
51 51
52#include <config.h> 52#include <config.h>
53#include "unexec.h"
54
53#define PERROR(file) report_error (file, new) 55#define PERROR(file) report_error (file, new)
54 56
55#ifndef CANNOT_DUMP /* all rest of file! */ 57#ifndef CANNOT_DUMP /* all rest of file! */
diff --git a/src/unexcw.c b/src/unexcw.c
index 02add901bbd..b5d72e61550 100644
--- a/src/unexcw.c
+++ b/src/unexcw.c
@@ -19,6 +19,8 @@ You should have received a copy of the GNU General Public License
19along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ 19along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
20 20
21#include <config.h> 21#include <config.h>
22#include "unexec.h"
23
22#include <setjmp.h> 24#include <setjmp.h>
23#include <lisp.h> 25#include <lisp.h>
24#include <stdio.h> 26#include <stdio.h>
@@ -299,4 +301,3 @@ unexec (const char *outfile, const char *infile)
299 301
300 return (0); 302 return (0);
301} 303}
302
diff --git a/src/unexelf.c b/src/unexelf.c
index 1009c87066b..182b9f8a16b 100644
--- a/src/unexelf.c
+++ b/src/unexelf.c
@@ -386,6 +386,8 @@ temacs:
386 Instead we read the whole file, modify it, and write it out. */ 386 Instead we read the whole file, modify it, and write it out. */
387 387
388#include <config.h> 388#include <config.h>
389#include <unexec.h>
390
389extern void fatal (const char *msgid, ...); 391extern void fatal (const char *msgid, ...);
390 392
391#include <sys/types.h> 393#include <sys/types.h>
diff --git a/src/unexhp9k800.c b/src/unexhp9k800.c
index c0471992a72..9889ffd63fc 100644
--- a/src/unexhp9k800.c
+++ b/src/unexhp9k800.c
@@ -50,6 +50,8 @@
50*/ 50*/
51 51
52#include <config.h> 52#include <config.h>
53#include "unexec.h"
54
53#include <stdio.h> 55#include <stdio.h>
54#include <fcntl.h> 56#include <fcntl.h>
55#include <errno.h> 57#include <errno.h>
@@ -319,4 +321,3 @@ display_header (hdr, auxhdr)
319 hdr->unloadable_sp_location, hdr->unloadable_sp_size); 321 hdr->unloadable_sp_location, hdr->unloadable_sp_size);
320} 322}
321#endif /* DEBUG */ 323#endif /* DEBUG */
322
diff --git a/src/unexmacosx.c b/src/unexmacosx.c
index 2e46c063e95..0df0bb8451d 100644
--- a/src/unexmacosx.c
+++ b/src/unexmacosx.c
@@ -95,6 +95,9 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
95#undef malloc 95#undef malloc
96#undef realloc 96#undef realloc
97#undef free 97#undef free
98
99#include "unexec.h"
100
98#include <stdio.h> 101#include <stdio.h>
99#include <fcntl.h> 102#include <fcntl.h>
100#include <stdarg.h> 103#include <stdarg.h>
diff --git a/src/unexsol.c b/src/unexsol.c
index e1a10f7d211..ae91c170859 100644
--- a/src/unexsol.c
+++ b/src/unexsol.c
@@ -1,6 +1,8 @@
1/* Trivial unexec for Solaris. */ 1/* Trivial unexec for Solaris. */
2 2
3#include <config.h> 3#include <config.h>
4#include "unexec.h"
5
4#include <dlfcn.h> 6#include <dlfcn.h>
5#include <setjmp.h> 7#include <setjmp.h>
6 8
diff --git a/src/unexw32.c b/src/unexw32.c
index 829c864c960..c921cd657d5 100644
--- a/src/unexw32.c
+++ b/src/unexw32.c
@@ -21,6 +21,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
21*/ 21*/
22 22
23#include <config.h> 23#include <config.h>
24#include "unexec.h"
24 25
25#include <stdio.h> 26#include <stdio.h>
26#include <fcntl.h> 27#include <fcntl.h>