summaryrefslogtreecommitdiffstats
path: root/tools/build.sh
blob: bd783caf5a8bdeaa4cbeeabb9b490d1913e06d8f (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/sh -xe
here="$(pwd)"
cpus=2

PATH="$here"/bin:"$PATH"
export PATH

rm -rf build bin lib lib64 libexec share m68k-none-elf
mkdir build

cd build
mkdir binutils gcc

cd binutils
../../src/binutils/configure --prefix="$here" --target=m68k-none-elf \
    --disable-libssp --disable-werror
make -j$cpus
make install

cd ../gcc
../../src/gcc/configure --prefix="$here" --target=m68k-none-elf \
    --disable-libssp --disable-werror --enable-languages=c
make -j$cpus
make install