[PATCH v2 05/10] user: Add "Install the Tool Suite" section

Sebastian Huber sebastian.huber at embedded-brains.de
Mon Jan 28 12:27:07 UTC 2019


---
 user/hardware/architectures.rst |   3 +
 user/start/index.rst            |   1 +
 user/start/tools.rst            | 126 ++++++++++++++++++++++++++++++++++++++++
 3 files changed, 130 insertions(+)
 create mode 100644 user/start/tools.rst

diff --git a/user/hardware/architectures.rst b/user/hardware/architectures.rst
index 5328db8..761258f 100644
--- a/user/hardware/architectures.rst
+++ b/user/hardware/architectures.rst
@@ -4,8 +4,11 @@
 .. Copyright (C) 2019 Sebastian Huber
 .. Copyright (C) 2016 Chris Johns <chrisj at rtems.org>
 
+.. _TargetArchitectures:
+
 Architectures
 =============
+
 .. index:: Architectures
 
 An RTEMS architecture is a class or family of a processor architecture that
diff --git a/user/start/index.rst b/user/start/index.rst
index d5f21e7..2bee850 100644
--- a/user/start/index.rst
+++ b/user/start/index.rst
@@ -19,6 +19,7 @@ applications on top of RTEMS.
     host
     prefixes
     sources
+    tools
 
 The following is a quick start guide that provides a basic set of commands to
 build the RTEMS Tools and Kernel. The quick start guide provides links to the
