Commit Graph

29 Commits

Author SHA1 Message Date
Ivan Velickovic
410b464c27 Remove unused Python imports in scripts
Signed-off-by: Ivan Velickovic <i.velickovic@unsw.edu.au>
2024-05-02 10:17:13 +01:00
Axel Heider
ed613d7d49 python: remove unused template parameter
Since commit cf8be663 this is no longer needed.

Signed-off-by: Axel Heider <axelheider@gmx.de>
2024-01-02 10:55:45 +11:00
Cindy Liu
498fd84a55 use raise warining in version check
Signed-off-by: Cindy Liu <hcindyl@google.com>
2023-12-28 06:05:07 +07:00
Cindy Liu
807a42e91e Move the version check just before the usage
Signed-off-by: Cindy Liu <hcindyl@google.com>
2023-12-28 06:05:07 +07:00
Cindy Liu
04dc9675f3 Replace deprecated pkg_resources usage
Use importlib.metadata to check the jinja2 version

Signed-off-by: Cindy Liu <hcindyl@google.com>
2023-12-28 06:05:07 +07:00
Axel Heider
83a02a96fc python: use '#paragma once' include guard
Signed-off-by: Axel Heider <axelheider@gmx.de>
2022-03-23 17:28:07 +11:00
matt rice
0e354b5766 tools: use conditions elem
Signed-off-by: matt rice <ratmice@gmail.com>
2022-03-22 18:33:38 +11:00
matt rice
d742424021 use the loop.first builtin instead of namespaces
this allows the template to be parsed with minijinja
which doesn't support namespaces or set (at this time).

Signed-off-by: matt rice <ratmice@gmail.com>
2022-03-01 07:57:31 +11:00
Gerwin Klein
ef94b463bd clarify license for generated headers
Invocation and syscall headers are generated and provided under
BSD-2-Clause for user code and GPL-2.0-only for kernel code. To
facilitate people other than the copyright holder performing this
operation, the master files are provided under both (BSD or GPL, free
to choose).
2020-03-09 13:21:49 +08:00
Gerwin Klein
79da079239 Convert license tags to SPDX identifiers
This commit also converts our own copyright headers to directly use
SPDX, but leaves all other copyright header intact, only adding the
SPDX ident. As far as possible this commit also merges multiple
Data61 copyright statements/headers into one for consistency.
2020-03-09 13:21:49 +08:00
Anna Lyons
bc61a7f3bd python2 --> python3
Update all scripts and build system to call python3, given python2's
upcoming doom. Use sys.maxsize instead of sys.maxint in one script
(maxint does not exist in python3).
2019-08-08 10:19:24 +10:00
Anna Lyons
cf57914c7f style: run autopep8 on python files 2019-03-27 10:43:58 +11:00
Adrian Danis
1dd8015da2 tools: State jinja2 version
Provides a graceful error when jinja2 is the wrong version
2018-06-21 14:38:55 +10:00
Kent McLeod
e281a47b7c Remove references to unused tempita library 2018-06-13 15:43:48 +10:00
Kent McLeod
187445000e tools: Fix whitespace differences in header gen 2018-06-13 10:42:35 +10:00
Summer Li
004891f410 libsel4: change tempita to jinja2 2018-06-12 16:54:25 +10:00
Anna Lyons
64cf2308ac tools: fix licenses 2017-06-22 15:27:30 +10:00
Anna Lyons
07f948331f libsel4: fix licenses
- some were incorrectly marked GPL (libsel4 is BSD)
- update NICTA --> DATA61 etc
- fix tags D61 --> DATA61
- update year to 2017
2017-06-22 15:27:29 +10:00
Adrian Danis
4bfa5bb979 tools: Correct case where label numbers will be 0
If `seL4_arch_invocations` is an empty list, this will cause `nSeL4ArchInvocationLabels`
to be declared as 0, rather than `nInvocationLabels` as intented. This change correctly
respects the behaviour of the 'first' variable, and does an explicit assignment to
`nSeL4ArchInvocationLabels` should it be the first (and only) member of the enum.

Closes #53
2017-01-04 10:40:25 +11:00
amrzar
ee75f086f3 update #ifdef to #if in auto generated files 2016-10-17 12:18:58 +11:00
Adrian Danis
cf8be6639f tools: Remove arithmetic in invocation generation
If invocations are hidden behind config guards the count of how
many invocations there are will be wrong. The C compiler will
correctly assign the value with enum auto numbering, so there's
no need to override that here
2016-06-16 15:36:00 +10:00
Anna Lyons
9fca296f8a tools: emit error if first invocation conditional
Placing a config condition on the first define
in sel4arch.xml will fail as currently the first define
must start at the last define + 1 of the previous
invocation enum.

If this is ever required, autoconf.h will need to be passed
to the script so it can check config variables itself.
2016-06-16 10:43:56 +10:00
Anna Lyons
73837c8ace tools: add conditional invocation label defines 2016-06-16 10:38:29 +10:00
Corey Richardson
36e8b1d494 tools: invocation_header_gen: python3 compat 2016-01-25 15:42:06 +11:00
Corey Richardson
1234892209 tools: invocation_header_gen: remove trailing whitespace 2016-01-25 15:42:05 +11:00
Adrian Danis
2dd0a4d5e1 libsel4: Explicitly generate number of invocation labels to handle case where there are no invocations 2016-01-13 14:08:22 +11:00
Adrian Danis
44a522dce2 libsel4: Generate libsel4 definitions from the current ARCH as well as the SEL4_ARCH 2016-01-08 10:16:30 +11:00
Max R.D. Parmer
da5ec79cf9 Use usr/bin/env for all python bangpaths to enable virtualenv use.
Very useful with python3 as the default platform.
2014-08-03 18:53:14 -07:00
TrusthworthySystems
91b7da8625 Release snapshot 2014-07-18 05:03:59 +10:00