mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-06 19:28:29 +00:00
Implement more toolchain fixes
This commit is contained in:
parent
0409096658
commit
226375933a
35 changed files with 69 additions and 31 deletions
|
@ -67,6 +67,7 @@ EOF
|
|||
exit 0
|
||||
fi
|
||||
|
||||
ORIGINAL="$0 $*"
|
||||
PLATFORM="-D__COSMOPOLITAN__"
|
||||
PREDEF="-include libc/integral/normalize.inc"
|
||||
CCFLAGS="-fdata-sections -ffunction-sections -fno-pie -mno-tls-direct-seg-refs -mno-red-zone -fportcosmo"
|
||||
|
@ -131,6 +132,8 @@ for x; do
|
|||
# this toolchain is intended for building other people's code
|
||||
# we don't need the compiler's assistance to be more portable
|
||||
continue
|
||||
elif [ x"$x" = x"-static-libgcc" ]; then
|
||||
continue
|
||||
elif [ x"$x" != x"${x#-O}" ]; then
|
||||
OPT=$x
|
||||
elif [ x"$x" = x"-c" ]; then
|
||||
|
@ -161,7 +164,7 @@ for x; do
|
|||
done
|
||||
|
||||
if [ $RELOCATABLE -eq 1 ]; then
|
||||
APEFLAGS=
|
||||
APEFLAGS="-r"
|
||||
fi
|
||||
|
||||
if [ x"$MODE" = x"nox87" ]; then
|
||||
|
@ -183,7 +186,7 @@ else
|
|||
fi
|
||||
|
||||
set -- "$CC" "$@"
|
||||
printf '(cd %s; %s)\n' "$PWD" "$*" >>/tmp/build.log
|
||||
printf '# %s\n(cd %s; %s)\n' "$ORIGINAL" "$PWD" "$*" >>/tmp/build.log
|
||||
"$@" || exit
|
||||
|
||||
if [ -n "$OUTPUT" ] && [ -f "$OUTPUT" ]; then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue