67 Commits

Author SHA1 Message Date
Chris Johns
828feec622 sb/setbuilder: Correctly create build set tar files
- Make a single tarfile for all buildsets built

- Use the staging tree as the tarfile source

- Use python's tarfile module

- Create a config.file object without loading a .cfg file

Updates #4716
2022-09-16 09:11:52 +10:00
Chris Johns
0253d81ad2 sb/config: Correctly handle multiple config paths
- Add rtems/config to the config directories searched to better
  support deployment

- Correctly expand the configdir and path searchs

Updates #4716
2022-09-14 17:21:21 +10:00
Chris Johns
6116d9c872 sb: Back port fixes from the development branch
Updates #4716
2022-09-08 15:47:40 +10:00
Ricardo Cárdenes
e5aa419d35 sb/config.py: Fix operator reconstruction
Close #4337
2021-03-11 09:54:13 -07:00
Vijay Kumar Banerjee
d638f2b9a0 sb/config.py: Fix relational operator
Close #4330
2021-03-10 11:47:36 -07:00
Anders Montonen
0c7965c093 sb: Fix Python literal comparison warnings
Fixes:
SyntaxWarning: "is" with a literal. Did you mean "=="?

Signed-off-by: Anders Montonen <Anders.Montonen@iki.fi>
2020-04-28 08:49:05 +10:00
Chris Johns
4295d3d377 sb/config: Add paths checks to %{path ...}
Updates #3893
2020-03-03 11:18:05 +11:00
Chris Johns
175ce0bcb0 sb/config: Expanded nested shell commands
Updates #3893
2020-03-03 11:18:05 +11:00
Chris Johns
9b5017f898 sb/config: Add support for line continuation.
- Add line continuation support so empty macros can be used at
  the end of configure command lines, ie RTEMS kernel. The
  config parser removes empty lines and wihout this support a
  trailing line continuation character joins a configure command
  line to next command.

- Fix freetype's gmake support for non-GNU operating systems.
2019-10-27 08:17:23 +11:00
Chris Johns
d8b2719ae6 sb/config: Escape double quotes on Windows for shell macros
Closes #3792
2019-09-06 11:49:28 +10:00
Chris Johns
b90b749f23 sb/config: Add triplet processing command. 2019-07-21 21:09:34 +10:00
Chris Johns
8db33fbe43 rtems: Add kernel, libbsd and BSP building as packages. 2019-07-21 21:09:34 +10:00
Chris Johns
8922c8bbb0 sb/config: Fix GDB probes when using python-config.
- Fix the config file handling of shell calls where the shell
  command has nesting braces.
- Fix the bool check to support a '!' next to the check value.
2019-07-21 21:09:34 +10:00
Chris Johns
0956a2c089 sb/config: Fix os and arch conditional logic.
Correctly split the argument list and check each element.

Closes #3743
2019-05-07 09:13:12 +10:00
Chris Johns
13f4c37999 sb: Add support to search for a suitable version of python.
The command python has been removed from upstream python and python2
and python3 is now used. This patch wraps the commands in a shell
script that locates a suitable python to run.

Updates #3537
2018-10-21 09:49:02 +11:00
Chris Johns
38fd56c8a8 sb: Monitor the build disk usage. Report the usage, total and various sizes
- Track the size of a build of a package in a build set to determine the
  maximum amout of disk space used. This can be used as a guide to
  documenting how much space a user needs to set aside to build a specific
  set of tools.

- The `%clean` stage of a build is now split into a separate script.
  I do not think this is an issue because I could not find any `%clean`
  sections in any build configs we have. In time support for the
  `%clean` section will be removed, the package builder cleans up.

Closes #3516
2018-09-28 07:36:49 +10:00
Chris Johns
162cbda055 sb/config: Terminate building on an error.
This changes the previous functionality where the RSB switch to
dry run mode. This functionality can be enabled by adding
`--keep-going`.

Close #3209.
2018-04-10 17:59:48 +10:00
Chris Johns
e02139d4ab sb: Fix 'bare' builds with --trace. 2017-06-26 09:28:07 +10:00
Chris Johns
c98555c5f2 sb: Do not filter -f options from a BSP. 2016-04-15 11:59:30 +10:00
Chris Johns
29819a2719 sb: fix the if logic to handle directives in if statements.
Directives in if statements end at the end of an if. The cannot
change or split across directive boundaries.

Add more trace detail to config.py.

Updates #2661.
2016-03-19 17:25:34 +11:00
Chris Johns
721fbe05a1 sb: Fix vairable type in _if.
Updates #2655.
2016-03-18 14:41:03 +11:00
Chris Johns
eb252061aa sb: Fix op parsing bug where the string was not created.
Updates #2655.
2016-03-18 14:41:03 +11:00
Chris Johns
8bde727065 sb: Fix %if logical OP parsing.
Updates #2655.
2016-03-18 10:45:28 +11:00
Chris Johns
db8ec8c99e bare: Update qemu package source hashes that are missing.
Add support for pkgconfig checks to fail when just downloading the
source so it is actually downloaded on hosts that may have a package
installed.

Updates #2657.
2016-03-17 18:30:13 +11:00
Chris Johns
38ed59a301 sb: Support --dry-run --with-download for 3rd party RTEMS BSP packages.
The building of 3rd party packages for an RTEMS BSP requires a valid
BSP so the standard method to download the source for releasing does
not work. This change adds support to allow this. The RTEMS BSP support
will not generate an error is no BSP or tools are provided or found.

The change addis logic operators to the %if statement so you can '||'
to 'or' and '&&' to 'and' logic expressions.

A new %log directive has been added to clean up the messages.

A new %{!define ...} has been added to aid checking within logic
expressions.

All command line --with/--without now appear as macros.

Add version.version to get just the RTEMS major and minor version.

Some pkg-config issues have been resolved.

Closes #2655.
2016-03-17 16:50:05 +11:00
Chris Johns
3a972f6102 sb: Update code base to support Python3 and Python2.
Fix Windows support to allow MSYS2 Python to be used.

Updates #2619.
2016-03-07 15:02:58 +11:00
Chris Johns
27a934e46c Remove the warning when undefining an undefined macro. 2015-12-11 16:31:05 +11:00
Chris Johns
6444d5806d Canandian Cross Compiling and RTEMS 3rd party package building Fixes.
The change fixes installing for RTEMS 3rd Party packages where the
RSB considered them Canadian Cross Compiling (Cxc). Fixing the
Cxc issue broke real Cxc builds. The change corrects the issue of
macros being changed in the Cxc and the prep data not being udpated.
The configuration is loaded again after the updated macros. The
macros are also copied and restored to ensure a clean stable base.

The change also introduces --rtems-tools and --rtems-bsp to align
the command line with the waf configure process or RTEMS application.
2015-07-20 13:49:42 +10:00
Chris Johns
99768016de sb: Expand each data line. 2015-06-05 16:58:29 +10:00
Chris Johns
2b4cd57ed8 sb: Fix the if logic for parameters. 2014-08-23 13:26:24 +00:00
Chris Johns
257d1e4378 rtems-4.11: Fix building the SPARC simulator.
Add support for simulator options to enable special features of
some gdb simulators.
2014-08-21 22:40:47 +10:00
Chris Johns
a083b52921 Add checksum support for downloaded files.
File download by http, ftp, pw support checksum. The %hash
directive provides a means of setting a hash used to
checksum the file.

Files on disk or just downloaded are checked.
2014-07-29 16:35:43 +10:00
Chris Johns
62cb64747f sb: Trace relative paths for nesting configs. 2014-06-17 10:58:30 +12:00
Chris Johns
0ffee19316 sb: Add support for building RTEMS 3rd party packages.
Remove the 'opt' from various macros and shell variables.

Add pkgconfig to the checks to make it clear the check is a
pkgconfig check.

Add NTP support as the first package to be built using the RSB.

Split the RTEMS URL's out from the base bset file into a separate
file that be included by other files.

Add an RTEMS BSP configuration file to help abstract the process
of building 3rd party packages.

Clean the cross and canadian cross support up so we can cleanly support
cross and canadian cross building.

Refactor the pkgconfig support and clean up the PC file handling of
loading modules.

