-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhowto.txt
69 lines (53 loc) · 1.7 KB
/
howto.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
===================================================================================================
OPENBIOS COMPILATION
---------------------
export TARGET=sparc-elf-
export PREFIX= <<the install directory of the cross compiler>>
export PATH=$PATH:$PREFIX/bin
chmod 755 ./config/scripts/switch-arch
./config/scripts/switch-arch tacus-sparc32
make build-verbose
cd obj-sparc32
sparc-elf-objcopy -O srec openbios-builtin.elf openbios-builtin.srec
sparc-elf-objcopy -O binary openbios-builtin.elf openbios.bin
sed 's/S3\(..\)FFD/S3\1F00/' openbios-builtin.srec >obios.sr
mv -f obios.sr ../../
mv -f openbios.bin ../../boot.rom
cd ..
cd ..
===================================================================================================
CROSS-COMPILER
---------------
Dependencies :
lib64gmp-devel
lib64mpfr-devel
lib64mpc-devel
export TARGET=sparc-elf
export PREFIX=/home/za/dev/ss/comp
export PATH=$PATH:$PREFIX/bin
mkdir build-binutils
cd build-binutils
../binutils-2.37.90/configure --target=$TARGET --prefix=$PREFIX
make all -j4
make install
cd ..
mkdir build-gcc
cd build-gcc
../gcc-11.2.0/configure --target=$TARGET --prefix=$PREFIX --without-headers --with-newlib --with-gnu-as --with-gnu-ld
make all-gcc -j4
make install-gcc
cd ..
mkdir build-newlib
cd build-newlib
../newlib-4.2.0.20211231/configure --target=$TARGET --prefix=$PREFIX
make all -j4
make install -j4
make all-target -j4
make all-host -j4
make install-target
cd ..
cd build-gcc
../gcc-11.2.0/configure --target=$TARGET --prefix=$PREFIX --with-newlib --with-gnu-as --with-gnu-ld --disable-shared --disable-libssp
make all -j4
make install
===================================================================================================