blob: f785fac07bcc59058cb7a0d30a9ca2caee24ef01 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
#!/bin/env bash
set -e
PATH=/opt/bootstrap/bin:/opt/toolchain/bin:$PATH
mkdir -p /toolchain/newlib/.build && cd /toolchain/newlib
tar xf /downloads/newlib-$NEWLIB_VERSION.tar.gz
cd .build
LDFLAGS=-mno-red-zone ../newlib-$NEWLIB_VERSION/configure \
--disable-newlib-fseek-optimization \
--disable-newlib-io-float \
--disable-newlib-supplied-syscalls \
--disable-nls \
--disable-werror \
--prefix=/opt/toolchain \
--target=$TARGET \
CFLAGS_FOR_TARGET="-mcmodel=kernel -fno-pie"
make -j$(nproc)
make install
|