Add support for %{?..} to return false if a macro is %{nil}.

Add %{pkgconfig ..} support to allow better control of access RTEMS
pkgconfig files.
2014-06-15 17:40:34 +12:00
Chris Johns
9a15c40e1b sb: Implement %source and %patch to manage source and patches.
Remove the numbered source and patches and automatically manage
sources and patches. This removes the overhead in maintaining large
collections of patches.
2014-05-13 23:26:09 +10:00
Chris Johns
f3b549010d config,sb: Qemu build updates for FreeBSD and the start of MinG32.
Hack round the FreeBSD iconv support in Freebsd 10. In 10 libc now
supports iconv however iconv.h is present under /usr/local.

Start to add support to build qemu for MinGW via a Cxc. This is a
work in progress and contains lots of hidden traps.

In config.py separate out of the canadian build status.
2014-04-08 15:11:00 +10:00
Chris Johns
c5b5493c19 config: Change pkgconfig to check.
Add the extra actions: ccflags, cflags, ldflags and libs to allow the
fetching of these from pkg-config files.
2014-02-11 14:06:45 +11:00
Chris Johns
c4fefdeb55 sb: Add pkg-config support.
Add a pkg-config look alike command so packages that use pkg-config can
build if pkg-config is not present on a host.

Add support to query package config from configuration scripts.
2014-02-11 10:18:35 +11:00
Chris Johns
7a691b8280 sb: Fix the config _parse args. 2013-09-03 08:50:06 +10:00
Chris Johns
845e92ffce sb: Fix nesting if statements.
Nesting if statements did not correctly process the contents of
the nested if script. This change makes the processing uniform
across all the logic stages.
2013-09-03 08:30:26 +10:00
Chris Johns
ebf8a1f0f8 Automtically build the Autotools to bootstrap RTEMS.
This changes adds support to build the autotools if the host installed
version is not a suitable version. Autoconf and automake have hard coded
references to the install prefix and host tools and this makes it impossible
to relocate, that is use in any path other than the install prefix. To
bootstrap automake you need to first build a suitable autoconf and with that
you can built automake for the install prefix. The other complication is
not referencing the install prefix in the path when building in the RSB.
Having the install prefix in the path can result in strange issues appearing
such as gcc using a new assembler feature not present in an older assember
installed under the install prefix.

The process is to build the autotools using an install prefix to an
internal path inside the RSB temporary path and to use that autoconf
to build the version for the install prefix. The internal install
prefix version is also used to bootstrap RTEMS.
2013-07-16 10:02:41 +10:00
Chris Johns
5237f1ccb7 Fix support for Windows (MinGW) native builds using MSYS.
Fix paths that need to be coverted to host format.

The shell expansion needs to invoke a shell on Windows as cmd.exe
will not work.

Munch the paths into smaller sizes for Windows due to the limited
path size.
2013-05-13 14:44:49 +10:00
Chris Johns
8837860347 Add a function to return the config file name. 2013-04-29 08:59:53 +10:00
Chris Johns
22afed354e Fix the trace message for _disable. 2013-04-28 15:51:51 +10:00
Chris Johns
517f03669c Add '%disable select' to turn off the macros maps. 2013-04-27 20:26:49 +10:00
Chris Johns
5142becd8e Refactor the logging support. 2013-04-21 18:37:02 +10:00
Chris Johns
b8ee74d356 Add a %testing section to the configuration files. 2013-04-15 13:26:36 +10:00
Chris Johns
0565e1fa4b Add support for snapshot testing.
User macro files passed on the command line allow a user to
override the defaults in configuration files to test new changes
in pending releases.

Fix macros issues with keys with more than one map.
2013-04-13 18:29:30 +10:00
Chris Johns
376aabf5e4 Another defines bug fix. 2013-04-13 10:39:02 +10:00
Chris Johns
5c7b1ef1e7 Package data into macro, sources from macro and a bug fix.
Package descritions and info and now always added to macros.

Hack to get the source in macros into the source this. This needs
to move to the package class and will soon.

Fix a bug where the old defines was still referenced.
2013-04-13 10:34:47 +10:00