| Age | Commit message (Collapse) | Author | Files | Lines |
|
Currently cgcc will die if the option '-x' is used with any argument
other than 'c'.
It makes sense since sparse can only handle C files but it can be
useful in a project to simply use something like:
make CC=cgcc
So, instead of die()ing, avoid calling sparse if such '-x' option
is used, like already done by default for non .c files.
Original-patch-by: Tom Rix <trix@redhat.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Add support for the Xtensa architecture.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Now that the OS can be specified to sparse via an option (--os=$OS)
and that sparse knows about their specificities, it's no more
needed or useful to also define them in cgcc.
So, remove from cgcc the OS-specificities known to sparse (a few
few exotic ones remain for now) but ensure that the info about
the correct OS is passed to sparse.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
The spec names 'ppc64+{be,le}' had the '+' to force them
to be internal names but are also useful as external names
(it helps to make systematic testing of the arch-specific code).
So rename them to 'ppc64{be,le}'.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
'__CYGWIN32__' is wrongly defined on 64-bit Cygwin.
Fix this by only defining it when $m32 is set and set $m32
when i386 is selected.
Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
During a call to add_specs('linux'), cgcc adds several macro definitions
to the sparse command line. In particular, it provides the incorrect
definition: '-Dlinux=linux'.
This bug was introduced in commit 807f74466b (<no title>, 2004-08-13), while
moving some calls to add_pre_buffer() around in lib.c. This was then moved
out of sparse, into cgcc, by commit cf2bde63a6 (<no title>, 2004-10-05),
where the definition was copied verbatum.
Fix this macro definition to read '-Dlinux=1' instead.
Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Sparse itself already add support for it, so add
support for it in the wrapper too.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
These options are sparse-specific and shouldn't be passed to GCC.
Reported-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
|
|
Now that sparse understands -mfloat-abi and set the related
predefines (__ARM_PCS_VFP, __ARM_PCS & __SOFTFP) it's not
cgcc can make good use of it.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Cygwin uses 'unsigned short' for its wchar_t.
So, use -fshort-wchar for it.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Some older codebases hit this warning all the time, so it's useful
to be able to disable it.
Signed-off-by: John Levon <john.levon@joyent.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
In addition of __BIG_ENDIAN__, gcc defines _BIG_ENDIAN on
powerpc (32 & 64-bit). cgcc does that too but this may also
beeneeded when using sparse itself.
So, move this define the the sparse code.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
As far as I can see, the macro '_STRING_ARCH_unaligned' may
be defined by glibc, not gcc. So, there is no reason for
cgcc to define it.
Worse, cgcc defines it to '1' while on some platorms (at least the
few ppc64 I've access to) the installed glibc defines it to '0'.
So, do not let cgcc define this macro.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Now that the arch is passed to sparse via '--arch=ARCH',
all predefines for integers and pointers are defined in sparse
itself. So, integer_types() & define_size_t() are now unneeded.
Remove these functions and -D__SIZEOF_POINTER__.
Note: sparc64 had also an entry for 128-bit integers (with
name 'LONG_LONG_LONG' and suffix 'LLL'); GCC only
predefines the SIZEOF macros which sparse also does
(but for all archs). So, it's fine to remove these also.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Now that it's possible to specify the architecture via
the --arch=ARCH option, let cgcc make use of it.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
In commit bb1bf7485 ("cgcc: gendeps for -MM, -MD & -MMD too"),
the flags -MD & -MMD were treated as -M (and -MM):
inhibit calling the checker/sparse because the command is
only used to generate dependencies.
But while this behaviour is correct for -MM, it's not for -MD & -MMD
since these flags are only used to generate the dependencies
*in addition* to the normal processing.
Fixes: bb1bf748580d1794f8da7200ba83ccfc2f2f3a8a
Reported-by: Ilya Maximets <i.maximets@samsung.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Better to declare undeclared or unintialized vars early,
so use the 'strict' & 'warnings' pragmas.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
* cgcc: add support for x86-x32
* cgcc: favor using 'gcc -dumpmachine' to determine specifics
* cgcc: simpler handling of hard-float ARM
* cgcc: add pseudo-archs for ppc64be/ppc64le
* cgcc: -dumpmachine should be fetched with '$ccom'
|
|
Detect when the target is x86-x32 and pass the appropriate flag '-mx32'.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
`uname -m` returns information about the host machine but this
information is useless when cgcc is used with a non-native compiler
since it's information about the target machine that is needed.
So, first try to determine the target machine via `gcc -dumpmachine`
and default to `uname -m`.
Note: this should fix problems with Debian build when armhf builder
is run on a arm64 environment.
Originally-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
There is an ABI for ARM with hard floats and one for soft floats
(as well as one for a sort of mix between hard & soft).
For hard floats, the preprocessor symbol '__ARM_PCS_VFP' needs to
be defined. This is added as an additional check in the code
returning the 'specs' for ARM.
To facilitate some upcoming changes and code reuse here, create
a pseudo-arch 'arm+hf' using '-D__ARM_PCS_VFP=1' in addition to
the usual options for ARM.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Platforms having an uname's machine 'ppc64' or 'ppc64le' need to
have their endianness set (as well as the 'ELF' version).
To facilitate some future changes and code reuse here, create
entries for 2 pseudo-archs 'ppc64+be' & 'ppc64+le'.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
The variable '$ccom' is used to hold the compiler command only
while '$cc' hold the compiler and it's options.
So, use '$ccom' to fetch '-dumpmachine' instead of '$cc'.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
* cgcc: -MF, -MQ & -MT need an argument
* cgcc: gendeps for -MM, -MD & -MMD too
|
|
It seems that some header files somehow need this.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
These flags expect an argument. So, the following element in
'@ARGV' must then not be considered as an option or an input file,
exactly like done for '-o FILE'.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
These flags must set '$gendeps', just like a plain '-M' do,
since they implies '-M'.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
cgcc fails if it doesn't know about the system/OS as
returned by `uname -s`. This creates a build failure for
Debian since Hurd is one of their non-official 'ports'
but unknown to cgcc.
So, teach cgcc about 'GNU' (the OS/system name returned
on Hurd) and add the few predefines used to identify it.
Reported-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Predefined macros like '__x86_64__', '__arm__', ... are used
in systems headers (and surely at other places too).
So, when appropriate, define the following symbols which seems
to be somehow needed by glibc:
m68k: __m68k__
mips: __mpis64, __mips
ppc: __ppc64__, __powerpc, __ppc__
riscv: __riscv__, __riscv_xlen__
s390: __zarch__
sparc: __sparc_v9__, __sparcv9
x86-64: __x86_64__, __x86_64
Also, the following symbols, which were previously only defined
in cgcc, are now defined in Sparse itself:
i386 __i386, __i386__
sparc __sparc, __sparc__, __arch64__, __sparc64__, __sparcv9__
s390 __s390__, __s390x__
ppc __PPC__, __powerpc__, __PPC64__, __powerpc64__
arm __arm__
arm64 __aarch64__
Note: these are only tested on i386, x86-64, arm, arm64,
mips64 (ABI O32), ppc, ppc64 (power7), ppc64el (power8)
and sparc64, most of them on a not-so-new OS version.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
cgcc can be used when cross-compiling if the target architecture
is given with '-target=<arch>'.
However, the name that needs to be given for the i386 arch is 'i86'.
Fix this by changing the name 'i86' into 'i386'.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Currently, cgcc only checks input files if their names end with
'.c' or if given as stdout. Other files are explicitly ignored.
This generally corresponds to what is wanted but GCC allows
arbitrary input files if the option '-x <language>' is given.
Some projects use this mechanism, for example to use the C
pre-processor on non-C files.
This fails when cgcc is used as wrapper around sparse + GCC.
Fix this by teaching cgcc about the '-x c' option.
Reported-by: Antonio Ospite <ao2@ao2.it>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
The option '-o', in itself, doesn't need to be handled
specially by cgcc but this option takes an argument and
option arguments need to be ignored by cgcc (otherwise
they can be interpreted and filtered-out by cgcc).
Avoid potential problems with -o's argument by simply
ignoring it.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
cgcc only does a minimal processing and filtering of its
command line and most options are simply forwarded to sparse
and gcc.
However, if one of the ignored options takes an argument that
matches one of the non-ignored options, this argument will be
processed as an option with undesirable effect.
Allow options to specify the number of arguments they're taking
and avoid any processing or filtering of these arguments while
still forwarding them to sparse and gcc.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Currently, when used on the kernel, sparse issues a bunch
of warnings like:
warning: constant 0x100000000 is so big it is long
These warning are issued when there is a discrepancy
between the type as indicated by the suffix (or the absence
of a suffix) and the real type as selected by the type
suffix *and* the value of the constant.
Since there is nothing incorrect with this discrepancy,
(no bits are lost) these warnings are more annoying than useful.
So, make them depending on a new warning flag -Wconstant-suffix
and make it off by default.
Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
When using sparse it's common to compile a file and directly
run sparse on the same file, like it is done for the kernel.
In this case, error messages from sparse are interspersed with
those from the compiler. It's thus not always easy to know from
which tools they come.
Fix this by allowing to prefix all the diagnostic messages
by some configurable string, by default "sparse". More exactly,
an error message that was emitted like:
file.c:<line>:<col>: error: this is invalid code
can now be emitted as:
file.c:<line>:<col>: sparse: error: this is invalid code
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Reviewed-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
|
|
Currently, cgcc contains the logic to add predefined symbols
like __INT_MAX or __SIZEOF_POINTER, but:
1) this logic is now completly present in sparse itself
2) cgcc hasn't the logic needed for x86-64-x32 which sparse now has.
So, drop these defines in cgcc and let cgcc simply use the ones
predefined by sparse itself.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Acked-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
|
|
|
|
as it will be used for dumping the IR not only just after
linearization but after other passes too.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Commit e0306fe0 "cgcc: teach cgcc about ppc64[le]" add support
for PPC64 to cgcc by adding the needed options like '-m64' &
'-m{little,big}-endian' and defines likes '-D__PPC64__=1'.
In this commit the defined '-D_CALL_ELF=2' was also added
but the value of 2 is for ELF v2 ABI, normally used for ppc64le,
while the older ELF ABI, normally used for plain ppc64 should use
'-D_CALL_ELF=2'.
Fix this by using the value of 1 or 2 for '_CALL_ELF' depending
if the architecture is ppc64 or ppc64le.
Fixes: e0306fe0b725af6e2e7ff59d7f0d99c96315791a
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Tested-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
This fixes:
$ uname -m
armv8l
$ env CHECK=./sparse ./cgcc -no-compile memops.c
/usr/include/arm-linux-gnueabihf/gnu/stubs.h:7:12: error: unable to open 'gnu/stubs-soft.h'
Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
This is needed to use sparse on the git tree on an arm64
machine (where a bug in the __builtin_bswapXX() expansion
was discovered).
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
By default, sparse will warn if memcpy() (or memset(),
copy_from_user(), copy_to_user()) is called with a very large
static byte-count.
But the limit is currently fixed at 100000, which may be fine
for some uses but not for others. For example, this value is
too low for sparse to be used on the git tree where, for example,
some array used to sort the index is cleared with memset().
Change this by making the limit configurable via a new flag:
-fmemcpy-max-count.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
sparse will warn if memcpy() (or memset(), copy_from_user(),
copy_to_user()) is called with a very large static byte-count.
But this warning is given unconditionaly while there are projects
where this warning may not be not desired.
Change this by making this warning conditional on a new warning
flag: -W[no-]memcpy-max-count
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
This was forgotten when adding this option.
Reported-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
The missing ones were:
* init-cstring
* override-init-all
* sizeof-bool
* unknown-attribute
Reported-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
cgcc knows about a few unix OSes but not yet about OSX/darwin.
Fix this by adding the two needed defines to cgcc's specs.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
|
|
Since the original x86-64 support in cgcc
(commit 0fcbcbf4: "Implement x86-64 support in cgcc")
cgcc define some non-reserved identifiers like i386, x86_64, ...
It should not since these are valid identifiers which could be used
for some variable names.
Current versions of gcc only define those prefixed with a double
underscore and cgcc also define those. So ...
Remove the defines of the non-prefixed ones.
Reported-by: Joe Lawrence <joe.lawrence@redhat.com>
Investigated-by: Joe Lawrence <joe.lawrence@redhat.com>
Originally-From: Linus Torvalds <torvalds@linux-foundation.org>
Tested-by: Joe Lawrence <joe.lawrence@redhat.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
This patch fixes several issues when compiling code under s390x
(64bit) with cgcc, e.g.
/usr/include/gnu/stubs.h:8:12: error: unable to open 'gnu/stubs-32.h'
by providing the proper defines.
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Passing the '-Wsparse-error' to cgcc can cause that option to be
passed to the C compiler (usually gcc), if the given source file
does not provoke any sparse warnings, which in turn results in
a failure to compile that file.
In order to avoid passing this sparse option to the compiler, we
add the '-Wsparse-error' option to the regular expression check
in the 'check_only_option' function.
In addition, we replace the plain call to 'die' when sparse exits
with non-zero status (maybe due to -Wsparse-error), with a simple
'exit 1'. This suppresses an 'Died at ./cgcc line 86.' message on
exit from cgcc.
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Capture the c-compiler command, in the $ccom variable, in order to
later invoke the compiler without extraneous command-line options.
In particular, use the $ccom variable in order to cleanly invoke the
compiler when setting the $gcc_base_dir variable.
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Make sparse fail and return an error code if a warning is encountered
and -Werror is specified or a hard error is found. This allows to use
sparse in automated build systems to more easily catch new sparse
warnings.
The validation script is extended to parse the expected output message
for an error message and validate the a non zero return value if such
a error message is found.
Also changes cgcc to die if the checker fails.
Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
GCC defines a macro __SIZEOF_POINTER__ to the size of a pointer in
bytes. Define it in sparse as well.
Signed-off-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Use of uninitialized value $bits in exists at /usr/bin/cgcc line 139.
/usr/bin/cgcc: weird number of bits. at /usr/bin/cgcc line 139.
Signed-off-by: Joel Soete <rubisher@scarlet.be>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Some structure types provide a set of fields of which most users will
only initialize the subset they care about. Users of these types should
always use designated initializers, to avoid relying on the specific
structure layout. Examples of this type of structure include the many
*_operations structures in Linux, which contain a set of function
pointers; these structures occasionally gain a new field, lose an
obsolete field, or change the function signature for a field.
Add a new attribute designated_init; when used on a struct, it tells
Sparse to warn on any positional initialization of a field in that
struct.
The new flag -Wdesignated-init controls these warnings. Since these
warnings only fire for structures explicitly tagged with the attribute,
enable the warning by default.
Includes documentation and test case.
Signed-off-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
sparse's -Wall option turns on all sparse warnings, including those that
many projects will not want; for instance, warnings that enforce
particular stylistic choices, or behavior allowed by a standard but
considered questionable or error-prone. Furthermore, using -Wall means
accepting all future warnings sparse may start issuing, not just those
intentionally turned on by default.
Other compilers like GCC also use -Wall, and interpret it to mean "turn
on a sensible set of warnings". Since sparse exists to emit warnings,
it already defaults to emitting a sensible set of warnings. Many
projects pass the same options to both sparse and the C compiler,
including warning options like -Wall; this results in turning on
excessive amounts of sparse warnings.
cgcc already filtered out -Wall, but many projects invoke sparse
directly rather than using cgcc. Remove that filter, now that -Wall
does not change sparse's behavior.
Projects almost certainly don't want to use the new -Wsparse-all option;
they should choose the specific set of warnings they want, or just go
with sparse's defaults.
Also update cgcc to know about Wsparse-all and not pass it to GCC, and
update a test case that unnecessarily used -Wall.
Signed-off-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
GCC provides a 128 bit type called internally as TImode (__int128_t)on 64 bit
platforms (at least x86_64 and Sparc64). These types are used by OpenBIOS.
Add support for types "long long long", __mode__(TI) and __(u)int128_t.
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Signed-off-by: Christopher Li <sparse@chrisli.org>
|
|
Signed-off-by: Alexey Zaytsev <alexey.zaytsev@gmail.com>
|
|
This patch adds OpenBSD support to sparse.
Acked-by: Christopher Li <sparse@chrisli.org>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
|
|
This patch adds support for Sparc64 (Sparc V9, LP64).
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
|
|
-spesc is just confusing, as gcc takes the same
option for something compeltely different.
Signed-off-by: Alexey Zaytsev <alexey.zaytsev@gmail.com>
|
|
I have a situation here when $(CC) is called with -M options with
slighly different set of -I/-D/etc arguments, which causes all sorts of
funny reports from sparse. Also, this increases the overall build time
because every compilation unit if sparsed twice.
Signed-off-by: Alexander Shishkin <alexander.shishckin@gmail.com>
|
|
I'm not sure this is exactly the right thing to do because I'm
unfamiliar with the default CFLAGS, but it seems to at least make it
mostly work on powerpc.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
|
|
cgcc's regex of Sparse warning options listed -Wundefined-preprocessor,
which doesn't exist; change it to -Wundef.
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
cgcc's regex of Sparse warning options listed -Wcast-to-address-space,
which doesn't exist; change it to -Wcast-to-as.
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Signed-off-by: Yura Pakhuchiy <pakhuchiy@gmail.com>
|
|
Signed-off-by: Pavel Roskin <proski@gnu.org>
|
|
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
|
|
a NULL pointer
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
This patch makes cgcc run on x86-64 machines by extending add_specs().
[original patch]
Signed-off-by: Alberto Bertogli <albertito@gmail.com>
[integer and size_t size fixes, -m32 support]
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Ideally these wouldn't need to exist in more than one place.
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
-Wall turns on all Sparse warnings, including experimental and noisy ones.
Don't include it just because a project wants to pass -Wall to cc. If you
really want cgcc to run sparse with -Wall, use CHECK="sparse -Wall".
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Signed-off-by: Josh Triplett <josh@freedesktop.org>
|
|
Mark it executable, and use "sparse" instead of "check" by default,
since that's what sparse gets installed as.
|
|
Teach check that "-" is stdin.
cgcc:
Teach cgcc that "-" is a file.
|
|
|
|
Handle -U.
cgcc:
Teach cgcc about "-v".
Teach cgcc not to run compiler when "-E" is seen.
Add define for __SIZE_TYPE__.
|
|
|
|
and system in cgcc.
|
|
|
|
|
|
|