diff options
Diffstat (limited to 'src/emacs.c')
| -rw-r--r-- | src/emacs.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/src/emacs.c b/src/emacs.c index 27e349c637f..4bbbf84ebab 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -1770,16 +1770,21 @@ main (argc, argv | |||
| 1770 | #endif | 1770 | #endif |
| 1771 | } | 1771 | } |
| 1772 | 1772 | ||
| 1773 | /* Set up for profiling. This is known to work on FreeBSD and | 1773 | /* Set up for profiling. This is known to work on FreeBSD, |
| 1774 | GNU/Linux. It might work on some other systems too. Give it a | 1774 | GNU/Linux and MinGW. It might work on some other systems too. |
| 1775 | try and tell us if it works on your system. To compile for | 1775 | Give it a try and tell us if it works on your system. To compile |
| 1776 | profiling use something like `make CFLAGS="-pg -g -O -DPROFILING=1'. */ | 1776 | for profiling use something like: |
| 1777 | #if defined (__FreeBSD__) || defined (__linux) | 1777 | `make CFLAGS="-pg -g -O -DPROFILING=1'. */ |
| 1778 | #if defined (__FreeBSD__) || defined (GNU_LINUX) || defined(__MINGW32__) | ||
| 1778 | #ifdef PROFILING | 1779 | #ifdef PROFILING |
| 1779 | if (initialized) | 1780 | if (initialized) |
| 1780 | { | 1781 | { |
| 1781 | extern void _mcleanup (); | 1782 | extern void _mcleanup (); |
| 1783 | #ifdef __MINGW32__ | ||
| 1784 | extern unsigned char etext asm ("etext"); | ||
| 1785 | #else | ||
| 1782 | extern char etext; | 1786 | extern char etext; |
| 1787 | #endif | ||
| 1783 | extern void safe_bcopy (); | 1788 | extern void safe_bcopy (); |
| 1784 | extern void dump_opcode_frequencies (); | 1789 | extern void dump_opcode_frequencies (); |
| 1785 | 1790 | ||
| @@ -2253,7 +2258,7 @@ You must run Emacs in batch mode in order to dump it. */) | |||
| 2253 | if (! noninteractive) | 2258 | if (! noninteractive) |
| 2254 | error ("Dumping Emacs works only in batch mode"); | 2259 | error ("Dumping Emacs works only in batch mode"); |
| 2255 | 2260 | ||
| 2256 | #ifdef __linux__ | 2261 | #ifdef GNU_LINUX |
| 2257 | if (heap_bss_diff > MAX_HEAP_BSS_DIFF) | 2262 | if (heap_bss_diff > MAX_HEAP_BSS_DIFF) |
| 2258 | { | 2263 | { |
| 2259 | fprintf (stderr, "**************************************************\n"); | 2264 | fprintf (stderr, "**************************************************\n"); |
| @@ -2265,7 +2270,7 @@ You must run Emacs in batch mode in order to dump it. */) | |||
| 2265 | fprintf (stderr, "exec-shield in etc/PROBLEMS for more information.\n"); | 2270 | fprintf (stderr, "exec-shield in etc/PROBLEMS for more information.\n"); |
| 2266 | fprintf (stderr, "**************************************************\n"); | 2271 | fprintf (stderr, "**************************************************\n"); |
| 2267 | } | 2272 | } |
| 2268 | #endif /* __linux__ */ | 2273 | #endif /* GNU_LINUX */ |
| 2269 | 2274 | ||
| 2270 | /* Bind `command-line-processed' to nil before dumping, | 2275 | /* Bind `command-line-processed' to nil before dumping, |
| 2271 | so that the dumped Emacs will process its command line | 2276 | so that the dumped Emacs will process its command line |