OpenCores
URL https://opencores.org/ocsvn/or1200_soc/or1200_soc/trunk

Subversion Repositories or1200_soc

[/] [or1200_soc/] [trunk/] [sw/] [Meansoffreedom/] [__notes.txt] - Blame information for rev 26

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 26 qaztronic
 
2
# cd to or1200_soc/sw/Meansoffreedom
3
 
4
export WORK_ROOT=$PWD
5
 
6
# build binutils
7
tar -xf binutils-2.16.1.tar.bz2
8
cd binutils-2.16.1
9
bzip2 -dc ../binutils_2.16.1_unified.diff_rgd_fixed.bz2 |patch -p1
10
cd ..
11
mkdir b-b
12
mkdir tools
13
cd b-b
14
../binutils-2.16.1/configure --target=or32-uclinux --prefix=$WORK_ROOT/tools/or32-uclinux
15
make all install
16
ls $WORK_ROOT/tools/or32-uclinux/bin
17
export PATH=$WORK_ROOT/tools/or32-uclinux/bin:$PATH
18
cd ..
19
 
20
# first build gcc
21
tar -xf linux-2.6.19.tar.bz2
22
cd linux-2.6.19
23
bzip2 -dc ../linux_2.6.19_or32_unified_simtested.bz2 |patch -p1
24
cd ..
25
mkdir tools/or32-uclinux/include
26
mkdir tools/or32-uclinux/include/asm
27
mkdir tools/or32-uclinux/include/linux
28
cp -f -dR linux-2.6.19/include/linux/* $WORK_ROOT/tools/or32-uclinux/include/linux
29
cp -f -dR linux-2.6.19/include/asm-or32/* $WORK_ROOT/tools/or32-uclinux/include/asm
30
cd $WORK_ROOT/tools/or32-uclinux
31
ln -s include sys-include
32
cd ../../
33
mkdir b-gcc
34
cd gcc-3.4.4
35
bzip2 -dc ../gcc-3.4.4-or32-unified.diff.bz2 |patch -p1
36
cd ../b-gcc
37
../gcc-3.4.4/configure --target=or32-uclinux --prefix=$WORK_ROOT/tools/or32-uclinux --with-localprefix=$WORK_ROOT/tools/or32-uclinux/or32-uclinux --with-gnu-as --with-gnu-ld --verbose --enable-languages=c
38
make all install
39
cd ../linux-2.6.19
40
make vmlinux ARCH=or32 CROSS_COMPILE=$WORK_ROOT/tools/or32-uclinux/bin/or32-uclinux-
41
cd ..
42
 
43
 
44
# build uClibc
45
tar -xf uClibc-0.9.28.3.tar.bz2
46
cd uClibc-0.9.28.3
47
bzip2 -dc ../uClibc-0.9.28-or32-unified.bz2 |patch -p1
48
cd libc
49
bzip2 -dc ../../uClibc-0.9.28-or32-libc-support.bz2 |patch -p1
50
cd ..
51
ln -s extra/Configs/Config.or32 Config
52
export CC=or32-uclinux-gcc
53
cp ../.config ./
54
make all install
55
cd ../
56
unset CC
57
 
58
# second build gcc with C++ hack
59
cd $WORK_ROOT/tools/or32-uclinux/or32-uclinux/
60
ln -s ../include sys-include
61
cd $WORK_ROOT/tools/or32-uclinux/or32-uclinux/lib
62
cp ../../lib/*.* .
63
cp $WORK_ROOT/C_plus_hack/configure.ac $WORK_ROOT/gcc-3.4.4/libstdc++-v3/
64
cp $WORK_ROOT/C_plus_hack/strsignal.c $WORK_ROOT/gcc-3.4.4/libiberty/
65
 
66
cd $WORK_ROOT/b-gcc
67
../gcc-3.4.4/configure --target=or32-uclinux --prefix=$WORK_ROOT/tools/or32-uclinux --with-localprefix=$WORK_ROOT/tools/or32-uclinux/or32-uclinux --with-gnu-as --with-gnu-ld --verbose --with-newlib --enable-languages=c,c++
68
make all install
69
# wait for the build to fail
70
 
71
cp $WORK_ROOT/C_plus_hack/ctype_base.h $WORK_ROOT/b-gcc/or32-uclinux/libstdc++-v3/include/or32-uclinux/bits/
72
cp $WORK_ROOT/C_plus_hack/ctype_noninline.h $WORK_ROOT/b-gcc/or32-uclinux/libstdc++-v3/include/or32-uclinux/bits/
73
make all install
74
# wait for the build to fail
75
 
76
cp $WORK_ROOT/C_plus_hack/c++locale.cc $WORK_ROOT/b-gcc/or32-uclinux/libstdc++-v3/src/
77
make all install
78
# wait for the build to fail
79
 
80
cp /lib/gcc/i686-pc-cygwin/3.4.4/include/c++/i686-pc-cygwin/bits/stdc++.h.gch/* $WORK_ROOT/b-gcc/or32-uclinux/libstdc++-v3/include/or32-uclinux/bits/stdc++.h.gch
81
make all install
82
 
83
cd $WORK_ROOT/tools/or32-uclinux/or32-uclinux
84
ln -s ../include sys-include
85
cd lib
86
cp ../../lib/*.* .
87
 
88
# done. test it.
89
cd $WORK_ROOT/../ecos_debug
90
export PATH=$WORK_ROOT/tools/or32-uclinux/bin:$WORK_ROOT/../ecos-3.0/tools/bin:$PATH
91
export ECOS_REPOSITORY=$WORK_ROOT/../ecos-3.0/packages
92
ecosconfig new OR1200_SOC redboot
93
ecosconfig import ./ecos_debug.ecm
94
ecosconfig tree
95
make
96
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.