source: rtems/doc/started/buildrt.t @ ae2e9f2

4.104.114.84.95
Last change on this file since ae2e9f2 was ae2e9f2, checked in by Joel Sherrill <joel.sherrill@…>, on 04/14/98 at 21:17:53

"arc" changed to "archive"

Pictures now in ASCII.

  • Property mode set to 100644
File size: 3.1 KB
Line 
1@c
2@c
3@c  COPYRIGHT (c) 1988-1998.
4@c  On-Line Applications Research Corporation (OAR).
5@c  All rights reserved.
6@c
7@c  $Id$
8@c
9
10@chapter Building RTEMS
11
12@section Unpack the RTEMS Source
13
14Use the following command sequence to unpack the RTEMS source into the
15tools directory:
16
17@example
18cd tools
19tar xzf ../archive/@value{RTEMS-TAR}
20@end example
21
22@section Add <INSTALL_POINT>/bin to Executable PATH
23
24In order to compile RTEMS, you must have the cross compilation toolset
25in your search patch.  The following command appends the directory
26where the tools were installed in the previous chapter:
27
28@example
29export PATH=$PATH:<INSTALL_POINT>/bin
30@end example
31
32NOTE:  The above command is in Bourne shell (@code{sh}) syntax and
33should work with the Korn (@code{ksh}) and GNU Bourne Again Shell
34(@code{bash}).  It will not work with the C Shell (@code{csh}) or
35derivatives of the C Shell.
36
37@section Verifying the Operation of the Cross Toolset
38
39In order to insure that the cross-compiler is invoking the correct
40subprograms (like @code{as} and @code{ld}), one can test assemble
41a small program.  When in verbose more, @code{gcc} prints out information
42showing where it found the subprograms it invokes.  Place the following
43function in a file named @code{f.c}:
44
45@example
46int f( int x )
47@{
48  return x + 1;
49@}
50@end example
51
52Then assemble the file using a command similar to the following:
53
54@example
55m68k-rtems-gcc -v -S f.c
56@end example
57
58Where @code{m68k-rtems-gcc} should be changed to match the installed
59name of your cross compiler.  The result of this command will be
60a sequence of output showing where the cross-compiler searched for
61and found its subcomponents.  Verify that these paths correspond
62to your <INSTALL_POINT>.
63
64@b{NOTE:} One of the most common installation errors is for the
65cross-compiler not to be able to find the cross assembler and default
66to using the native @code{as}.  This can result in very confusing
67error messages.
68
69@section Generate RTEMS for a Specific Target and BSP
70
71Make a build directory under tools and build the RTEMS product in this
72directory. The ../@value{RTEMS-UNTAR}/configure
73command has numerous command line
74arguments. These arguments are discussed in detail in documentation that
75comes with the RTEMS distribution. In the installation described in the
76section "Unpack the RTEMS source", these configuration options can be found
77in file tools/@value{RTEMS-UNTAR}/README.configure.
78
79The following shows the command sequence required to configure,
80compile, and install RTEMS with the POSIX API, KA9Q TCP/IP,
81and C++ support disabled.  RTEMS will be built to target
82the @code{BOARD_SUPPORT_PACKAGE} board.
83
84@example
85mkdir build-rtems
86cd build-rtems
87../@value{RTEMS-UNTAR}/configure --target=<TARGET_CONFIGURATION> \
88    --disable-posix --disable-ka9q --disable-cxx \
89    --enable-rtemsbsp=<BOARD_SUPPORT_PACKAGE>\
90    --prefix=<INSTALL_POINT>
91gmake all install
92@end example
93
94Where the list of currently supported of <TARGET_CONFIGURATION>'s and
95<BOARD_SUPPORT_PACKAGE>'s can be found in
96tools/@value{RTEMS-UNTAR}/README.configure.
97
98<INSTALL_POINT> is the installation point from the previous step
99"Modify the bit script" in the build of the tools.
100
101
Note: See TracBrowser for help on using the repository browser.