Download clean versions of the distribution and the three patch files for OpenRISC 1000 from the locations given in Section 2.3.
Important | |
---|---|
Ensure the version number (0.9.28.3) is exactly the same. |
Unpack the downloaded source code. Apply the main MOF patch to the
main uClibc directory (See Section 3.1.1 for an example
of how to apply a patch file.). Apply the supplementary MOF
patch file to the libc
sub-directory of the
uClibc directory not the main directory.
A further patch is required to ensure uClibc will work correctly
with the OpenRISC tool chain. The linker can get confused about the
stdio
library initialization and termination. To avoid this, dummy
versions of __stdio_init
and
__stdio_term
must be added. Apply the
Embecosm patch file to the main directory to fix these problems.
The patches must be applied in this order. A typical set of commands would be:
cd uClibc-0.9.28.3 bzcat -dc ../uClibc-0.9.28-or32-unified.bz2 | patch -p1 cd libc bzcat -dc ../../uClibc-0.9.28-or32-libc-support.bz2 | patch -p1 cd .. bzcat -dc ../embecosm-esp2-or32-uclibc-0.9.28.3-patch-2.0.bz2 | patch -p1