FENIX_main/config.sh

28 lines
589 B
Bash
Raw Normal View History

2021-01-31 20:08:26 +00:00
SYSTEM_HEADER_PROJECTS="libc kernel"
PROJECTS="libc kernel"
export MAKE=${MAKE:-make}
export HOST=${HOST:-$(./default-host.sh)}
export AR=${HOST}-ar
export AS=${HOST}-as
export CC=${HOST}-gcc
export PREFIX=/usr
export EXEC_PREFIX=$PREFIX
export BOOTDIR=/boot
export LIBDIR=$EXEC_PREFIX/lib
export INCLUDEDIR=$PREFIX/include
2022-11-12 20:53:01 +00:00
export CFLAGS='-O2 -g -Wall'
2021-01-31 20:08:26 +00:00
export CPPFLAGS=''
# Sysroot time!
export SYSROOT="$(pwd)/sysroot"
export CC="$CC --sysroot=$SYSROOT"
# A workaround for -elf gcc targets
if echo "$HOST" | grep -Eq -- '-elf($|-)'; then
export CC="$CC -isystem=$INCLUDEDIR"
fi