Eli Zaretskii [Tue, 3 Jun 2014 07:28:07 +0000 (10:28 +0300)]
Define the size of dumped data for MS-Windows locally on w32heap.c.
configure.ac (C_HEAP_SWITCH): Remove.
src/w32heap.c (DUMPED_HEAP_SIZE): Move from w32heap.h. Don't use
HEAPSIZE; instead, define separate values for the 32- and 64-bit
builds.
src/Makefile.in (C_HEAP_SWITCH): Remove.
(ALL_CFLAGS): Don't use $(C_HEAP_SWITCH).
Eli Zaretskii [Tue, 3 Jun 2014 06:51:18 +0000 (09:51 +0300)]
Fix MS-Windows build broken by menu changes on 2014-06-02.
src/w32menu.c (w32_menu_show): Fix a typo that broke compilation.
src/menu.h (enum button_type, struct _widget_value) [HAVE_NTGUI]:
Define instead of including ../lwlib/lwlib.h, which causes
compilation errors due to missing X11 headers.
Dmitry Antipov [Tue, 3 Jun 2014 04:17:53 +0000 (08:17 +0400)]
* xlwmenu.c (openXftFont): Do not load regular X font here.
(XlwMenuInitialize): Remove ancient #if 0 code.
(XlwMenuDestroy): Likewise. Free regular X font here.
Sam Steingold [Mon, 2 Jun 2014 19:02:31 +0000 (15:02 -0400)]
Avoid the type error on f10 when lookup-key returns an number.
* lisp/menu-bar.el (lookup-key-ignore-too-long): Extract from...
(popup-menu): ...here.
(menu-bar-open): Use it to avoid an error when `lookup-key'
returns a number.
Eli Zaretskii [Mon, 2 Jun 2014 17:08:50 +0000 (20:08 +0300)]
Minor improvement of sbrk emulation on MS-Windows.
src/w32heap.c (malloc_after_dump, realloc_after_dump): Update the
emulated break value only if it goes up.
(sbrk): Add assertion that the INCREMENT argument is strictly
zero. Improve and correct the commentary.
* lisp/progmodes/verilog-mode.el (verilog-mode-version): Bump.
(verilog-auto-arg-format): New option, to support newlines in AUTOARG.
(verilog-type-font-keywords): Add nor.
(verilog-batch-execute-func): Force reading of Local Variables.
Fix printing "no changes to be saved" with verilog-batch.
(verilog-auto-arg-ports): Doc fix.
Add verilog-auto-arg-format to support newlines in AUTOARG.
(verilog-auto-arg): Doc fix.
Paul Eggert [Mon, 2 Jun 2014 06:08:49 +0000 (23:08 -0700)]
Improve AIX-related merge from emacs-24.
* conf_post.h (FLEXIBLE_ARRAY_MEMBER): Fix comment.
* lisp.h (ENUMABLE) [!_AIX]: Don't define to 0 merely because we're
not on AIX; since we're on the trunk we can use enums more broadly.
Paul Eggert [Sun, 1 Jun 2014 23:58:38 +0000 (16:58 -0700)]
Merge from gnulib.
This incorporates:
2014-06-02 acl: apply pure attribute to two functions
2014-06-01 gnulib-common.m4: add _GL_UNUSED_LABEL
2014-05-31 dup2, fcntl, fcntl-h: port to AIX 7.1
2014-05-30 ftoastr: work around compiler bug in IBM xlc 12.1
* lib/acl-internal.h, lib/fcntl.in.h, lib/ftoastr.h:
* m4/dup2.m4, m4/fcntl.m4, m4/gnulib-common.m4:
Update from gnulib.
Paul Eggert [Sun, 1 Jun 2014 07:06:28 +0000 (00:06 -0700)]
Bring back the changes to GDB-visible symbols, but only on AIX.
And only if it's not pre-4.2 GCC.
* lisp.h (ENUMABLE, DEFINE_GDB_SYMBOL_ENUM): New macros.
(ARRAY_MARK_FLAG, PSEUDOVECTOR_FLAG, VALMASK): Use them.
(ARRAY_MARK_FLAG_val, PSEUDOVECTOR_FLAG_val, VALMASK_val):
New macros.
Glenn Morris [Sun, 1 Jun 2014 02:36:40 +0000 (19:36 -0700)]
* loadup.el (load-prefer-newer): Set non-nil when dumping.
--eval doesn't work (or not early enough) during dumping.
Making load-prefer-newer non-nil by default would be simpler...
Paul Eggert [Fri, 30 May 2014 20:19:29 +0000 (13:19 -0700)]
Fix port to 32-bit AIX with xlc.
This doesn't fix Bug#17598, but it does fix a regression since Emacs
built with xlc until recently, and perhaps it'll help us fix Bug#17598.
* configure.ac (GC_SETJMP_WORKS): Define for AIX, too.
Merge from gnulib, incorporating:
2014-05-30 ftoastr: work around compiler bug in IBM xlc 12.1
* lib/ftoastr.c: Update from gnulib.
* src/alloc.c (gdb_make_enums_visible): Remove FLOAT_TO_STRING_BUFSIZE.
* src/conf_post.h (FLEXIBLE_ARRAY_MEMBER) [__IBMC__]: Don't define to empty.
* src/lisp.h (FLOAT_TO_STRING_BUFSIZE): Make it a macro, instead of an enum,
to work around a compiler bug in IBM xlc 12.1.
Eli Zaretskii [Fri, 30 May 2014 09:02:55 +0000 (12:02 +0300)]
Enhance error checking in heap allocation routines on MS-Windows.
src/w32heap.c (malloc_before_dump, malloc_after_dump)
(malloc_before_dump, realloc_after_dump, realloc_before_dump)
(mmap_alloc, mmap_realloc): Check for errors more thoroughly and
set errno where appropriate to emulate CRT functions.
Dmitry Antipov [Fri, 30 May 2014 07:40:29 +0000 (11:40 +0400)]
Debugging facility to check whether 'const char *' points to
relocatable data of non-pure Lisp string.
* alloc.c (maybe_lisp_pointer): New function, refactored out of ...
(mark_maybe_pointer): ... adjusted user.
(relocatable_string_data_p): New function.
* lisp.h (relocatable_string_data_p): Add prototype.
* xdisp.c (message_with_string): If ENABLE_CHECKING, make sure
the pointer to relocatable Lisp data is not used.
Paul Eggert [Fri, 30 May 2014 04:12:08 +0000 (21:12 -0700)]
Don't let SIGINT handling block SIGCHLD indefinitely.
* atimer.c (block_atimers):
* callproc.c (block_child_signal): Block SIGINT too;
otherwise, its handler might now unblock signals that it shouldn't.
* keyboard.c (read_char): Clear signal mask, since we may
be in a SIGINT handler, and many signals may be masked.
* keyboard.c (handle_interrupt):
* sysdep.c (handle_arith_signal):
Clear signal mask instead of just unblocking the signal that
was received, since several signals may be blocked at this point.
nt/Makefile.in (DONT_INSTALL): Now empty.
(addsection${EXEEXT}): Remove target.
nt/addsection.c: File removed.
src/Makefile.in (TEMACS_POST_LINK): Remove target.
(emacs$(EXEEXT)): Remove $(ADDSECTION) from prerequisites.
(temacs$(EXEEXT)): Remove $(TEMACS_POST_LINK) from the recipe.
Eli Zaretskii [Thu, 29 May 2014 16:47:49 +0000 (19:47 +0300)]
Fix bug #17588 with mouse highlight when an X frame is redisplayed frequently.
src/xterm.c (x_update_window_end): Don't invalidate the entire
mouse-highlight info, just signal frame_up_to_date_hook that mouse
highlight needs to be redisplayed.
Paul Eggert [Thu, 29 May 2014 15:05:06 +0000 (08:05 -0700)]
Don't substitute sigprocmask for pthread_sigmask.
sigprocmask isn't portable in a multithreaded process.
* configure.ac (gl_THREADLIB): Remove dummy.
Merge from gnulib, incorporating:
2014-05-28 pthread_sigmask, timer-time: use gl_THREADLIB only if needed
* m4/pthread_sigmask.m4, m4/timer_time.m4: Update from gnulib.
* src/Makefile.in (LIB_PTHREAD_SIGMASK): Remove; all uses removed.
Eli Zaretskii [Thu, 29 May 2014 14:52:47 +0000 (17:52 +0300)]
Fix bug #17622 with crashes in mmap routines.
src/buffer.c (init_buffer): Accept an argument 'initialized'.
[USE_MMAP_FOR_BUFFERS]: If 'initialized' is non-zero, reset
mmap_regions and mmap_fd, to avoid referencing stale data from the
dump phase. Add an assertion for buffer text of buffers created
in temacs before this function is called.
(mmap_regions_1, mmap_fd_1): Remove unused variables.
src/lisp.h (init_buffer): Update prototype.
src/emacs.c (main): Pass 'initialized' as the argument to init_buffer.
Paul Eggert [Thu, 29 May 2014 05:31:43 +0000 (22:31 -0700)]
Port the GDB-visible symbols to AIX.
Without them, GDB doesn't work to debug Emacs, since the AIX linker
optimizes away the relevant external symbols. Use enums instead;
this suffices for the AIX port, which is 32-bit-only anyway.
* lisp.h (ENUMABLE, DEFINE_GDB_SYMBOL_ENUM): New macros.
(ARRAY_MARK_FLAG, PSEUDOVECTOR_FLAG, VALMASK): Use them.
(ARRAY_MARK_FLAG_val, PSEUDOVECTOR_FLAG_val, VALMASK_val):
New macros.
Stefan Monnier [Thu, 29 May 2014 03:54:37 +0000 (23:54 -0400)]
* lisp/whitespace.el: Use font-lock-flush. Minimize refontifications.
Side benefit: it works without jit-lock.
(whitespace-point--used): New buffer-local var.
(whitespace-color-on): Initialize it and flush it. Use font-lock-flush.
(whitespace-color-off): Use font-lock-flush.
(whitespace-point--used, whitespace-point--flush-used): New functions.
(whitespace-trailing-regexp, whitespace-empty-at-bob-regexp)
(whitespace-empty-at-eob-regexp): Use them.
(whitespace-post-command-hook): Rewrite.
Dmitry Antipov [Wed, 28 May 2014 08:00:10 +0000 (12:00 +0400)]
On X, always make pointer visible when deleting frame (Bug#17609).
* frame.c (frame_make_pointer_visible, frame_make_pointer_invisible):
Pass frame as arg.
* frame.h (frame_make_pointer_visible, frame_make_pointer_invisible):
Adjust prototypes.
* cmds.c (Fself_insert_command): Use SELECTED_FRAME.
* keyboard.c (gobble_input): If there is no terminal input error,
make sure the pointer is visible for all frames on this terminal.
* xterm.c (x_free_frame_resources): Always enable pointer visibility.