mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-13 18:17:39 -04:00
Don't force gcc as host compiler + fix clang warnings
On MacOS, gcc is a symlink for clang. Patch gets rid of the warnings produced by clang, when it is set as HOSTCC, and fixes voicetools compilation on MacOS when calling make voicetools from the simulator directory. lua rb_defines_helper: format specifies type 'int' but the argument has type 'long' codecs: opus / speex (LOGF): format '%ld' expects argument of type 'long int', but argument 7 has type 'off_t' gigabeat: variable 'size' set but not used rdf2binary: a function declaration without a prototype is deprecated in all versions of C rbspeexdec: passing 'unsigned char *' to parameter of type 'char *' converts between pointers to integer types where one is of the unique plain 'char' type and the other is not hmac-sha1.c defining a type within 'offsetof' is a Clang extension Change-Id: I90539906698868f9589650585d865aee9f7e8539
This commit is contained in:
parent
a86b1999d0
commit
727c800c0d
8 changed files with 25 additions and 33 deletions
9
tools/configure
vendored
9
tools/configure
vendored
|
@ -16,9 +16,6 @@ LDOPTS=""
|
|||
GLOBAL_LDOPTS=""
|
||||
LDMAP_OPT="-Map"
|
||||
|
||||
HOSTCC=gcc
|
||||
HOSTAR=ar
|
||||
|
||||
extradefines=""
|
||||
use_logf="#undef ROCKBOX_HAS_LOGF"
|
||||
use_bootchart="#undef DO_BOOTCHART"
|
||||
|
@ -398,9 +395,7 @@ simcc () {
|
|||
if $CC --version | grep -q "clang"; then
|
||||
echo "[Warning] Clang compiler ($CC) in your path is unsupported. Trying gcc-14."
|
||||
CC=gcc-14
|
||||
HOSTCC=gcc-14
|
||||
AR=gcc-ar-14
|
||||
HOSTAR=gcc-ar-14
|
||||
CPP=cpp-14
|
||||
fi
|
||||
LDOPTS="$LDOPTS -ldl"
|
||||
|
@ -4612,8 +4607,8 @@ else
|
|||
fi
|
||||
|
||||
# figure out the full path to the various commands if possible
|
||||
HOSTCC=`findtool ${HOSTCC} --lit`
|
||||
HOSTAR=`findtool ${HOSTAR} --lit`
|
||||
HOSTCC=`findtool gcc --lit`
|
||||
HOSTAR=`findtool ar --lit`
|
||||
CC=`findtool ${CC} --lit`
|
||||
CPP=`findtool ${CPP} --lit`
|
||||
LD=`findtool ${LD} --lit`
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue