1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-19 10:22:27 +00:00
Commit Graph

1009 Commits

Author SHA1 Message Date
Juanma Barranquero
4d64875a83 nt/config.nt: Sync with autogen/config.in.
(NO_ABORT, SIGNAL_H_AHB): Remove.
2012-09-07 14:15:08 +02:00
Eli Zaretskii
3e6d6928bd MS-Windows followup for 2012-09-07T01:27:44Z!eggert@cs.ucla.edu, signal-handler cleanup.
src/w32proc.c (sigaction): New function, emulates Posix 'sigaction'.
 src/w32.c (sigemptyset): Empty the set.
 (sigsetmask, sigmask, sigblock, sigunblock): Remove unused functions.

 nt/inc/ms-w32.h (struct sigaction): Declare sa_handler __cdecl.

Fixes: debbugs:12327
2012-09-07 11:20:07 +03:00
Juanma Barranquero
5dbaffae0c nt/config.nt: Sync with autogen/config.in. 2012-09-05 02:17:57 +02:00
Paul Eggert
1088b9226e Simplify redefinition of 'abort' (Bug#12316).
Do not try to redefine the 'abort' function.  Instead, redo
the code so that it calls 'emacs_abort' rather than 'abort'.
This removes the need for the NO_ABORT configure-time macro
and makes it easier to change the abort code to do a backtrace.
* configure.ac (NO_ABRT): Remove.
* admin/CPP-DEFINES (NO_ABORT): Remove.
* nt/inc/ms-w32.h (w32_abort) [HAVE_NTGUI]: Remove.
* src/.gdbinit: Just stop at emacs_abort, not at w32_abort or abort.
* src/emacs.c (abort) [!DOS_NT && !NO_ABORT]:
Remove; sysdep.c's emacs_abort now takes its place.
* src/lisp.h (emacs_abort): New decl.  All calls from Emacs code to
'abort' changed to use 'emacs_abort'.
* src/msdos.c (dos_abort) [defined abort]: Remove; not used.
(abort) [!defined abort]: Rename to ...
(emacs_abort): ... new name.
* src/sysdep.c (emacs_abort) [!HAVE_NTGUI]: New function, taking
the place of the old 'abort' in emacs.c.
* src/w32.c, src/w32fns.c (abort): Do not #undef.
* src/w32.c (emacs_abort): Rename from w32_abort.
2012-09-04 10:34:54 -07:00
Juanma Barranquero
137e08a46c nt/config.nt: Sync with autogen/config.in.
(HAVE_EXECINFO_H, TERM_HEADER): New macros.
2012-09-02 04:00:47 +02:00
Daniel Colascione
17a2cbbd76 Refactor window-system configuration
This change streamlines the window system selection code in
configure.in and moves many common function declarations from
window-specific headers to frame.h.  It introduces a new TERM_HEADER
macro in config.h: we set this macro to the right header to use for
the window system for which we're compiling Emacs and have source
files include it indirectly.  This way, we don't have to teach every
file about every window system.
2012-08-31 22:38:52 -08:00
Juanma Barranquero
fe72cdc5b2 nt/config.nt: Sync with autogen/config.in. 2012-08-22 13:30:25 +02:00
Juanma Barranquero
8223e9280f nt/config.nt: Sync with autogen/config.in.
(HAVE_POSIX_OPENPT): New macro.
2012-08-17 12:51:29 +02:00
Chong Yidong
b6928595db Bump version to 24.2.50 2012-08-15 21:26:30 +08:00
Juanma Barranquero
e38b9db247 nt/config.nt: Sync with autogen/config.in.
(_GL_INLINE_HEADER_BEGIN): Update.
2012-08-14 18:15:28 +02:00
Glenn Morris
9374581a24 Move DIRECTORY_SEP from lisp.h to config.h
* configure.ac (DIRECTORY_SEP): Move here from src/lisp.h.

* src/lisp.h (DIRECTORY_SEP): Let configure set it.

* nt/config.nt (DIRECTORY_SEP): Move here from src/lisp.h.

* lib-src/movemail.c (DIRECTORY_SEP, IS_DIRECTORY_SEP):
* lib-src/make-docfile.c (DIRECTORY_SEP, IS_DIRECTORY_SEP):
* lib-src/emacsclient.c (DIRECTORY_SEP, IS_DIRECTORY_SEP, IS_DEVICE_SEP):
Remove (they are in config.h now).
2012-08-09 20:02:10 -04:00
Juanma Barranquero
a8ab93b0f6 * nt/config.nt: Sync with autogen/config.nt.
(BROKEN_GETWD, DISPNEW_NEEDS_STDIO_EXT): New macros.
(PENDING_OUTPUT_COUNT): Move definition to inc/ms-w32.h.

* nt/inc/ms-w32.h (PENDING_OUTPUT_COUNT): Define.
2012-08-07 13:03:48 +02:00
Glenn Morris
1c6f11f42a Remove GNU_LIBRARY_PENDING_OUTPUT_COUNT
* configure.ac (GNU_LIBRARY_PENDING_OUTPUT_COUNT): Remove.
(PENDING_OUTPUT_COUNT): Absorb GNU_LIBRARY_PENDING_OUTPUT_COUNT.
(DISPNEW_NEEDS_STDIO_EXT): New define.

* src/dispnew.c (GNU_LIBRARY_PENDING_OUTPUT_COUNT, PENDING_OUTPUT_COUNT):
Let configure handle it.
(stdio_ext.h) [DISPNEW_NEEDS_STDIO_EXT]: Include it.

* nt/config.nt (GNU_LIBRARY_PENDING_OUTPUT_COUNT): Remove.
(PENDING_OUTPUT_COUNT): Define it as dispnew.c used to.

* admin/CPP-DEFINES (GNU_LIBRARY_PENDING_OUTPUT_COUNT): Remove.
2012-08-06 16:22:22 -04:00
Eli Zaretskii
76151e2ce7 Fix bug #11959 with startup warnings on MS-Windows about ../site-lisp.
src/w32.c (init_environment): Change the default values of many
 environment variables in dflt_envvars[] to NULL, to avoid pushing
 them into environment when they were not already defined.  Remove
 the code that deletes site-lisp subdirectories from the default
 value of EMACSLOADPATH, as it is no longer needed.
 (check_windows_init_file): Now external, not static.  Use
 Vload_path as is, without adding anything, as this function is now
 called when Vload_path is already set up.
 src/w32.h (check_windows_init_file): Add prototype.
 src/emacs.c (init_cmdargs) [WINDOWSNT]: When running from the build
 directory, ignore the /*/i386/ tail in Vinvocation_directory, for
 compatibility with Posix platforms.
 (main): Move the call to check_windows_init_file to here from
 w32.c.
 (decode_env_path) [WINDOWSNT]: Expand the %emacs_dir%/ prefix, if
 any, in the DEFALT argument into the root of the Emacs build or
 installation tree, as appropriate.
 src/callproc.c (init_callproc_1): Call decode_env_path instead of
 doing its equivalent by hand.
 (init_callproc): Replace DOS_NT condition with MSDOS, thus letting
 the code that sets Vexec_path run on MS-Windows.
 src/lread.c (init_lread): Add comments to #ifdef's.

 nt/paths.h (PATH_LOADSEARCH, PATH_SITELOADSEARCH, PATH_EXEC)
 (PATH_DATA, PATH_DOC): Replace dummy directory names with
 directories relative to %emacs_dir%.
 (PATH_EXEC): Add lib-src/oo-spd/i386 and lib-src/oo/i386, to cater
 to the use case of running un-installed Emacs.
2012-08-04 17:17:10 +03:00
Juanma Barranquero
3fbc4b542c * nt/config.nt: Sync with autogen/config.in.
(DOS_NT, MSDOS): New macros.
(WRETCODE, wait3): Remove.

* nt/inc/ms-w32.h (DOS_NT): Remove; defined in config.nt.

* lib-src/makefile.w32-in (LOCAL_FLAGS): Remove WINDOWSNT and DOS_NT,
they are always defined in config.h.
2012-08-03 14:16:40 +02:00
Eli Zaretskii
6dad71783c Support symlinks on latest versions of MS-Windows.
src/w32.c: Include winioctl.h and aclapi.h.
 (is_symlink, chase_symlinks, enable_privilege, restore_privilege)
 (revert_to_self): Forward declarations of static functions.
 <static BOOL g_b_init_get_security_info>:
 <g_b_init_create_symbolic_link>: New static flags.
 (globals_of_w32): Initialize them to zero.
 (GetSecurityInfo_Proc, CreateSymbolicLink_Proc): New typedefs.
 (map_w32_filename): Improve commentary.  Simplify switch.
 (SYMBOLIC_LINK_FLAG_DIRECTORY): Define if not defined in system
 headers (most versions of MinGW w32api don't).
 (get_security_info, create_symbolic_link)
 (get_file_security_desc_by_handle, is_symlink, chase_symlinks):
 New functions.
 (sys_access, sys_chmod): Call 'chase_symlinks' to resolve symlinks
 in the argument file name.
 (sys_access): Call unc_volume_file_attributes only if
 GetFileAttributes fails with network-related error codes.
 (sys_rename): Diagnose renaming of a symlink when the user doesn't
 have the required privileges.
 (get_file_security_desc_by_name): Renamed from
 get_file_security_desc.
 (stat_worker): New function, with most of the guts of 'stat', and
 with addition of handling of symlinks and support for 'lstat'.  If
 possible, get file's attributes and security information by
 handle, not by name.  Produce S_IFLNK bit for symlinks, when
 called from 'lstat'.
 (stat, lstat): New functions, call 'stat_worker'.
 (symlink, readlink, careadlinkat): Rewritten to create and resolve
 symlinks when the underlying filesystem supports them.

 lib/src/ntlib.c (lstat): New function, calls 'stat'.

 nt/inc/sys/stat.h (S_IFLNK): Define.
 (S_ISLNK): A non-trivial definition.
 (lstat): Prototype instead of a macro that redirects to 'stat'.

 lisp/files.el (file-truename): Don't skip symlink-chasing part on
 windows-nt.  Incorporate the resolution of 8+3 short aliases on
 Windows into the loop that recursively chases symlinks.  Compare
 directory and its parent case-insensitively on MS-Windows and
 MS-DOS.

 etc/NEWS: Announce the symlink support on MS-Windows.
2012-08-03 13:23:30 +03:00
Paul Eggert
f162bcc31c Use C99-style 'extern inline' if available.
* lib-src/profile.c (SYSTIME_INLINE): Define.
* nt/config.nt: Sync with autogen/config.in.
(_GL_INLINE, _GL_EXTERN_INLINE, _GL_INLINE_HEADER_BEGIN)
(_GL_INLINE_HEADER_END): New macros.
* src/buffer.h (BUFFER_INLINE):
* src/category.h (CATEGORY_INLINE):
* src/character.h (CHARACTER_INLINE):
* src/charset.h (CHARSET_INLINE):
* src/composite.h (COMPOSITE_INLINE):
* src/dispextern.h (DISPEXTERN_INLINE):
* src/lisp.h (LISP_INLINE):
* src/systime.h (SYSTIME_INLINE):
New macro, replacing 'static inline' in this header.
* src/buffer.h, src/category.h, src/character.h, src/charset.h:
* src/composite.h, src/dispextern.h, lisp.h, systime.h:
Use INLINE_HEADER_BEGIN, INLINE_HEADER_END.
* src/alloc.c (LISP_INLINE):
* src/buffer.c (BUFFER_INLINE):
* src/category.c (CATEGORY_INLINE):
* src/character.c (CHARACTER_INLINE):
* src/charset.c (CHARSET_INLINE):
* src/composite.c (COMPOSITE_INLINE):
* src/dispnew.c (DISPEXTERN_INLINE):
* src/sysdep.c (SYSTIME_INLINE):
Define to EXTERN_INLINE, so that the corresponding functions
are compiled into code.
* src/conf_post.h (INLINE, EXTERN_INLINE, INLINE_HEADER_BEGIN)
(INLINE_HEADER_END): New macros.
* src/lisp.h (PSEUDOVECTOR_FLAG): Now a macro as well as a constant,
since it's used in non-static inline functions now.
2012-08-02 00:31:34 -07:00
Glenn Morris
837b365b2a Move NT-specific include file to the NT include directory
* nt/inc/ms-w32.h: Move here from ../src/s.
* nt/config.nt (config_opsysfile): Change to <ms-w32.h>.

* s/ms-w32.h: Move to ../nt/inc.
* src/makefile.w32-in (TAGS, TAGS-gmake, MS_W32_H):
Update for new ms-w32.h location.

* lib-src/makefile.w32-in (MS_W32_H): Update for new ms-w32.h location.

* lib/makefile.w32-in (MS_W32_H): Update for new ms-w32.h location.

* lisp/emacs-lisp/authors.el (authors-renamed-files-alist): Add ms-w32.h.
2012-08-01 23:19:48 -07:00
Juanma Barranquero
c90acc54da Sync Windows port with autogen/config.in changes.
* nt/config.nt: Sync with autogen/config.in.
(DEVICE_SEP, FLOAT_CHECK_DOMAIN, HAVE_INVERSE_HYPERBOLIC)
(INTERNAL_TERMINAL, IS_ANY_SEP, IS_DEVICE_SEP, IS_DIRECTORY_SEP):
New macros.

* src/s/ms-w32.h (DEVICE_SEP, IS_DIRECTORY_SEP, IS_ANY_SEP):
Remove; moved to nt/config.nt.
2012-08-01 13:20:07 +02:00
Juanma Barranquero
552a99b4cb Adapt Windows port to recent changes in autogen/config.in.
* lib-src/makefile.w32-in (CONFIG_H): Update dependencies.
(CONF_POST_H): New macro.

* lib/makefile.w32-in (CONFIG_H): Update dependencies.
(CONF_POST_H): New macro.

* nt/config.nt: Sync with autogen/config.in.
Remove code moved to conf_post.h and include <conf_post.h>
(NULL_DEVICE, SEPCHAR, SIGNAL_H_AHB, TIOCSIGSEND, USER_FULL_NAME)
(USG5_4, WRETCODE, _longjmp, _setjmp, wait3): New macros.

* src/makefile.w32-in (CONFIG_H): Update dependencies.
(CONF_POST_H): New macro.

* src/s/ms-w32.h (SEPCHAR, NULL_DEVICE): Remove; moved to nt/config.nt.
2012-08-01 02:29:59 +02:00
Juanma Barranquero
1117bd24d1 nt/config.nt: Sync with autogen/config.in.
(HAVE_ENVIRON_DECL): New macro.
2012-07-29 18:56:18 +02:00
Eli Zaretskii
55a6cca64f MS-Windows followup for 2012-07-28T23:05:32Z!eggert@cs.ucla.edu.
nt/inc/stdalign.h (_Alignas, alignas): Define.
 src/makefile.w32-in (LISP_H): Add $(NT_INC)/stdalign.h.

Fixes: debbugs:9772
2012-07-29 18:43:09 +03:00
Paul Eggert
b46a6a83b3 Don't use the abbreviation "win" to refer to Windows (Bug#10421).
* lisp/org/ob-lilypond.el (ly-w32-ly-path): Rename from ly-win32-ly-path.
(ly-w32-pdf-path): Rename from ly-win32-pdf-path.
(ly-w32-midi-path): Rename from ly-win32-midi-path.
(ly-determine-ly-path, ly-determine-pdf-path, ly-determine-midi-path):
Check for "windows-nt", not "win32", in system-type.
* src/regex.c (MAX_BUF_SIZE): Remove some incorrect and
long-ago-commented-out code that talks about "WIN32".
* src/w32heap.h (OS_WINDOWS_95): Rename from OS_WIN95.
All uses changed.
2012-07-29 01:18:29 -07:00
Paul Eggert
e32a579975 Use Gnulib stdalign and environ modules (Bug#9772, Bug#9960).
* .bzrignore: Add lib/stdalign.h.
* config.bat: Do not set NO_DECL_ALIGN; no longer needed.
Copy lib/stdalign.in.h to lib/stdalign.in-h as needed.
* configure.ac (HAVE_ATTRIBUTE_ALIGNED): Remove the code that
fiddles with this, as gnulib now does this for us.
* admin/merge-gnulib: Add environ, stdalign.
* m4/environ.m4: New file, from gnulib.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
* lib/stdalign.in.h, m4/stdalign.m4: New files, from gnulib.
* sed2v2.inp (HAVE_ATTRIBUTE_ALIGNED): Remove edit.
* sedlibmk.inp (STDALIGN_H, @GL_GENERATE_STDALIGN_H_TRUE@)
(GL_GENERATE_STDALIGN_H_FALSE): New edits.
* nt/config.nt (HAVE_ATTRIBUTE_ALIGNED): Remove.
* src/alloc.c (XMALLOC_BASE_ALIGNMENT, GC_POINTER_ALIGNMENT, pure_alloc):
Simplify by using alignof.
(pure_alloc) [! USE_LSB_TAG]: Don't over-align EMACS_INT values.
* src/lisp.h: Include <stdalign.h>.
(GCALIGNMENT): New macro and constant.
(DECL_ALIGN): Remove.  All uses replaced by alignas (GCALIGNMENT).
(USE_LSB_TAG): ifdef on alignas, not on DECL_ALIGN.
(stdalign): New macro, if not already defined.
2012-07-28 16:05:32 -07:00
Juanma Barranquero
22e983b7ec * nt/config.nt: Sync with autogen/config.in.
(GC_MARK_SECONDARY_STACK, GC_MARK_STACK, GC_SETJMP_WORKS)
(SETUP_SLAVE_PTY): New macros.

* src/s/ms-w32.h (GC_SETJMP_WORKS, GC_MARK_STACK): Set in nt/config.nt.
2012-07-14 04:26:31 +02:00
Juanma Barranquero
ed9265fc7d Fix typos in ChangeLogs. 2012-07-14 04:08:32 +02:00
Juanma Barranquero
ef099b57b6 * nt/config.nt: Sync with autogen/config.in.
(BROKEN_FIONREAD, BROKEN_GET_CURRENT_DIR_NAME)
(BROKEN_PTY_READ_AFTER_EAGAIN, BROKEN_SIGAIO, BROKEN_SIGPOLL)
(BROKEN_SIGPTY, BSD4_2, BSD_SYSTEM, BSD_SYSTEM_AHB, CYGWIN, DARWIN_OS)
(FIRST_PTY_LETTER, GNU_LINUX, G_SLICE_ALWAYS_MALLOC, HAVE_PTYS)
(HAVE_SOCKETS, HPUX, INTERRUPT_INPUT, IRIX6_5, NARROWPROTO, NO_ABORT)
(NO_EDITRES, NSIG_MINIMUM, PREFER_VSUSP, PTY_ITERATION
(PTY_NAME_SPRINTF, PTY_OPEN, PTY_TTY_NAME_SPRINTF, RUN_TIME_REMAP)
(SETPGRP_RELEASES_CTTY, SOLARIS2, TAB3, TABDLY, ULIMIT_BREAK_VALUE)
(UNIX98_PTYS, USG, USG5, XOS_NEEDS_TIME_H, _AIX): New macros.
(HAVE_ATTRIBUTE_ALIGNED, HAVE_C99_STRTOLD, HAVE___BUILTIN_UNWIND_INIT):
Set in src/s/ms-w32.h, not here.

* src/s/ms-w32.h (FIRST_PTY_LETTER, HAVE_SOCKETS): Move to nt/config.nt.
(HAVE_ATTRIBUTE_ALIGNED, HAVE_C99_STRTOLD, HAVE___BUILTIN_UNWIND_INIT):
Set here, not in nt/config.nt.
2012-07-13 13:49:26 +02:00
Juanma Barranquero
116f7b5477 nt/config.nt: Sync with autogen/config.in.
(CLASH_DETECTION, DEFAULT_SOUND_DEVICE, DONT_REOPEN_PTY)
(GNU_LIBRARY_PENDING_OUTPUT_COUNT, SIGNALS_VIA_CHARACTERS): New macros.
(HAVE_MKDIR, HAVE_RENAME, HAVE_RMDIR, HAVE_STRERROR): Remove.
2012-07-11 13:44:31 +02:00
Juanma Barranquero
dfa96edd13 nt/config.nt: Sync with autogen/config.in. 2012-07-10 13:46:31 +02:00
Paul Eggert
5994c1836b Add GCC-style 'const' attribute to functions that can use it. 2012-07-09 09:38:45 -07:00
Juanma Barranquero
5eabd6f001 nt/config.nt: Sync with autogen/config.in. 2012-07-09 15:40:34 +02:00
Juanma Barranquero
9d6fa7c706 nt/config.nt (BROKEN_SA_RESTART): Fix comment. 2012-07-08 16:58:24 +02:00
Juanma Barranquero
090bd7cb34 Fix ChangeLog typos. 2012-07-08 01:16:19 +02:00
Juanma Barranquero
dffdc540e2 nt/config.nt (HAVE_STRCASECMP, HAVE_STRNCASECMP): Remove. 2012-07-07 22:26:48 +02:00
Juanma Barranquero
f247498ead * nt/config.nt: Complete rework to bring it in sync with autogen/config.in.
All Windows-specific code moved to src/s/ms-w32.h.

* src/s/ms-w32.h: Settings not specific to Windows moved to nt/config.nt.
Windows-specific code from nt/config.nt moved here.
Obsolete settings removed.
2012-07-06 19:19:33 +02:00
Juanma Barranquero
0566bc9540 * nt/configure.bat (enablechecking): Enable checks through src/config.h.
* nt/gmake.defs (DEBUG_CFLAGS): Add -fno-crossjumping.
(CHECKING_CFLAGS): Remove.
(CFLAGS, ESC_CFLAGS): Do not include $(CHECKING_CFLAGS).

* nt/nmake.defs (CHECKING_CFLAGS): Remove.
(CFLAGS, ESC_CFLAGS): Do not include $(CHECKING_CFLAGS).
2012-07-04 19:17:19 +02:00
Juanma Barranquero
95f61aa29a Remove obsolete configuration options (Windows port).
* admin/CPP-DEFINES (LISP_FLOAT_TYPE): Remove, obsolete.

* nt/config.nt (LISP_FLOAT_TYPE, HAVE_XFREE386, USE_TEXT_PROPERTIES)
(GSSAPI, HAVE_LIBINTL, HAVE_LIBGSSAPI_KRB5, HAVE_LIBGSSAPI)
(HAVE_GSSAPI_H, HAVE_LIBXBD, HAVE_MEMCPY, HAVE_MEMMOVE, HAVE_MEMSET)
(HAVE_MEMCMP): Remove, obsolete.

* src/s/ms-w32.h (LISP_FLOAT_TYPE, HAVE_MEMCMP, HAVE_MEMCPY)
(HAVE_MEMMOVE, HAVE_MEMSET): Don't set, obsolete.
2012-07-04 18:46:42 +02:00
Glenn Morris
ca26824cb0 Make --no-site-lisp work for --enable-locallisppath elements
without "site-lisp" in the name.
Ref http://debbugs.gnu.org/10208#25, point iii).

* configure.in (standardlisppath): New output variable.
(lisppath): Use standardlisppath.
* Makefile.in (standardlisppath): New, set by configure.
(epaths-force): Use standardlisppath and locallisppath rather than lisppath.

* src/epaths.in (PATH_SITELOADSEARCH): New.
* src/lread.c (init_lread): Use PATH_SITELOADSEARCH.

* nt/paths.h (PATH_SITELOADSEARCH): New.

Fixes: debbugs:11658
2012-06-30 14:10:50 -07:00
Juanma Barranquero
0e711109c1 nt/nmake.defs,gmake.defs (CHECKING_FLAGS): Remove XASSERTS. 2012-06-28 11:06:11 +02:00
Eli Zaretskii
5e0881ddc4 nt/config.nt (_Noreturn): Don't reference __SUNPRO_C.
Fixes: debbugs:11750
2012-06-24 21:31:31 +03:00
Paul Eggert
845ca89390 Switch from NO_RETURN to C11's _Noreturn.
Fixes: debbugs:11750
2012-06-24 10:39:14 -07:00
Eli Zaretskii
696056c280 Improve port of struct timespec to MS-Windows.
lib/makefile.w32-in ($(BLD)/dtotimespec.$(O)):
 ($(BLD)/timespec-add.$(O)):
 ($(BLD)/timespec-sub.$(O)): Don't depend on
 $(EMACS_ROOT)/nt/inc/sys/time.h.
 lib/stat-time.h:
 lib/timespec.h:
 lib/utimens.h: Revert last change.
 src/makefile.w32-in (TIMESPEC_H): Remove nt/inc/sys/time.h.
 (SYSTIME_H): Add nt/inc/sys/time.h.
 src/systime.h [WINDOWSNT]: Include sys/time.h.
 src/s/ms-w32.h (struct timespec): Definition moved from
 nt/inc/sys/time.h.  Suggested by Paul Eggert <eggert@cs.ucla.edu>.
 nt/inc/sys/time.h (struct timespec): Don't define it here, it is
 now defined in src/s/ms-w32.h.

Fixes: debbugs:9000
2012-06-24 20:21:20 +03:00
Eli Zaretskii
388cdec072 Fix the MS-Windows build broken by 2012-06-22T21:17:42Z!eggert@cs.ucla.edu.
nt/inc/sys/time.h (struct timespec): Define.
 lib/makefile.w32-in (GNULIBOBJS): Add $(BLD)/dtotimespec.$(O),
 $(BLD)/gettime.$(O), $(BLD)/timespec-add.$(O), and
 $(BLD)/timespec-sub.$(O).
 ($(BLD)/dtotimespec.$(O)):
 ($(BLD)/gettime.$(O)):
 ($(BLD)/timespec-add.$(O)):
 ($(BLD)/timespec-sub.$(O)): New dependencies.
 lib/stat-time.h:
 lib/timespec.h:
 lib/utimens.h: Include sys/time.h
 src/w32.c (fdutimens): New function.
 src/w32proc.c (sys_select): Adapt to change in the EMACS_TIME type.
 src/s/ms-w32.h (pselect): Redirect to sys_select.
 src/sysselect.h [WINDOWSNT]: Don't include sys/select.h.

Fixes: debbugs:9000
2012-06-23 13:22:59 +03:00
Eli Zaretskii
6eb93f60be Fix "make dist" on MS-Windows.
nt/makefile.w32-in (install-addpm): New target.
 (dist): Depend on it.
 (install-shortcuts): Depend on install-addpm instead of copying
 addpm.exe as part of the recipe.  See
 http://lists.gnu.org/archive/html/emacs-devel/2012-06/msg00171.html
 for the related problem and discussions.
2012-06-16 16:17:14 +03:00
Glenn Morris
a9be7d2b19 Move SYSTEM_TYPE from src/s to configure
* configure.in (SYSTEM_TYPE): New AC_DEFINE.

* msdos/sed2v2.inp (SYSTEM_TYPE): Set it.

* nt/config.nt (SYSTEM_TYPE): Define it.

* src/s/aix4-2.h, src/s/bsd-common.h, src/s/cygwin.h, src/s/darwin.h:
* src/s/gnu-kfreebsd.h, src/s/gnu-linux.h, src/s/gnu.h, src/s/hpux10-20.h:
* src/s/irix6-5.h, src/s/ms-w32.h, src/s/msdos.h, src/s/template.h:
* src/s/usg5-4-common.h: Remove SYSTEM_TYPE.
2012-06-11 19:17:11 -04:00
Chong Yidong
efc00ab16e Merge from emacs-24; up to 2012-04-24T21:47:24Z!michael.albinus@gmx.de 2012-05-31 14:08:06 +08:00
Eli Zaretskii
0652336413 Fix bug #11405 with MSVC build of emacsclientw.
lib-src/makefile.w32-in ($(BLD)/emacsclientw.exe): Use $(MWINDOWS)
 instead of a literal -mwindows, which is not supported by MSVC.
 nt/nmake.defs (MWINDOWS): Define as "-subsystem:windows -entry:mainCRTStartup".
 Suggested by Fabrice Popineau <fabrice.popineau@supelec.fr>.
 nt/gmake.defs (MWINDOWS): Define as "-mwindows".
2012-05-29 19:15:12 +03:00
Eli Zaretskii
c00ea352d8 Remove HAVE_SYSINFO from nt/config.nt, followup to 2012-05-28T00:46:33Z!eggert@cs.ucla.edu.
nt/config.nt (HAVE_SYSINFO): Remove; unused.
2012-05-28 20:00:18 +03:00
Eli Zaretskii
e383e32d7a Fix subtle problem with redirection in nt/configure.bat.
nt/configure.bat (genmakefiles): Move the redirection away from the
 end of the command, to avoid excess whitespace at the end of Make
 variables created at configure time, and also avoid things like
 "FOO1>>config.settings", where "1" gets interpreted as the file
 descriptor and eaten up.  This fixes breakage introduced by the
 last change, without reintroducing the bug fixed by that change.
2012-05-28 19:17:35 +03:00
Eli Zaretskii
cd37650917 Fix the MS-Windows build broken by 1995-02-25T20:57:45Z!rms@gnu.org.
lib/makefile.w32-in ($(BLD)/md5.$(O)): 
 ($(BLD)/sha1.$(O)): 
 ($(BLD)/sha256.$(O)): 
 ($(BLD)/sha512.$(O)): Depend on $(EMACS_ROOT)/nt/inc/stdalign.h.
 Suggested by Christoph Scholtes <cschol2112@googlemail.com>.
 lib/getopt_.h: Regenerate.
 nt/inc/stdalign.h: New file.

Fixes: debbugs:11527
2012-05-27 15:11:23 +03:00
Glenn Morris
33017fafd1 Merge from emacs-24; up to 2012-04-24T08:35:02Z!lekktu@gmail.com 2012-05-26 18:06:44 -07:00
Paul Eggert
3437465030 Remove src/m/*.
* configure.in: Remove all mention of src/m/*.
(machine, machfile, M_FILE, config_machfile, and_machfile): Remove.
All uses removed.
(BITS_PER_CHAR, BITS_PER_SHORT, BITS_PER_INT, BITS_PER_LONG)
(BITS_PER_LONG_LONG): Move to src/lisp.h.
* lib/makefile.w32-in: Remove dependencies on
$(EMACS_ROOT)/src/m/intel386.h.
* make-dist: Don't make links to src/m.
* admin/CPP-DEFINES: Do not mention src/m/*.h.
(BITS_PER_EMACS_INT, BITS_PER_LONG, BITS_PER_CHAR)
(BITS_PER_SHORT, BITS_PER_INT): Remove.
* admin/MAINTAINERS: Remove src/m/.
* lib-src/makefile.w32-in: Remove dependencies on
$(EMACS_ROOT)/src/m/intel386.h.
* msdos/mainmake.v2 (TAGS tags): Don't look at $(CURDIR)/src/m/intel386.h.
* nt/config.nt: Do not include "m/intel386.h"; file was removed.
(BITS_PER_CHAR, BITS_PER_SHORT, BITS_PER_INT, BITS_PER_LONG):
Move to src/lisp.h.
(EMACS_INT_MAX): New macro.
This directory predates autoconf and is no longer needed nowadays.
Move its few remaining bits of functionality to where they're needed.
* src/m/README, src/m/alpha.h, src/m/amdx86-64.h, src/m/ia64.h, src/m/ibmrs6000.h:
* src/m/ibms390x.h, src/m/intel386.h, src/m/m68k.h, src/m/macppc.h:
* src/m/sparc.h, src/m/template.h: Remove.
* src/Makefile.in (M_FILE): Remove.  All uses removed.
* src/alloc.c (POINTERS_MIGHT_HIDE_IN_OBJECTS):
* src/lisp.h (USE_LSB_TAG):
* src/mem-limits.h (EXCEEDS_LISP_PTR):
Use VAL_MAX, not VALBITS, in #if.
* src/lisp.h (EMACS_INT_MAX): New macro, useful in #if.
(EMACS_UINT): Define unconditionally now.
(BITS_PER_CHAR, BITS_PER_SHORT, BITS_PER_INT, BITS_PER_LONG)
(BITS_PER_EMACS_INT): New constants, replacing
what used to be in config.h, but not useful in #if.
(GCTYPEBITS, VALBITS): Define unconditionally, since m/* files don't
define them any more.
(VAL_MAX): New macro.
(VALMASK): Use it.
* src/puresize.h (PURESIZE_RATIO): Use EMACS_INT_MAX, not
BITS_PER_EMACS_INT, in #if.
* src/s/aix4-2.h (BROKEN_FIONREAD, BROKEN_SIGAIO, BROKEN_SIGPTY)
(BROKEN_SIGPOLL): Move here from m/ibmrs6000.h, which was removed.
* src/s/gnu-linux.h (ULIMIT_BREAK_VALUE) [__i386__]:
* src/s/ms-w32.h (DATA_START):
Move here from removed file m/intel386.h.
* src/s/gnu.h (NLIST_STRUCT): Remove undef; 'configure' does this.
* src/s/irix6-5.h (_LP64): Remove; lisp.h no longer needs this.
2012-05-22 09:20:27 -07:00
Paul Eggert
9232a6d9a7 Remove unused HAVE_* symbols for functions.
* configure.in (AC_CHECK_FUNCS): Remove XSetWMProtocols,
getdomainname, mblen (twice), mbrlen (twice), mbsinit, ualarm,
getsockopt, setsockopt, mremap, mempcpy.
* admin/CPP-DEFINES (HAVE_GETDOMAINNAME): Remove.
* msdos/sed2v2.inp (HAVE_MBLEN): Remove.
* msdos/sed2x.inp (HAVE_XSETWMPROTOCOLS): Remove.
* nt/config.nt (HAVE_GETDOMAINNAME, HAVE_XSETWMPROTOCOLS)
(HAVE_GETSOCKOPT, HAVE_SETSOCKOPT): Remove; not needed.
* src/s/ms-w32.h (HAVE_GETDOMAINNAME): Remove; not needed.
2012-05-19 11:04:49 -07:00
Paul Eggert
003fdae201 Remove no-longer-used macro HAVE_FTIME.
* configure.in (machine): Do not set to 'vax', since src/m/vax.h
is being removed.
(AC_CHECK_FUNCS): Remove ftime.
* admin/CPP-DEFINES (HAVE_FTIME): Remove.
* nt/config.nt (HAVE_FTIME): Remove undef; not needed.
* src/m/vax.h: Remove; no longer needed since HAVE_FTIME is being removed.
* src/s/ms-w32.h (HAVE_FTIME): Remove; not needed.
2012-05-19 01:49:08 -07:00
Eli Zaretskii
ce12872275 Fix redirection in nt/configure.bat.
nt/configure.bat: Ensure a space between %var% expansion and
 redirection symbol '>', which breaks when %var% ends in a digit,
 such as 1.
2012-05-18 11:21:19 +03:00
Chong Yidong
ee812c5f16 Bump version to 24.0.97.
Regenerate ldefs-boot.el and AUTHORS.
2012-05-17 10:36:40 +08:00
Glenn Morris
9311dcff1d Remove HAVE_LIBNCURSES; it is required to be true
Also, it was a confusing name, since it does not necessarily mean that
we literally have libncurses; rather that we have tputs etc.

* configure.in (HAVE_LIBNCURSES): Remove; it is required to be true.

* src/dispnew.c: Remove HAVE_LIBNCURSES test;
it is always true on relevant platforms.

* nt/config.nt (HAVE_LIBNCURSES): Remove undef; not needed.
2012-04-30 20:30:11 -04:00
Chong Yidong
9723e05aa3 Bump version to 24.0.96.
Regenerate AUTHORS and ldefs-boot.el.
2012-04-28 00:33:57 +08:00
Juanma Barranquero
75f1671a52 Fix ChangeLog typos. 2012-04-15 04:59:30 +02:00
Glenn Morris
35dc09a19c Merge from emacs-24, up to 2012-04-10T02:06:19Z!larsi@gnus.org 2012-04-13 18:46:06 -07:00
Dani Moncayo
e645df7cc3 * nt/makefile.w32-in: Fix typo (Bug#10261). 2012-04-11 14:33:51 +08:00
Eli Zaretskii
7dd02dc7c4 Better parallelism on MS-Windows for "make info".
nt/makefile.w32-in (emacs, misc, lispref, lispintro): New targets,
 each runs makeinfo in its own subdirectory of 'doc'.
 (info-gmake): Depend on these new targets.
2012-04-10 22:03:32 +03:00
Glenn Morris
f3774f20c3 Bump trunk version to 24.1.50.
* README, configure.in (AC_INIT): Bump version to 24.1.50.

* doc/emacs/emacsver.texi (EMACSVER): Bump version to 24.1.50.

* doc/man/emacs.1: Bump version to 24.1.50.

* msdos/sed2v2.inp: Bump version to 24.1.50.

* nextstep/Cocoa/Emacs.base/Contents/Info.plist:
* nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:
* nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:
* nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:
Bump version to 24.1.50.

* nt/config.nt, nt/makefile.w32-in, nt/emacs.rc, nt/emacsclient.rc:
Bump version to 24.1.50.
2012-04-07 13:00:16 -07:00
Eli Zaretskii
9078ead6ce Support building on MS-Windows with libxml2.
src/makefile.w32-in (OBJ2): Add xml.$(O).
 (GLOBAL_SOURCES): Add xml.c.
 ($(BLD)/xml.$(O)): New dependency list.
 src/xml.c (DEF_XML2_FN, LOAD_XML2_FN) [WINDOWSNT]: New macros.
 (fn_htmlReadMemory, fn_xmlReadMemory, fn_xmlDocGetRootElement)
 (fn_xmlFreeDoc, fn_xmlCleanupParser, fn_xmlCheckVersion)
 [!WINDOWSNT]: New macros.
 (init_libxml2_functions, libxml2_loaded_p): New functions.
 (parse_region): Call fn_xmlCheckVersion instead of using the macro
 LIBXML_TEST_VERSION.  Call libxml2 functions via the fn_* macros.
 (xml_cleanup_parser): New function, export for fn_xmlCleanupParser.
 Calls xmlCleanupParser only if libxml2 was loaded (or statically
 linked in).
 (Flibxml_parse_html_region, Flibxml_parse_xml_region): Call
 init_libxml2_functions before calling libxml2 functions.
 (syms_of_xml) <Qlibxml2_dll>: DEFSYM it.
 src/emacs.c: Don't include libxml/parser.h.
 (shut_down_emacs): Call xml_cleanup_parser, instead of calling
 xmlCleanupParser directly.
 src/ lisp.h [HAVE_LIBXML2]: Add prototype for xml_cleanup_parser.

 nt/configure.bat: Support building with libxml2.
 nt/INSTALL:
 nt/README.W32: Add information about libxml2.

 lisp/term/w32-win.el (dynamic-library-alist): Add libxml2 DLLs.

 lib-src/makefile.w32-in (obj): Add xml.o.
2012-04-07 16:57:36 +03:00
Eli Zaretskii
d67a9a85f5 Fix parallel build and bootstrap on MS-Windows.
nt/makefile.w32-in: (all): Don't depend on stamp_BLD and on maybe-bootstrap.
 (all-other-dirs-$(MAKETYPE)): Depend on maybe-bootstrap.
 (bootstrap-gmake): Invoke the "clean" and build targets in 2
 separate commands, so they run in that order even under "make -j".
 lib/makefile.w32-in (gnulib, all): Don't depend on stamp_BLD.
 lib-src/makefile.w32-in (ALL): Now the list of executables, not of phony
 targets.
 (.PHONY): Only make-docfile is its prerequisite now.
 (make-docfile): Don't depend on stamp_BLD.  Add a comment about
 the need in this target.
 (ctags, etags, ebrowse, hexl, movemail, emacsclient)
 (test-distrib): Phony targets removed.
 ($(BLD)/test-distrib.exe): Run test-distrib as part of the recipe.
 (all): Don't depend on stamp_BLD.
2012-04-07 13:19:22 +03:00
Eli Zaretskii
1dcece2598 Convert nt/makefile.w32-in to Unix EOL format. 2012-04-07 11:26:32 +03:00
Chong Yidong
319bc402c8 Bump version to 24.0.95.
Regenerate AUTHORS and ldefs-boot.el.
2012-04-02 12:38:31 +08:00
Eli Zaretskii
581355cc06 Discourage in comments from defining HAVE_GETCWD on MS-Windows.
src/s/ms-w32.h: Discourage from defining HAVE_GETCWD.
 nt/config.nt: Discourage from defining HAVE_GETCWD.
2012-03-29 22:06:39 +02:00
Eli Zaretskii
e5a69fd00a Fix parallel "make install" on MS-Windows.
nt/makefile.w32-in (install-bin): Don't copy addpm.exe here.  Use
 $(DIRNAME)_same-dir.tst instead of same-dir.tst, to avoid stepping
 on other (parallel) Make job's toes.
 (install-other-dirs-nmake, install-other-dirs-gmake): Depend on `all'.
 (install-shortcuts): Depend on $(INSTALL_DIR)/bin.  Copy addpm.exe
 here.
 (maybe-copy-distfiles-CMD, maybe-copy-distfiles-SH, dist): Depend
 on create-tmp-dist-dir.
 nt/nmake.defs (DIRNAME): New variable.
 (IFNOTSAMEDIR): Use $(DIRNAME)_same-dir.tst instead of
 same-dir.tst.
 nt/gmake.defs (DIRNAME): New variable.
 (IFNOTSAMEDIR): Use $(DIRNAME)_same-dir.tst instead of
 same-dir.tst, to avoid conflicts between several (parallel) Make
 jobs.
 lisp/makefile.w32-in (install): Use $(DIRNAME)_same-dir.tst instead
 of same-dir.tst, to avoid stepping on other (parallel) Make job's
 toes.
 leim/makefile.w32-in (install): Use $(DIRNAME)_same-dir.tst instead
 of same-dir.tst, to avoid stepping on other (parallel) Make job's
 toes.
2012-03-25 20:17:46 +02:00
Chong Yidong
9c62cd0479 Bump version to 24.0.94 2012-02-27 11:20:00 +08:00
Eli Zaretskii
58b65bf58c Fix bug #10674 with infinite re-spawning of cmdproxy.exe.
nt/cmdproxy.c (main): Bypass conversion of the file name in argv[0]
 and our own module name to short 8+3 aliases, if the original file
 names compare equal.  If GetShortPathName fails, compare the base
 names of the two file names, and only re-spawn the command line if
 the base-name comparison also fails.
2012-02-24 12:13:20 +02:00
Dani Moncayo
2dbe4d7106 * nt/makefile.w32-in (maybe-copy-distfiles-SH): Fix typo. 2012-02-23 02:52:08 -05:00
Christoph Scholtes
42a275e05e * nt/README.W32: Removed specific version information for libXpm
included in the binary distribution for maintenance purposes.
2012-02-05 21:07:40 -07:00
Christoph Scholtes
533183f36a Added missing bug numbers to Changelog entries. 2012-02-05 15:51:11 -07:00
Christoph Scholtes
3e44c7824f * make-dist (README.W32): Include file in source tarball.
* nt/README.W32: Clarification for inclusion in source tarball.
2012-02-05 13:56:41 -07:00
Christoph Scholtes
7519763363 * lib/makefile.w32-in (PRAGMA_SYSTEM_HEADER): Move to platform
specific makefiles to support getopt_.h generation with MSVC.

* nt/gmake.defs (PRAGMA_SYSTEM_HEADER): Add for GCC.

* nt/nmake.defs (PRAGMA_SYSTEM_HEADER): Add, but ignore with MSVC.
2012-02-05 13:40:36 -07:00
Christoph Scholtes
d452256dd8 * nt/makefile.w32-in (maybe-copy-distfiles)
(maybe-copy-distfiles-CMD, maybe-copy-distfiles-SH)
(create-tmp-dist-dir): Added to make --distfiles optional.
(dist): Use create-tmp-dist-dir and maybe-copy-distfiles.
2012-02-05 13:14:54 -07:00
Glenn Morris
a0d363f477 * nt/INSTALL: Mention --lib, --enable-checking.
* etc/NEWS: Markup for things in nt/INSTALL (no need for these things
to be in the manuals proper).
2012-02-04 13:34:36 -08:00
Eli Zaretskii
e0aeebda1f Avoid MS-Windows compilation errors when struct stat is redefined.
nt/inc/sys/stat.h (_STAT_DEFINED): Define, to prevent redefinitions
 by other headers.
2012-02-04 15:24:07 +02:00
Juanma Barranquero
6df6ae42fe Fix typos in ChangeLogs. 2012-01-31 17:15:03 +01:00
Eli Zaretskii
7a43121e52 nt/INSTALL: Update instructions for parallel builds. 2012-01-30 20:37:01 +02:00
Chong Yidong
d7fac6deb0 Bump version to 24.0.93.
Regenerate AUTHORS and ldefs-boot.el.
2012-01-29 23:46:05 +08:00
Eli Zaretskii
8dc96b40e0 nt/README.W32, nt/INSTALL: Update the URL for GnuTLS binaries. 2012-01-26 23:37:32 +02:00
Glenn Morris
acaf905b11 Add 2012 to FSF copyright years for Emacs files 2012-01-05 01:46:05 -08:00
Paul Eggert
c80e3b4aed Spelling fixes. 2011-12-04 00:02:42 -08:00
Chong Yidong
6db4e2d308 Bump version to 24.0.92.
Regenerate AUTHORS and ldefs-boot.el.
2011-12-01 00:23:05 +08:00
Eli Zaretskii
8c9afb4694 Fix MS-Windows build with MSVC compiler.
Parts of the changes by Fabrice Popineau  <fabrice.popineau@supelec.fr>.

 lib-src/makefile.w32-in (LOCAL_FLAGS): Add $(EMACS_EXTRA_C_FLAGS).
 lib-src/emacsclient.c (main) <environ>: Remove declaration, already
 pulled in by unistd.h on Posix hosts and stdlib.h on MS-Windows.
 nt/inc/stdint.h (uint32_t, uint64_t) [_WIN64]: New typedefs.
 (UINT64_MAX) [_WIN64]: Fix definition.
 (uintmax_t, intmax_t): Fix definitions.
 nt/inc/inttypes.h (strtoumax, strtoimax) [!__MINGW32__]: Provide
 correct definitions.
 nt/config.nt (HAVE_DECL_STRTOLL): Define.
 (va_copy) [_WIN64]: Provide a better definition.
 src/s/ms-w32.h (utimbuf) [_MSC_VER]: Don't define.
 (snprintf) [_MSC_VER]: Redirect to _snprintf.
 (strtoll) [_MSC_VER]: Redirect to _strtoi64.
 (malloc, free, realloc, calloc): Redirect to e_* only when
 compiling Emacs.
 src/lisp.h (GCTYPEBITS): Move before first use.
 (ALIGN_GCTYPEBITS) [_MSC_VER]: Define.
 (DECL_ALIGN) [_MSC_VER]: Use it, as MSVC doesn't like bit ops in
 this macro definition.
 (tzname): Redirect to _tzname for all values of _MSC_VER.

Fixes: debbugs:9960
2011-11-27 20:52:53 +02:00
Paul Eggert
b0b199744d Spelling fixes. 2011-11-26 00:26:37 -08:00
Juanma Barranquero
e9fce1acd8 Fix typos. 2011-11-25 14:26:30 +01:00
Eli Zaretskii
034ea24ddb nt/INSTALL: Elaborate on debugging fatal errors. 2011-11-25 14:17:33 +02:00
Paul Eggert
e1dbe924b5 Spelling fixes. 2011-11-19 18:29:42 -08:00
Paul Eggert
5396468298 Spelling fixes. 2011-11-19 01:18:31 -08:00
Paul Eggert
3ed8598c49 Spelling fixes. 2011-11-18 00:31:02 -08:00
Paul Eggert
c5e87d104b Spelling fixes. 2011-11-17 09:40:48 -08:00
Juanma Barranquero
58179ccebd Fix typos. 2011-11-16 13:34:47 +01:00
Eli Zaretskii
b018182ccd Update information about PNG libraries for MS-Windows.
admin/nt/README-ftp-server: Update the information about PNG libraries.
 nt/README.W32: Update the GTK Windows download URL for libpng.
2011-11-15 20:08:38 +02:00
Juanma Barranquero
c701515351 Fix typos. 2011-11-15 18:37:37 +01:00
Christoph Scholtes
d7cecd19b3 * inc/stdint.h (UINT64_MAX, UINT32_MAX): Fix values. 2011-11-13 07:43:13 -07:00
Juanma Barranquero
40a8bdf60f Fix typos. 2011-11-12 00:17:16 +01:00
Christoph Scholtes
c4c32b976a * inc/stdint.h (UINT64_MAX, UINT64_MIN, INT64_MIN, UINTMAX_MAX)
(UINTMAX_MIN, INTMAX_MAX, INTMAX_MIN, UINT32_MIN, UINT32_MAX)
(INT32_MIN, UINTMAX_MAX, UINTMAX_MIN, INTMAX_MAX, INTMAX_MIN)
(intmax_t, INT64_MAX): Add for MSVC.
2011-11-05 16:33:44 -06:00
Christoph Scholtes
1e8110e753 Fix definition of `mode_t'. 2011-11-05 11:16:01 -06:00
Christoph Scholtes
600b1907da * nt/config.nt: (mode_t) [!__GNUC__]: Define mode_t for MSVC. 2011-11-05 08:59:51 -06:00
Eli Zaretskii
955f3b13c6 Fix compilation with MSVC in lib/.
nt/config.nt (inline) [!__GNUC__]: Define to __inline for MSVC.
2011-11-05 16:10:27 +02:00
Eli Zaretskii
a6fc3b5c53 Support MSVC build with newer versions of Visual Studio.
Small portions of the changes by Fabrice Popineau <fabrice.popineau@supelec.fr>.

 src/makefile.w32-in (TAGS-gmake): Don't use $(patsubst ...), as
 Nmake barfs on that.  Use $(OBJ*_c) variables instead, defined on
 nt/gmake.defs.
 src/lisp.h (ENUM_BF): New macro, for enumerated types in bitfields,
 which are not supported by MSVC.
 (Lisp_Symbol, Lisp_Misc_Any, Lisp_Marker, Lisp_Misc_Overlay)
 (Lisp_Save_Value, Lisp_Free): Use ENUM_BF for enumerated types in
 bitfields.
 (Lisp_Object) [USE_LISP_UNION_TYPE]: Use ENUM_BF for enumerated
 types in bitfields.
 (DEFUN) [_MSC_VER]: Define in a different way for MSVC.
 src/w32fns.c [_MSC_VER]: DECLARE_HANDLE for any MSVC version.
 src/w32.c: Don't include w32api.h for MSVC.
 (init_environment) [_MSC_VER]: Call sys_access, not _access.
 src/s/ms-w32.h <sigset_t, ssize_t> [_MSC_VER]: Typedefs for MSVC.
 [_MSC_VER]: Include sys/timeb.h, sys/stat.h, and signal.h.
 (fstat, stat, utime) [_MSC_VER]: Redirect to their sys_* cousins.
 (malloc, free, realloc, calloc) [_MSC_VER]: Always redirect to the
 e_* cousins.
 (alloca) [_MSC_VER]: Define to _alloca.
 src/lisp.h (DECL_ALIGN) [_MSC_VER]: Define for MSVC.
 src/regex.c <re_char> [_MSC_VER]: A separate definition for MSVC.
 nt/makefile.w32-in (clean-other-dirs-nmake)
 (distclean-other-dirs-nmake, maintainer-clean-other-dirs-nmake):
 Update for current structure of doc/ subdirectories.
 nt/gmake.defs (OBJ0_c, OBJ1_c, OBJ2_c): New variables.
 nt/INSTALL: Update for newer versions of MSVC.
 lib/makefile.w32-in (FRC): New dummy target.
 (TAGS): Depend on FRC.

Fixes: debbugs:9960
2011-11-05 13:34:56 +02:00
Eli Zaretskii
fc5f9b45f6 Last part of fix for bug #8562 with Emacs on Windows 9X.
nt/runemacs.c (ensure_unicows_dll): New function, tries to load
 UNICOWS.DLL on Windows 9X.
 (WinMain): If ensure_unicows_dll fails to find UNICOWS.DLL,
 display a dialog to the effect that Emacs cannot be started.
2011-11-04 23:59:16 +02:00
Chong Yidong
2e5f9e42d0 Bump version to 24.0.91.
Regenerate AUTHORS and ldefs-boot.el.
2011-10-31 10:25:01 +08:00
Eli Zaretskii
8cedc5acf9 Document that UNICOWS.DLL is required to run Emacs on Windows 9X.
nt/README.W32: Mention UNICOWS.DLL as prerequisite for running
 Emacs on Windows 9X.
 admin/nt/README-ftp-server: Mention UNICOWS.DLL as prerequisite for
 running Emacs on Windows 9X.

Fixes: debbugs:8562
2011-10-28 17:03:13 +02:00
Eli Zaretskii
df1c5f0561 Don't put INSTALL into w32 binary distributions. (Bug#9861)
nt/makefile.w32-in (dist): Don't put the top-level INSTALL into the
 distribution.
2011-10-25 18:54:19 +02:00
Christoph Scholtes
df6d30f325 * INSTALL: Update URL for GTK download page. 2011-10-24 20:33:24 -06:00
Eli Zaretskii
804a4315bd Fix bugs #641 and #9794 with %Z and current-time-zone on w32.
nt/config.nt (HAVE_TZNAME, HAVE_DECL_TZNAME): Define.
2011-10-22 11:17:01 +02:00
Chong Yidong
f7d75b4bba Bump version to 24.0.90.
Regenerate AUTHORS and ldefs-boot.el.
2011-09-25 23:20:03 -04:00
Juanma Barranquero
5e617bc2b6 Whitespace changes. 2011-09-09 03:06:52 +02:00
Paul Eggert
86633eab8a sprintf-related integer and memory overflow issues
Fixes: debbugs:9397 debbugs:9412
2011-09-04 14:52:59 -07:00
Paul Eggert
55e5faa189 Add a stub for snprintf, for ancient hosts lacking it.
* configure.in (snprintf): New check.
* nt/config.nt (HAVE_SNPRINTF): New macro.
* src/sysdep.c (snprintf) [! HAVE_SNPRINTF]: New function.
2011-08-31 15:18:16 -07:00
Paul Eggert
044c22e545 Merge: Integer signedness and overflow and related fixes.
Fixes: debbugs:9079
2011-07-27 17:48:01 -07:00
Paul Eggert
0e926e561c Assume freestanding C89 headers, string.h, stdlib.h. 2011-07-06 18:32:56 -07:00
Eli Zaretskii
81d63f1a46 nt/ChangeLog: Fix a typo in last entry. 2011-06-07 15:35:48 +03:00
Eli Zaretskii
f7b2cdf3ad Update nt/inc/stdint.h for PTRDIFF_MAX.
nt/inc/stdint.h (INT32_MAX, INT64_MAX, INTPTR_MAX, PTRDIFF_MAX)
 [!__GNUC__]: New macros.
2011-06-07 15:34:09 +03:00
Paul Eggert
55d4c1b248 [ChangeLog]
Use 'inline', not 'INLINE'.
* configure.in, autogen/config.in (INLINE): Remove.
[lib-src/ChangeLog]
Use 'inline', not 'INLINE'.
* etags.c (hash): Now inline unconditionally.
* make-docfile.c (put_char): inline, not INLINE.
[nt/ChangeLog]
Use 'inline', not 'INLINE'.
* config.nt (INLINE): Remove.
[src/ChangeLog]
Use 'inline', not 'INLINE'.
* alloc.c, fontset.c (INLINE): Remove.
* alloc.c, bidi.c, charset.c, coding.c, dispnew.c, fns.c, image.c:
* intervals.c, keyboard.c, process.c, syntax.c, textprop.c, w32term.c:
* xdisp.c, xfaces.c, xterm.c: Replace all uses of INLINE with inline.
* gmalloc.c (register_heapinfo): Use inline unconditionally.
* lisp.h (LISP_MAKE_RVALUE): Use inline, not __inline__.
2011-05-28 15:39:39 -07:00
Eli Zaretskii
8a70d4b1e2 nt/README.W32: Add information about GnuTLS libraries. 2011-05-17 21:17:45 +03:00
Eli Zaretskii
394970663d Define a replacement for va_copy for MSVC.
nt/config.nt [_MSC_VER] (va_copy): Replacement for the MS compiler.
2011-05-09 16:35:56 +03:00
Ben Key
4d3fcc8e60 * nt/configure.bat: Renamed the fusercflags variable to escusercflags
so that the variable name better matches its purpose, to be identical
to usercflags with the exception that all quotes are escaped by the \
character.

Renamed the fuserldflags variable to escuserldflags so that the
variable name better matches its purpose, to be identical to
userldflags with the exception that all quotes are escaped by the \
character.

A new ESC_USER_CFLAGS variable is written to config.settings.  This
variable has the same value as the escusercflags variable.

* nt/gmake.defs, nt/nmake.defs: Added the variable ESC_CFLAGS.  This
variable is identical to the CFLAGS variable except that it includes
the new ESC_USER_CFLAGS variable instead of USER_CFLAGS.

* src/makefile.w32-in: The bootstrap-temacs rule now makes use of one
of two shell specific rules, either bootstrap-temacs-CMD or
bootstrap-temacs-SH.  The bootstrap-temacs-SH rule is identical to the
previous implementation of the bootstrap-temacs rule.  The
bootstrap-temacs-CMD rule is similar to the previous implementation of
the bootstrap-temacs rule except that it makes use of the ESC_CFLAGS
variable instead of the CFLAGS variable.


These changes are required to extend my earlier fix to add support for
--cflags and --ldflags options that include quotes so that it works
whether make uses cmd or sh as the shell.
2011-05-06 23:00:12 -05:00
Eli Zaretskii
0a47eac473 Adapt Windows include files to latest changes.
nt/inc/inttypes.h [!__MINGW32__]: Include stdint.h.  Move the
 definition of uintmax_t from here...
 nt/inc/stdint.h (uintmax_t): ...to here.
 (intptr_t) [!__GNUC__]: New typedef.
2011-05-06 15:09:08 +03:00
Paul Eggert
122b0c8643 Temporarily disable wider-than-pointer EMACS_INT. 2011-05-05 22:55:01 -07:00
Paul Eggert
852a74a59b Merge from mainline. 2011-05-04 22:31:24 -07:00
Ben Key
d429d8e9c3 * configure.bat: Added support for --cflags and --ldflags
options that include quotes as long as command extensions are
enabled.  Specifically when -I, -L, and similar flags are used
to specify supplementary include and library directories a
directory name that includes spaces may now be used if it is
enclosed in quotes.

* INSTALL: Documented the change to configure.bat.
2011-05-04 21:56:16 -05:00
Juanma Barranquero
0898ca10c0 Implement dynamic loading of GnuTLS on Windows.
* lisp/term/w32-win.el (dynamic-library-alist): Add `gnutls'.

* nt/INSTALL: Clarify GnuTLS support.

* src/callproc.c, src/emacs.c: Include lisp.h before src/w32.h, not after.

* src/gnutls.c (Qgnutls_dll): Define.
  (DEF_GNUTLS_FN, LOAD_GNUTLS_FN): New macros.
  (gnutls_*): Declare function pointers.
  (init_gnutls_functions): New function to initialize function pointers.
  (emacs_gnutls_handshake, Fgnutls_error_string, Fgnutls_deinit)
  (emacs_gnutls_global_init, Fgnutls_bye): Use function pointers.
  (emacs_gnutls_record_check_pending, emacs_gnutls_transport_set_errno):
  Wrappers for gnutls_record_check_pending and gnutls_transport_set_errno.
  (emacs_gnutls_write, emacs_gnutls_read)
  (emacs_gnutls_handle_error, Fgnutls_error_fatalp)
  (Fgnutls_available_p): New function.
  (Fgnutls_boot): Call Fgnutls_available_p.  Use function pointers.
  (syms_of_gnutls) <Qgnutls_dll>: Initialize and staticpro it.
  (syms_of_gnutls) <Sgnutls_available_p>: defsubr it.

* src/gnutls.h (GNUTLS_EMACS_ERROR_NOT_LOADED): New macro.
  (emacs_gnutls_write, emacs_gnutls_read): Mark as extern.
  (emacs_gnutls_record_check_pending, emacs_gnutls_transport_set_errno):
  Declare.

* src/w32.c (QCloaded_from, Vlibrary_cache): Define.
  (w32_delayed_load): Move from image.c.  When loading a library, record
  its filename in the :loaded-from property of the library id.
  (globals_of_w32) <QCloaded_from, Vlibrary_cache>:
  Initialize and staticpro them.
  (emacs_gnutls_pull, emacs_gnutls_push): Call emacs_gnutls_* functions.

* src/image.c: Include w32.h.
  (Vimage_type_cache): Delete.
  (syms_of_image) <Vimage_type_cache>: Don't initialize and staticpro it.
  (CACHE_IMAGE_TYPE, Finit_image_library): Use Vlibrary_cache instead.
  (w32_delayed_load): Move to w32.c.

* src/process.c: Include lisp.h before src/w32.h, not after.
  (wait_reading_process_output): Call emacs_gnutls_record_check_pending
  instead of gnutls_record_check_pending.

* src/w32.h (VlibraryCache, QCloaded_from, w32_delayed_load): Declare.
2011-05-04 16:03:16 +02:00
Paul Eggert
b5611f17a7 Merge from mainline. 2011-04-30 12:00:39 -07:00
Eli Zaretskii
ba366b6db5 Define HAVE_LONG_LONG_INT, HAVE_UNSIGNED_LONG_LONG_INT for Windows.
nt/config.nt (HAVE_LONG_LONG_INT, HAVE_UNSIGNED_LONG_LONG_INT):
 Define to 1 for MinGW of MSVC versions >= 1400.
2011-04-30 12:14:30 +03:00
Paul Eggert
68652052aa * config.nt: Simplify test to 1400 <= _MSC_VER. 2011-04-30 00:38:26 -07:00
Paul Eggert
b28b879992 * config.nt: Configure 64-bit integers.
(BITS_PER_LONG_LONG): Define if C99-style long long and "%lld" work.
(EMACS_INT, BITS_PER_EMACS_INT, pI): Otherwise, define these if
__int64 and "%I64d" work.
2011-04-29 23:51:50 -07:00
Eli Zaretskii
aff458c342 nt/gmake.defs (ARCH): Fix error message in case of unknown architecture. 2011-04-28 23:43:23 +03:00
Eli Zaretskii
6c06b142a0 nt/INSTALL: More details about problems with MSYS Bash.
Fixes: debbugs:8564
2011-04-28 23:28:51 +03:00
Eli Zaretskii
a8f9176117 nt/INSTALL: Mention problems with MSYS/Cygwin Bash right at the beginning.
Fixes: debbugs:8564
2011-04-28 20:25:14 +03:00
Eli Zaretskii
fc3b729195 Support inttypes.h and strtoumax in non-MinGW builds on Windows.
nt/inc/inttypes.h: New file.
 nt/config.nt (HAVE_DECL_STRTOULL, HAVE_DECL_STRTOUMAX)
 (HAVE_STRTOULL, HAVE_STRTOUMAX): New macros.
2011-04-28 00:14:34 +03:00
Juanma Barranquero
841a157789 Fix ChangeLog typos. 2011-04-27 21:51:19 +02:00
Daniel Colascione
fe9c230b7f * cmdproxy.c (try_dequote_cmdline): Notice variable substitutions in
quoted strings and bail out.
2011-04-26 21:19:15 -07:00
Daniel Colascione
8f91bf9345 Improve Windows quoting robustness 2011-04-26 03:44:03 -07:00
Ted Zlatanov
fd4af8d902 Add GnuTLS support for W32.
* nt/configure.bat: New options --without-gnutls and --lib, new build
variable USER_LIBS, automatically detect GnuTLS.  Copies the PNG
library setup with trivial modifications.
* nt/INSTALL: Add instructions for GnuTLS support.
* nt/gmake.defs: Prefix USER_LIBS with -l.
2011-04-24 20:29:31 -05:00
Ben Key
4a1a6b5b7d Modified the code that parses the --cflags and --ldflags options to support parameters that include the = character as long as they are enclosed in quotes. 2011-04-15 17:48:00 -05:00
Eli Zaretskii
0f1ba050b3 Fix the Windows build due to introduction of ATTRIBUTE_FORMAT_PRINTF.
nt/config.nt (NO_INLINE, ATTRIBUTE_FORMAT)
 (ATTRIBUTE_FORMAT_PRINTF): Define, as followup to 2011-04-06T05:19:39Z!eggert@cs.ucla.edu
 on the trunk on 2011-04-06.
2011-04-06 18:44:32 +03:00
Juanma Barranquero
3338398778 Update and split ChangeLogs. 2011-04-06 14:18:10 +02:00
Glenn Morris
9af30bdf17 Remove (RET)SIGTYPE; it is identical to void on all supported systems.
Ref: http://lists.gnu.org/archive/html/emacs-devel/2011-03/msg01068.html

* configure.in (AC_TYPE_SIGNAL): Remove obsolete macro.
(AH_BOTTOM): Do not define SIGTYPE.

* lib-src/emacsclient.c: Replace SIGTYPE with void.

* nt/config.nt: Remove RETSIGTYPE, SIGTYPE (identical to void).

* src/syssignal.h: Replace RETSIGTYPE with void.

* src/atimer.c, src/data.c, src/dispnew.c, src/emacs.c, src/floatfns.c:
* src/keyboard.c, src/keyboard.h, src/lisp.h, src/process.c, src/sysdep.c:
* src/xterm.c: Replace SIGTYPE with void everywhere.

* src/s/template.h (SIGTYPE): Remove commented out definition.
* src/s/usg5-4-common.h (SIGTYPE): Remove definition.

* admin/CPP-DEFINES: Remove SIGTYPE.
2011-03-26 19:27:11 -07:00
Juanma Barranquero
0f4a96b5d7 nt/*.c, src/*.c: Remove unused variables.
* nt/addpm.c (main): Remove unused variable `retval'.
* nt/preprep.c (main): Remove unused variable `ptr'.
* src/dispextern.h (glyph_matric): Use #if GLYPH_DEBUG, not #ifdef.
* src/fileio.c (check_executable) [DOS_NT]: Remove unused variables `len'
  and `suffix'.
  (Fset_file_selinux_context) [HAVE_LIBSELINUX]: Move here declaration
  of variables specific to SELinux and computation of `encoded_absname'.
* src/image.c (XPutPixel): Remove unused variable `height'.
* src/keyboard.c (make_lispy_event): Remove unused variable `hpos'.
* src/unexw32.c (get_section_info): Remove unused variable `section'.
* src/w32.c (stat): Remove unused variables `drive_root' and `devtype'.
  (system_process_attributes): Remove unused variable `sess'.
  (sys_read): Remove unused variable `err'.
* src/w32fns.c (top): Wrap variables with #if GLYPH_DEBUG, not #ifdef.
  (w32_wnd_proc): Remove unused variable `isdead'.
  (unwind_create_frame): Use #if GLYPH_DEBUG, not #ifdef.
  (Fx_server_max_request_size): Remove unused variable `dpyinfo'.
  (x_create_tip_frame): Remove unused variable `tem'.
* src/w32inevt.c (w32_console_read_socket): Remove unused variable `no_events'.
* src/w32term.c (x_draw_composite_glyph_string_foreground):
  Remove unused variable `width'.
2011-03-25 16:39:59 +01:00
Juanma Barranquero
9c88f33949 w32: Fix some warnings reported by -Wall -Wextra.
* lib-src/ntlib.c: Include <ctype.h>.

* nt/cmdproxy.c: Include <ctype.h>.
  (make_absolute): Remove unused variable `i'.

* src/w32fns.c (x_set_menu_bar_lines): Remove unused variable `olines'.
  (w32_wnd_proc): Pass NULL to Windows API, not uninitialized buffer.
  (Fx_close_connection): Remove unused variable `i'.

* src/w32font.c (w32font_draw): Return number of glyphs.
  (w32font_open_internal): Remove unused variable `i'.
  (w32font_driver): Add missing initializer.

* src/w32menu.c (utf8to16): Remove unused variable `utf16'.
  (fill_in_menu): Remove unused variable `items_added'.

* src/w32term.c (last_mouse_press_frame): Remove static global variable.
  (w32_clip_to_row): Remove unused variable `f'.
  (x_delete_terminal): Remove unused variable `i'.

* src/w32uniscribe.c (uniscribe_shape): Remove unused variable `nclusters'.
  (NOTHING): Remove unused static global variable.
  (uniscribe_check_otf): Remove unused variable `table'.
  (uniscribe_font_driver): Add missing initializers.
2011-03-23 17:25:38 +01:00
Eli Zaretskii
0f7bb05d28 Implement stubs of readlink' and symlink' for MS-Windows.
src/w32.c (symlink, readlink): New stub functions.
 nt/inc/unistd.h (readlink, symlink): Declare prototypes.
2011-02-27 21:48:31 +02:00
Eli Zaretskii
e5c96d2184 Define nlink_t for w32.
nt/config.nt (nlink_t): Define.
2011-02-26 16:02:45 +02:00
Christoph Scholtes
9f8370e63f Add stdint.h for MS-Windows.
nt/inc/stdint.h: New file, to support compilation with tool chains
 that do not have stdint.h (e.g. MSVC).
 lib/makefile.w32-in: ($(BLD)/md5.$(O)): Added dependency on
 $(EMACS_ROOT)/nt/inc/stdint.h.
2011-02-21 22:16:43 +02:00
Eli Zaretskii
25c51af3a9 Adapt MS-Windows build to import of filemode.c from gnulib.
nt/inc/sys/stat.h (S_ISUID, S_ISGID, S_ISVTX, S_IRGRP, S_IROTH)
 (S_IWGRP, S_IWOTH, S_IXGRP, S_IXOTH, S_ISSOCK, S_ISLNK, S_ISCTG)
 (S_ISDOOR, S_ISMPB, S_ISMPC, S_ISNWK, S_ISPORT, S_ISWHT)
 (S_TYPEISMQ, S_TYPEISSEM, S_TYPEISSHM, S_TYPEISTMO): Define.
 (lstat): Define to stat.
 lib/makefile.w32-in ($(BLD)/filemode.$(O)): Move from
 src/makefile.w32-in and adapt.  Depend on stamp_BLD.
 (GNULIBOBJS): Add $(BLD)/filemode.$(O).
 src/makefile.w32-in ($(BLD)/filemode.$(O)): Move recipe to
 lib/makefilw.w32-in.
 ($(BLD)/dired.$(O)): Depend on $(EMACS_ROOT)/lib/filemode.h.
 (GLOBAL_SOURCES): Remove filemode.c.
 (OBJ1): Remove $(BLD)/filemode.$(O).
 lib-src/makefile.w32-in ($(BLD)/ctags.$(O), $(BLD)/emacsclient.$(O))
 ($(BLD)/etags.$(O), $(BLD)/movemail.$(O), $(BLD)/ntlib.$(O)):
 Depend on $(EMACS_ROOT)/nt/inc/sys/stat.h.
2011-02-21 22:00:19 +02:00
Eli Zaretskii
d37f40ed38 Update the Windows build according to 2011-02-08T21:42:56Z!tromey@redhat.com and 2011-02-09T17:04:43Z!schwab@linux-m68k.org.
src/makefile.w32-in (GLOBAL_SOURCES, SOME_MACHINE_OBJECTS, obj): New
 macros.
 (globals.h, gl-stamp): New targets.
 (clean): Clean gl-stamp and globals.h.
 nt/makefile.w32-in (bootstrap-nmake, bootstrap-gmake): Make the
 "make-docfile" target in lib-src, before bootstrapping the src
 directory.  Needed since building in src needs to run make-docfile
 to produce globals.h.
2011-02-09 22:50:17 +02:00