mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-24 07:20:37 +00:00
530 lines
9.9 KiB
Plaintext
530 lines
9.9 KiB
Plaintext
Here are some of the cpp macros used, together with some short explanation
|
|
of their use. Feel free to add more macros and more categories.
|
|
Most of these are from config.in, so it's probably better to put the
|
|
explanations in that file. Ideally, everything would be defined and
|
|
documented in config.in, and this file would not be necessary.
|
|
|
|
|
|
** Distinguishing OSes **
|
|
|
|
AIX
|
|
_AIX
|
|
CYGWIN Compiling the Cygwin port.
|
|
__CYGWIN__ Ditto
|
|
GNU_LINUX
|
|
HPUX
|
|
MSDOS Compiling the MS-DOS port.
|
|
__MSDOS__ Ditto.
|
|
__DJGPP_MINOR__ Minor version number of the DJGPP library; used only in msdos.c and dosfns.c.
|
|
DOS_NT Compiling for either the MS-DOS or native MS-Windows port.
|
|
WINDOWSNT Compiling the native MS-Windows (W32) port.
|
|
__MINGW32__ Compiling the W32 port with the MinGW or MinGW-w64 ports of GCC.
|
|
MINGW_W64 Compiling the W32 port with the MinGW-w64 port of GCC.
|
|
DARWIN_OS Compiling on macOS or pure Darwin (and using s/darwin.h).
|
|
SOLARIS2
|
|
USG
|
|
USG5_4
|
|
HAIKU Compiling on Haiku.
|
|
|
|
** Distinguishing GUIs **
|
|
|
|
HAVE_NTGUI Use the native W32 GUI for windows, frames, menus&scrollbars.
|
|
HAVE_NS Use the NeXT/OpenStep/Cocoa UI under macOS or GNUstep.
|
|
NS_IMPL_GNUSTEP Compile support for GNUstep implementation of NS GUI API.
|
|
NS_IMPL_COCOA Compile support for Cocoa (Apple) implementation of NS GUI API.
|
|
HAVE_X11 Compile support for the X11 GUI.
|
|
HAVE_PGTK Compile support for using GTK itself without directly using X Windows APIs.
|
|
HAVE_HAIKU Compile support for the Haiku window system.
|
|
HAVE_X_WINDOWS Compile support for X Window system
|
|
(It looks like, nowadays, if HAVE_X11 is set, HAVE_X_WINDOWS must
|
|
be, and vice versa. At least, this is true for configure, and
|
|
msdos; not sure about nt.)
|
|
|
|
** X Windows features **
|
|
HAVE_X11R6 Whether or not the system has X11R6. (Always defined.)
|
|
HAVE_X11R6_XIM Whether or not the system supports XIM features introduced in R6.
|
|
HAVE_X11XTR6 Whether or not the Xt is from X11R6 or newer.
|
|
|
|
USE_LUCID Use the Lucid toolkit for menus&scrollbars. Requires HAVE_X11.
|
|
USE_MOTIF Use the Motif toolkit for menus&scrollbars. Requires HAVE_X11.
|
|
USE_GTK Use the Gtk toolkit for menus&scrollbars. Requires HAVE_X11 or HAVE_PGTK.
|
|
HAVE_GTK3 Use GTK version 3 or later. Requires HAVE_X11.
|
|
|
|
HAVE_XCB_SHAPE Whether or not XCB supports the Nonrectangular Window Shape extension.
|
|
HAVE_XCOMPOSITE Whether or not the XCOMPOSITE extension library is present.
|
|
HAVE_XDBE Whether or not to use the Xdbe extension for double buffering.
|
|
HAVE_XFIXES Whether or not the Xfixes extension library is present.
|
|
HAVE_XINERAMA Whether or not the Xinerama extension library is present.
|
|
HAVE_XINPUT2 Whether or not to use version 2 of the X Input Extension for input.
|
|
HAVE_XINPUT2_1 Whether or not version 2.1 of the X Input Extension is supported.
|
|
HAVE_XINPUT2_2 Whether or not version 2.2 of the X Input Extension is supported.
|
|
HAVE_XINPUT2_3 Whether or not version 2.3 of the X Input Extension is supported.
|
|
HAVE_XINPUT2_4 Whether or not version 2.4 of the X Input Extension is supported.
|
|
HAVE_XKB Whether or not the XKB extension library is present.
|
|
HAVE_XRANDR Whether or not the RandR extension library is present.
|
|
HAVE_XSHAPE Whether or not the Nonrectangular Window Shape extension library is present.
|
|
HAVE_XSYNC Whether or not the X Synchronization Extension library is present.
|
|
USE_XCB Whether or not the XCB library is used to optimize some X requests.
|
|
|
|
** Frame types **
|
|
|
|
FRAME_TERMCAP_P A tty (character terminal) frame.
|
|
FRAME_X_P A frame on X Window system.
|
|
FRAME_MSDOS_P An MS-DOS frame (used only by the DOS port).
|
|
FRAME_W32_P A frame using native MS-Windows GUI.
|
|
FRAME_WINDOW_P A GUI frame (like X, w32, etc.)
|
|
|
|
** Support for accessing other processes on the system **
|
|
|
|
HAVE_PROCFS The /proc filesystem is supported.
|
|
|
|
** Compile-time options **
|
|
|
|
REL_ALLOC Compile in the relocatable memory allocator ralloc.c.
|
|
SYSTEM_MALLOC Use the system library's malloc.
|
|
subprocesses System can use subprocesses (for M-x shell for example).
|
|
Defined by default, only MSDOS undefines it.
|
|
DEBUG_LISP_OBJECT_TYPE Define it in lisp.h enable compile time checks
|
|
on Lisp_Object use.
|
|
|
|
** System specific macros
|
|
FIRST_PTY_LETTER
|
|
HAVE_PTYS
|
|
INTERRUPT_INPUT
|
|
NARROWPROTO
|
|
SEPCHAR
|
|
SYSTEM_TYPE
|
|
|
|
** Misc macros
|
|
USER_FULL_NAME If defined, overrides the default pw->pw_gecos for
|
|
getting at the full user name. Only MSDOS overrides the default.
|
|
|
|
** Miscellaneous defines. Some of these might not be used in the code
|
|
anymore, so they can be removed.
|
|
|
|
AMPERSAND_FULL_NAME
|
|
BROKEN_DATAGRAM_SOCKETS
|
|
BROKEN_GET_CURRENT_DIR_NAME
|
|
BROKEN_PTY_READ_AFTER_EAGAIN
|
|
DEFAULT_SOUND_DEVICE
|
|
DEVICE_SEP
|
|
DIRECTORY_SEP
|
|
DONT_REOPEN_PTY
|
|
DOUG_LEA_MALLOC
|
|
EMACS_CONFIGURATION
|
|
EMACS_CONFIG_OPTIONS
|
|
EMACS_INT
|
|
EMACS_UINT
|
|
GC_MARK_SECONDARY_STACK
|
|
GC_SETJMP_WORKS
|
|
GNU_MALLOC
|
|
HAVE_ALLOCA
|
|
HAVE_ALLOCA_H
|
|
HAVE_ALSA
|
|
HAVE_BDFFONT
|
|
HAVE_CFMAKERAW
|
|
HAVE_CFSETSPEED
|
|
HAVE_CLOCK_GETTIME
|
|
HAVE_CLOCK_SETTIME
|
|
HAVE_COFF_H
|
|
HAVE_COM_ERR_H
|
|
HAVE_DBUS
|
|
HAVE_DBUS_TYPE_IS_VALID
|
|
HAVE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CK
|
|
MAIL_USE_LOCKF
|
|
MAIL_USE_POP
|
|
MAIL_USE_SYSTEM_LOCK
|
|
MAXPATHLEN
|
|
NLIST_STRUCT
|
|
NSIG
|
|
NSIG_MINIMUM
|
|
NULL_DEVICE
|
|
PAGESIZE
|
|
PTY_ITERATION
|
|
PTY_NAME_SPRINTF
|
|
PTY_OPEN
|
|
PTY_TTY_NAME_SPRINTF
|
|
PURESIZE
|
|
RUN_TIME_REMAP
|
|
SETUP_SLAVE_PTY
|
|
SIGNALS_VIA_CHARACTERS
|
|
STDC_HEADERS
|
|
SYSTEM_PURESIZE_EXTRA
|
|
SYSTEM_MALLOC
|
|
TAB3
|
|
TABDLY
|
|
TERM
|
|
TIOCSIGSEND
|
|
TM_IN_SYS_TIME
|
|
UNIX98_PTYS
|
|
USE_TOOLKIT_SCROLL_BARS
|
|
USG_SUBTTY_WORKS
|
|
VALBITS
|
|
XOS_NEEDS_TIME_H
|
|
_FILE_OFFSET_BITS
|
|
_LP64
|
|
_longjmp
|
|
_setjmp
|
|
abort
|
|
alloca
|
|
close
|
|
emacs
|
|
free
|
|
gmtime
|
|
localtime
|
|
malloc
|
|
random
|
|
read
|
|
realloc
|
|
select
|
|
umask
|
|
vfork
|
|
|
|
|
|
src/sysdep.c:
|
|
write
|
|
|
|
src/syssignal.h:
|
|
signal
|
|
sigmask
|
|
sigsetmask
|
|
|
|
|
|
lib/dup2.c:
|
|
dup2
|
|
|
|
lib/signal.h:
|
|
signal
|
|
|
|
lib/stdio.h:
|
|
fdopen
|
|
fopen
|
|
fwrite
|
|
popen
|
|
rename
|
|
|
|
lib/stdlib.h:
|
|
calloc
|
|
srandom (conf_post.h may undo)
|
|
|
|
lib/strftime.c:
|
|
tzname
|
|
tzset
|
|
|
|
lib/sys/stat.h:
|
|
mkdir
|
|
|
|
lib/unistd.h:
|
|
chown
|
|
dup
|
|
dup2
|
|
ftruncate
|
|
isatty
|
|
link
|
|
lseek
|
|
pipe
|
|
rmdir
|
|
sleep
|
|
unlink
|
|
|
|
|
|
MS DOS stuff:
|
|
|
|
_NAIVE_DOS_REGS
|
|
|
|
|
|
MS stuff:
|
|
|
|
USE_CRT_DLL
|
|
|
|
ms-w32.h:
|
|
DebPrint
|
|
EMACSDEBUG
|
|
MUST_UNDEF__STDC__
|
|
|
|
_VARARGS_
|
|
_WINSOCKAPI_
|
|
_WINSOCK_H
|
|
|
|
access
|
|
calloc
|
|
chdir
|
|
chmod
|
|
chown
|
|
creat
|
|
ctime
|
|
dup
|
|
dup2
|
|
execlp
|
|
execvp (also emacsclient.c [WINDOWSNT])
|
|
fdopen
|
|
fileno
|
|
fopen
|
|
fsync
|
|
ftruncate
|
|
getdefdir
|
|
getdisk
|
|
getpid
|
|
isatty
|
|
kill
|
|
link
|
|
lseek
|
|
mkdir
|
|
mktemp
|
|
open
|
|
pclose
|
|
pipe
|
|
popen
|
|
rename
|
|
rmdir
|
|
signal
|
|
sleep
|
|
spawnve
|
|
strdup
|
|
stricmp
|
|
strnicmp
|
|
strupr
|
|
sys_nerr
|
|
tzname
|
|
tzset
|
|
umask
|
|
unlink
|
|
utimbuf
|
|
utime
|
|
wait (also movemail.c [WINDOWSNT])
|
|
write
|
|
|
|
lib-src/ntlib:
|
|
access
|
|
chdir
|
|
chmod
|
|
creat
|
|
dup
|
|
dup2
|
|
execlp
|
|
execvp
|
|
fdopen
|
|
fileno
|
|
fopen
|
|
getpid
|
|
index
|
|
isatty
|
|
lseek
|
|
mkdir
|
|
mktemp
|
|
open
|
|
pclose
|
|
pipe
|
|
popen
|
|
rmdir
|
|
rindex
|
|
sleep
|
|
umask
|
|
unlink
|
|
utime
|