1# Toybox configuration file. 2 3# This sets environment variables used by scripts/make.sh 4 5# A synonym. 6[ -z "$CROSS_COMPILE" ] && CROSS_COMPILE="$CROSS" 7 8# CFLAGS and OPTIMIZE are different so you can add extra CFLAGS without 9# disabling default optimizations 10[ -z "$CFLAGS" ] && CFLAGS="-Wall -Wundef -Wno-char-subscripts" 11# Required for our expected ABI. we're 8-bit clean thus "char" must be unsigned. 12CFLAGS="$CFLAGS -funsigned-char" 13[ -z "$OPTIMIZE" ] && OPTIMIZE="-Os -ffunction-sections -fdata-sections -fno-asynchronous-unwind-tables" 14 15# We accept LDFLAGS, but by default don't have anything in it 16[ -z "$LDOPTIMIZE" ] && LDOPTIMIZE="-Wl,--gc-sections" 17 18[ -z "$CC" ] && CC=cc 19 20# If HOSTCC needs CFLAGS or LDFLAGS, just add them to the variable 21# ala HOSTCC="blah-cc --static" 22[ -z "$HOSTCC" ] && HOSTCC=gcc 23