| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
compiler supports it
Submitted in https://savannah.gnu.org/patch/index.php?9243.
Suggested-by: Attila <attila@stalphonsos.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These macros would fail with infinite recursion if used twice for the
same variable, for example
AX_COMPILER_FLAGS_CFLAGS([WARN_CFLAGS], ... some options ...)
AX_COMPILER_FLAGS_CFLAGS([WARN_CFLAGS], ... more options ...)
In particular, invoking AX_COMPILER_FLAGS, followed by
AX_COMPILER_FLAGS_CFLAGS with more "yes" options has this failure mode.
This is because the first time through the macro, we define
ax_warn_cflags_variable = "WARN_CFLAGS" as expected. The second time,
because the first parameter is underquoted, its value is substituted
before calling m4_define, so we inadvertently define
WARN_CFLAGS = "WARN_CFLAGS". The next time WARN_CFLAGS is mentioned,
attempts to expand it will recurse forever, because m4 does not
special-case a macro that appears in its own expansion like cpp does.
Signed-off-by: Simon McVittie <smcv@debian.org>
|
| |
|
|
|
|
|
| |
Substring expansion such as ${flag:5} is not supported by POSIX, and
it can cause error for systems not using bash as their default shell.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These characters caused the `macro2m4.py` script to terminate with an error:
$ make maintainer-all
...
python ./macro2m4.py "m4/ax_compiler_flags_cflags.m4" "stage/ax_compiler_flags_cflags.m4"
Traceback (most recent call last):
File "./macro2m4.py", line 56, in <module>
m = Macro(m4File, computeSerialNumber=True)
File "~/src/autoconf-archive/macro.py", line 62, in __init__
(header,body) = loadFile(filePath).split("\n\n", 1)
File "~/src/autoconf-archive/macro.py", line 8, in loadFile
return fd.read()
File "/usr/lib/python3.4/encodings/ascii.py", line 26, in decode
return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 3615: ordinal not in range(128)
cfg.mk:35: recipe for target 'stage/ax_compiler_flags_cflags.m4' failed
make: *** [stage/ax_compiler_flags_cflags.m4] Error 1
This error might only occur when using Python 3.
Since all affected characters were apostrophes in comments, I simply replaced
them with ASCII character 39.
The serial numbers of the files were incremented.
|
|
|
|
|
|
|
|
|
|
|
|
| |
These went against the whole concept of providing a baseline set of
warnings which is set by the module maintainer, since it allowed
individual developers to opt out of certain classes of warning.
Remove them, leaving the ‘no’, ‘yes’ and ‘error’ levels. This maintains
API compatibility of the macros by marking various EXTRA-* variables as
unused, but still handling them, and merging their values with the
preceding EXTRA-* variables. For example, all extra ‘maximum’ and
‘error’ flags are now included in the ‘yes’ level of warnings.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We need to add a -Wno-error=* flag for each -Wno-* flag as some
compilers will re-enable the warning as an error if -Wall is passed in
the user’s CFLAGS after we’ve specific -Werror.
Previously this was done manually for the -Wno-* flags in
AX_COMPILER_FLAGS_CFLAGS and AX_COMPILER_FLAGS_CXXFLAGS. However, this
ignored the cases where the user was passing -Wno-* flags as extra-flags
to the macros.
Factor this out and automate it so -Wno-error=* flags will be tested and
appended for any -Wno-* flag specified by the user in extra-flags.
|
|
|
|
|
|
|
|
|
|
| |
See the new comments for details. Disable specific flags (which were
already disabled) as errors as well as warnings, to prevent -Wall from a
build bot effectively re-enabling them as errors.
Based on
http://cgit.freedesktop.org/telepathy/telepathy-glib/tree/m4/tp-compiler-warnings.m4#n22.
Thanks to Simon McVittie.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a new AX_COMPILER_FLAGS_CXXFLAGS macro, which acts similarly to
AX_COMPILER_FLAGS_CFLAGS, but for the C++ compiler.
Modify the default set of warnings slightly, to remove
-Waggregate-return, because using it makes it difficult to write
idiomatic C++ code. Add -Wno-overloaded-virtual as a C++-specific
warning. Remove C-specific warnings such as -Wnested-externs,
-Wmissing-prototypes, -Wstrict-prototypes,
-Wdeclaration-after-statement, -Wold-style-definition and
-Wimplicit-function-declaration.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
The build process requires python, the python StringTemplate module,
and preferably SCons. A make-based build exists, but it is really slow
and awkward, compared to the SConstruct file.
|