; Recommend not to use -O3 in production builds
* nt/INSTALL: * INSTALL: Recommend not to use -O3 and -Os in ordinary production builds. (Bug#76559)
This commit is contained in:
parent
6ed119d305
commit
75a314dc8a
2 changed files with 19 additions and 4 deletions
19
INSTALL
19
INSTALL
|
@ -10,7 +10,7 @@ instructions in this file should be sufficient. For other
|
|||
configurations, we have additional specialized files:
|
||||
|
||||
. INSTALL.REPO if you build from a Git checkout
|
||||
. nt/INSTALL if you build for MS-Windows
|
||||
. nt/INSTALL if you build a native (non-Cygwin) Emacs for MS-Windows
|
||||
. nextstep/INSTALL if you build for GNUstep/macOS
|
||||
. java/INSTALL if you build for Android
|
||||
. msdos/INSTALL if you build for MS-DOS
|
||||
|
@ -294,12 +294,20 @@ Lisp code even if your system satisfies the build requirements, use the
|
|||
|
||||
DETAILED BUILDING AND INSTALLATION:
|
||||
|
||||
(This is for a Unix or Unix-like system. For GNUstep and macOS,
|
||||
see nextstep/INSTALL. For non-ancient versions of MS Windows, see
|
||||
the file nt/INSTALL. For MS-DOS and MS Windows 3.X, see msdos/INSTALL.)
|
||||
(This is for a Unix or Unix-like system (including Cygwin on
|
||||
MS-Windows). For GNUstep and macOS, see nextstep/INSTALL. For building
|
||||
a native Windows Emacs for non-ancient versions of MS Windows, see the
|
||||
file nt/INSTALL. For MS-DOS and MS Windows 3.X, see msdos/INSTALL.)
|
||||
|
||||
1) See BASIC INSTALLATION above for getting and configuring Emacs.
|
||||
|
||||
1a) For ordinary production builds, if you want to specify non-default
|
||||
compiler options via CFLAGS variable, we recommend against using
|
||||
optimization options -O3 or -Os, and also recommend not to use the
|
||||
compiler option -fsanitize=undefined. These are known to sometimes cause
|
||||
problems with the generated code, and we recommend using them only in
|
||||
debugging builds or for testing specific problems in Emacs.
|
||||
|
||||
2) In the unlikely event that 'configure' does not detect your system
|
||||
type correctly, consult './etc/MACHINES' to see what --host, --build
|
||||
options you should pass to 'configure'. That file also offers hints
|
||||
|
@ -534,6 +542,9 @@ to look in '/bar/mylib' for libraries, pass the -Og optimization
|
|||
switch to the compiler, and link against libfoo and libbar
|
||||
libraries in addition to the standard ones.
|
||||
|
||||
For ordinary production builds, we recommend against using -O3 and -Os
|
||||
in CFLAGS, and also against using -fsanitize=undefined compiler option.
|
||||
|
||||
For some libraries, like Gtk+, fontconfig and ALSA, 'configure' uses
|
||||
pkg-config to find where those libraries are installed.
|
||||
If you want pkg-config to look in special directories, you have to set
|
||||
|
|
|
@ -55,6 +55,10 @@ build should run on Windows 9X and newer systems).
|
|||
./configure --prefix=/d/usr/emacs --enable-checking='yes,glyphs' \
|
||||
CFLAGS='-O0 -g3'
|
||||
|
||||
(For ordinary production builds, we recommend not to use -O3 or -Os
|
||||
in CFLAGS, as those could sometimes produce bad or suboptimal code,
|
||||
especially in major new releases of GCC.)
|
||||
|
||||
3. After the configure script finishes, it should display the
|
||||
resulting configuration. After that, type
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue