source: rtems-source-builder/rtems/config/tools/rtems-tools-common-1.cfg @ 8db33fb

5
Last change on this file since 8db33fb was 8db33fb, checked in by Chris Johns <chrisj@…>, on 07/11/19 at 22:25:15

rtems: Add kernel, libbsd and BSP building as packages.

  • Property mode set to 100644
File size: 1.4 KB
Line 
1#
2# RTEMS Tools Version 2.
3#
4# This configuration file configure's, builds and install's RTEMS Tools.
5#
6
7Name:      rtems-tools-%{rtems_tools_version}-%{release}
8Summary:   RTEMS Tools %{rtems_tools_version} for host %{_host}
9Version:   %{rtems_tools_version}
10Release:   %{release}
11URL:       http://www.rtems.org/
12License:   BSD-2-Clause + GPL-2.0
13
14#
15# Prepare the source code.
16#
17%prep
18  # save the build top directory and cd back to it rather than
19  # using 'cd ..' because some shells change $PWD to a symlink's
20  # target location and 'cd ..' fails.
21  build_top=$(pwd)
22
23  %if ! %{defined rtems_tools_source}
24    %if %{rsb_released}
25      rtems_tools_source="rtems-tools-%{rtems_tools_version}"
26    %else
27      rtems_tools_source="rtems-tools.git"
28    %endif
29  %else
30    rtems_tools_source=%{rtems_tools_source}
31  %endif
32
33  source_dir_rtems_tools=${rtems_tools_source}
34  %source setup rtems-tools -q -n ${rtems_tools_source}
35  %patch setup rtems-tools -p1
36
37  cd ${build_top}
38
39%build
40  build_top=$(pwd)
41
42  #
43  # Provide the host for a Cxc build.
44  #
45  if test "%{_build}" != "%{_host}" ; then
46    RT_HOST="--host=%{_host}"
47  else
48    RT_HOST=
49  fi
50
51  cd ${source_dir_rtems_tools}
52  ./waf distclean configure ${RT_HOST} --prefix=%{_prefix}
53  ./waf
54  cd ${build_top}
55
56%install
57  build_top=$(pwd)
58
59  %{__rmdir} $SB_BUILD_ROOT
60
61  cd ${source_dir_rtems_tools}
62  ./waf --destdir=$SB_BUILD_ROOT%{rtems_waf_build_root_suffix} install
63  cd ${build_top}
Note: See TracBrowser for help on using the repository browser.