diff options
Diffstat (limited to 'build.env')
-rw-r--r-- | build.env | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/build.env b/build.env new file mode 100644 index 0000000..0e8dd8b --- /dev/null +++ b/build.env @@ -0,0 +1,18 @@ +# The toolchain will be installed into PREFIX +export PREFIX=/usr/local/pacman + +# Setup toolchain search paths +export PATH=$PREFIX/bin:$PREFIX/sbin:$PATH +export MANPATH=$PREFIX/share/man:$MANPATH +export PKG_CONFIG_PATH=$PREFIX/lib/pkgconfig + +# Basic compile/link flags +export CFLAGS="-I$PREFIX/include -O2 -pipe" +export LDFLAGS="-L$PREFIX/lib" + +# Use the most basic locale possible +export LANG=C + +# Helper for `make -j` calls +export CPU_COUNT=$(python -c 'import os; print(os.cpu_count())') +if (( CPU_COUNT > 1 )); then (( CPU_COUNT-- )); fi |