diff --git a/user/start/tools.rst b/user/start/tools.rst
new file mode 100644
index 0000000..1be229a
--- /dev/null
+++ b/user/start/tools.rst
@@ -0,0 +1,126 @@
+.. SPDX-License-Identifier: CC-BY-SA-4.0
+
+.. Copyright (C) 2019 embedded brains GmbH
+.. Copyright (C) 2019 Sebastian Huber
+
+.. _QuickStartTools:
+
+Install the Tool Suite
+======================
+
+You chose an installation prefix and cloned two RTEMS repositories in the
+previous sections.  We chose :file:`$HOME/quick-start/rtems/5` as the
+installation prefix and cloned the repositories in
+:file:`$HOME/quick-start/src`.
+
+You must select the
+:ref:`target architecture <TargetArchitectures>` for which you need a tool
+suite.  In this quick start chapter we choose `sparc-rtems5`.  The
+`sparc-rtems5` is the tool suite name for the SPARC architecture and RTEMS
+version 5.  The tool suite for RTEMS and the RTEMS sources are tightly coupled.
+For example, do not use a RTEMS version 5 tool suite with RTEMS version 4.11
+sources and vice versa.  We use the RSB in two steps.  The first step is to
+download additional sources and patches.  Afterwards, you could disconnect your
+host computer from the internet.  It is no longer required to work with RTEMS.
+
+.. code-block:: none
+
+    cd $HOME/quick-start/src/rsb/rtems
+    ../source-builder/sb-set-builder --source-only-download 5/rtems-sparc
+
+This command should output something like this (omitted lines are denoted by
+...):
+
+.. code-block:: none
+
+    RTEMS Source Builder - Set Builder, 5 (f07504d27192)
+    warning: exe: absolute exe found in path: (__unzip) /usr/local/bin/unzip
+    Build Set: 5/rtems-sparc
+    ...
+    download: https://ftp.gnu.org/gnu/gcc/gcc-7.4.0/gcc-7.4.0.tar.xz -> sources/gcc-7.4.0.tar.xz
+    ...
+    Build Sizes: usage: 0.000B total: 140.576MB (sources: 140.230MB, patches: 353.696KB, installed 0.000B)
+    Build Set: Time 0:02:24.309020
+
+If you encounter errors in the first step, check your internet connection,
+firewall settings, virus scanners and the availability of the download servers.
+The seconds step is to build and install the tool suite.
+
+.. code-block:: none
+
+    cd $HOME/quick-start/src/rsb/rtems
+    ../source-builder/sb-set-builder --prefix=$HOME/quick-start/rtems/5 5/rtems-sparc
+
+This command should output something like this (omitted lines are denoted by
+...):
+
+.. code-block:: none
+
+    RTEMS Source Builder - Set Builder, 5 (f07504d27192)
+    warning: exe: absolute exe found in path: (__unzip) /usr/local/bin/unzip
+    Build Set: 5/rtems-sparc
+    ...
+    config: tools/rtems-gcc-7.4.0-newlib-dc6e94551f09d3a983afd571478d63a09d6f66fa.cfg
+    package: sparc-rtems5-gcc-7.4.0-newlib-dc6e94551f09d3a983afd571478d63a09d6f66fa-x86_64-freebsd12.0-1
+    building: sparc-rtems5-gcc-7.4.0-newlib-dc6e94551f09d3a983afd571478d63a09d6f66fa-x86_64-freebsd12.0-1
+    sizes: sparc-rtems5-gcc-7.4.0-newlib-dc6e94551f09d3a983afd571478d63a09d6f66fa-x86_64-freebsd12.0-1: 4.714GB (installed: 890.736MB)
+    cleaning: sparc-rtems5-gcc-7.4.0-newlib-dc6e94551f09d3a983afd571478d63a09d6f66fa-x86_64-freebsd12.0-1
+    ...
+    Build Sizes: usage: 5.692GB total: 1.116GB (sources: 140.230MB, patches: 353.696KB, installed 1001.778MB)
+    Build Set: Time 0:22:00.360146
+
+In case the seconds step was successful, you can check if for example the cross
+C compiler works with the following command:
+
+.. code-block:: none
+
+    $HOME/quick-start/rtems/5/bin/sparc-rtems5-gcc --version --verbose
+
+This command should output something like below.  In this output the actual
+prefix path was replaced by ``$PREFIX``.  The ``compiled by`` line depends on
+the native C++ compiler of your host computer.  In the output you see the Git
+hash of the RSB.  This helps you to identify the exact sources which were used
+to build the cross compiler of your RTEMS tool suite.
+
+.. code-block:: none
+
+    Using built-in specs.
+    COLLECT_GCC=$PREFIX/bin/sparc-rtems5-gcc
+    COLLECT_LTO_WRAPPER=$PREFIX/bin/../libexec/gcc/sparc-rtems5/7.4.0/lto-wrapper
+    sparc-rtems5-gcc (GCC) 7.4.0 20181206 (RTEMS 5, RSB f07504d27192d9f76d782bf04bf10a08644a898c, Newlib dc6e94551f09d3a983afd571478d63a09d6f66fa)
+    Copyright (C) 2017 Free Software Foundation, Inc.
+    This is free software; see the source for copying conditions.  There is NO
+    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+
+
+    Target: sparc-rtems5
+    Configured with: ../gcc-7.4.0/configure ...
+    Thread model: rtems
+    gcc version 7.4.0 20181206 (RTEMS 5, RSB f07504d27192d9f76d782bf04bf10a08644a898c, Newlib dc6e94551f09d3a983afd571478d63a09d6f66fa) (GCC) 
+    COLLECT_GCC_OPTIONS='--version' '-v' '-mcpu=v7'
+     $PREFIX/bin/../libexec/gcc/sparc-rtems5/7.4.0/cc1 -quiet -v -iprefix $PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/ help-dummy -quiet -dumpbase help-dummy -mcpu=v7 -auxbase help-dummy -version --version -o /tmp//cc9u2Ohj.s
+    GNU C11 (GCC) version 7.4.0 20181206 (RTEMS 5, RSB f07504d27192d9f76d782bf04bf10a08644a898c, Newlib dc6e94551f09d3a983afd571478d63a09d6f66fa) (sparc-rtems5)
+            compiled by GNU C version 4.2.1 Compatible FreeBSD Clang 6.0.1 (tags/RELEASE_601/final 335540), GMP version 6.1.0, MPFR version 3.1.4, MPC version 1.0.3, isl version isl-0.16.1-GMP
+
+    GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
+    COLLECT_GCC_OPTIONS='--version' '-v' '-mcpu=v7'
+     $PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/bin/as -v -s --version -o /tmp//cc9GAkXG.o /tmp//cc9u2Ohj.s
+    GNU assembler version 2.31.1 (sparc-rtems5) using BFD version (GNU Binutils) 2.31.1
+    GNU assembler (GNU Binutils) 2.31.1
+    Copyright (C) 2018 Free Software Foundation, Inc.
+    This program is free software; you may redistribute it under the terms of
+    the GNU General Public License version 3 or later.
+    This program has absolutely no warranty.
+    This assembler was configured for a target of `sparc-rtems5'.
+    COMPILER_PATH=$PREFIX/bin/../libexec/gcc/sparc-rtems5/7.4.0/:$PREFIX/bin/../libexec/gcc/:$PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/bin/
+    LIBRARY_PATH=$PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/:$PREFIX/bin/../lib/gcc/:$PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/lib/
+    COLLECT_GCC_OPTIONS='--version' '-v' '-mcpu=v7'
+     $PREFIX/bin/../libexec/gcc/sparc-rtems5/7.4.0/collect2 --version $PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/lib/crt0.o -L$PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0 -L$PREFIX/bin/../lib/gcc -L$PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/lib /tmp//cc9GAkXG.o -lgcc -lc -lgcc
+    collect2 version 7.4.0 20181206 (RTEMS 5, RSB f07504d27192d9f76d782bf04bf10a08644a898c, Newlib dc6e94551f09d3a983afd571478d63a09d6f66fa)
+    $PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/bin/ld --version $PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/lib/crt0.o -L$PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0 -L$PREFIX/bin/../lib/gcc -L$PREFIX/bin/../lib/gcc/sparc-rtems5/7.4.0/../../../../sparc-rtems5/lib /tmp//cc9GAkXG.o -lgcc -lc -lgcc
+    GNU ld (GNU Binutils) 2.31.1
+    Copyright (C) 2018 Free Software Foundation, Inc.
+    This program is free software; you may redistribute it under the terms of
+    the GNU General Public License version 3 or (at your option) a later version.
+    This program has absolutely no warranty.
+    COLLECT_GCC_OPTIONS='--version' '-v' '-mcpu=v7'
-- 
2.16.4



More information about the devel mailing list