From 614b988d8afdc445812fdb05810ef5d4e2594044 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Thu, 28 May 2020 08:54:25 +0200 Subject: spec: Add examples --- spec/spec/build-ada-test-program.yml | 25 +++++++++++++++++++++- spec/spec/build-bsp.yml | 40 +++++++++++++++++++++++++++++++++++- spec/spec/build-config-file.yml | 15 +++++++++++++- spec/spec/build-group.yml | 22 +++++++++++++++++++- spec/spec/build-library.yml | 23 ++++++++++++++++++++- spec/spec/build-objects.yml | 22 +++++++++++++++++++- spec/spec/build-option.yml | 25 +++++++++++++++++++++- spec/spec/build-script.yml | 24 +++++++++++++++++++++- spec/spec/build-start-file.yml | 16 ++++++++++++++- spec/spec/build-test-program.yml | 22 +++++++++++++++++++- spec/spec/enabled-by.yml | 6 +++++- spec/spec/requirement.yml | 14 ++++++++++++- 12 files changed, 242 insertions(+), 12 deletions(-) diff --git a/spec/spec/build-ada-test-program.yml b/spec/spec/build-ada-test-program.yml index 66a470f7..2425f858 100644 --- a/spec/spec/build-ada-test-program.yml +++ b/spec/spec/build-ada-test-program.yml @@ -10,7 +10,30 @@ links: spec-value: ada-test-program uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + ada-main: testsuites/ada/samples/hello/hello.adb + ada-object-directory: testsuites/ada/samples/hello + adaflags: [] + adaincludes: + - cpukit/include/adainclude + - testsuites/ada/support + build-type: ada-test-program + cflags: [] + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + cppflags: [] + enabled-by: true + includes: [] + ldflags: [] + links: [] + source: + - testsuites/ada/samples/hello/init.c + stlib: [] + target: testsuites/ada/ada_hello.exe + type: build + use-after: [] + use-before: [] spec-info: dict: attributes: diff --git a/spec/spec/build-bsp.yml b/spec/spec/build-bsp.yml index e08eb0cd..3660da67 100644 --- a/spec/spec/build-bsp.yml +++ b/spec/spec/build-bsp.yml @@ -10,7 +10,45 @@ links: spec-value: bsp uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + arch: myarch + bsp: mybsp + build-type: bsp + cflags: [] + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + cppflags: [] + enabled-by: true + family: mybsp + includes: [] + install: + - destination: ${BSP_INCLUDEDIR} + source: + - bsps/myarch/mybsp/include/bsp.h + - bsps/myarch/mybsp/include/tm27.h + - destination: ${BSP_INCLUDEDIR}/bsp + source: + - bsps/myarch/mybsp/include/bsp/irq.h + - destination: ${BSP_LIBDIR} + source: + - bsps/myarch/mybsp/start/linkcmds + links: + - role: build-dependency + uid: ../../obj + - role: build-dependency + uid: ../../opto2 + - role: build-dependency + uid: abi + - role: build-dependency + uid: obj + - role: build-dependency + uid: ../start + - role: build-dependency + uid: ../../bspopts + source: + - bsps/myarch/mybsp/start/bspstart.c + type: build spec-info: dict: attributes: diff --git a/spec/spec/build-config-file.yml b/spec/spec/build-config-file.yml index f99bbca9..ed050b68 100644 --- a/spec/spec/build-config-file.yml +++ b/spec/spec/build-config-file.yml @@ -10,7 +10,20 @@ links: spec-value: config-file uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + build-type: config-file + content: | + # ... + Name: ${ARCH}-rtems${__RTEMS_MAJOR__}-${BSP_NAME} + # ... + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + enabled-by: true + install-path: ${PREFIX}/lib/pkgconfig + links: [] + target: ${ARCH}-rtems${__RTEMS_MAJOR__}-${BSP_NAME}.pc + type: build spec-info: dict: attributes: diff --git a/spec/spec/build-group.yml b/spec/spec/build-group.yml index f25365bb..c0dd1c63 100644 --- a/spec/spec/build-group.yml +++ b/spec/spec/build-group.yml @@ -10,7 +10,27 @@ links: spec-value: group uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + build-type: group + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + enabled-by: + - BUILD_TESTS + - BUILD_SAMPLES + includes: + - testsuites/support/include + install: [] + ldflags: + - -Wl,--wrap=printf + - -Wl,--wrap=puts + links: + - role: build-dependency + uid: ticker + type: build + use-after: [] + use-before: + - rtemstest spec-info: dict: attributes: diff --git a/spec/spec/build-library.yml b/spec/spec/build-library.yml index 8cfe1afe..a48644ac 100644 --- a/spec/spec/build-library.yml +++ b/spec/spec/build-library.yml @@ -10,7 +10,28 @@ links: spec-value: library uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + build-type: library + cflags: + - -Wno-pointer-sign + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + cppflags: [] + cxxflags: [] + enabled-by: true + includes: + - cpukit/libfs/src/jffs2/include + install: + - destination: ${BSP_INCLUDEDIR}/rtems + source: + - cpukit/include/rtems/jffs2.h + install-path: ${BSP_LIBDIR} + links: [] + source: + - cpukit/libfs/src/jffs2/src/build.c + target: jffs2 + type: build spec-info: dict: attributes: diff --git a/spec/spec/build-objects.yml b/spec/spec/build-objects.yml index 96ac5e5f..2192cb07 100644 --- a/spec/spec/build-objects.yml +++ b/spec/spec/build-objects.yml @@ -10,7 +10,27 @@ links: spec-value: objects uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + build-type: objects + cflags: [] + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + cppflags: [] + cxxflags: [] + enabled-by: true + includes: [] + install: + - destination: ${BSP_INCLUDEDIR}/bsp + source: + - bsps/include/bsp/bootcard.h + - bsps/include/bsp/default-initial-extension.h + - bsps/include/bsp/fatal.h + links: [] + source: + - bsps/shared/start/bootcard.c + - bsps/shared/rtems-version.c + type: build spec-info: dict: attributes: diff --git a/spec/spec/build-option.yml b/spec/spec/build-option.yml index 6d92a739..b05275aa 100644 --- a/spec/spec/build-option.yml +++ b/spec/spec/build-option.yml @@ -10,7 +10,30 @@ links: spec-value: option uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + actions: + - get-integer: null + - define: null + build-type: option + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + default: 115200 + default-by-variant: + - value: 9600 + variants: + - m68k/m5484FireEngine + - powerpc/hsc_cm01 + - value: 19200 + variants: + - m68k/COBRA5475 + description: | + Default baud for console and other serial devices. + enabled-by: true + format: '{}' + links: [] + name: BSP_CONSOLE_BAUD + type: build spec-info: dict: attributes: diff --git a/spec/spec/build-script.yml b/spec/spec/build-script.yml index 4ae7d2c8..dcbe498c 100644 --- a/spec/spec/build-script.yml +++ b/spec/spec/build-script.yml @@ -10,7 +10,29 @@ links: spec-value: script uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + build-type: script + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + default: null + default-by-variant: [] + do-build: | + bld.install_as( + "${BSP_LIBDIR}/linkcmds", + "bsps/" + bld.env.ARCH + "/" + bld.env.BSP_FAMILY + + "/start/linkcmds." + bld.env.BSP_BASE + ) + do-configure: | + conf.env.append_value( + "LINKFLAGS", + ["-qnolinkcmds", "-T", "linkcmds." + conf.env.BSP_BASE] + ) + enabled-by: true + links: [] + prepare-build: null + prepare-configure: null + type: build spec-info: dict: attributes: diff --git a/spec/spec/build-start-file.yml b/spec/spec/build-start-file.yml index b942c355..d82722bf 100644 --- a/spec/spec/build-start-file.yml +++ b/spec/spec/build-start-file.yml @@ -10,7 +10,21 @@ links: spec-value: start-file uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + asflags: [] + build-type: start-file + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + cppflags: [] + enabled-by: true + includes: [] + install-path: ${BSP_LIBDIR} + links: [] + source: + - bsps/sparc/shared/start/start.S + target: start.o + type: build spec-info: dict: attributes: diff --git a/spec/spec/build-test-program.yml b/spec/spec/build-test-program.yml index 29218cc0..f2fc4d0d 100644 --- a/spec/spec/build-test-program.yml +++ b/spec/spec/build-test-program.yml @@ -10,7 +10,27 @@ links: spec-value: test-program uid: build spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + build-type: test-program + cflags: [] + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) + cppflags: [] + cxxflags: [] + enabled-by: true + features: c cprogram + includes: [] + ldflags: [] + links: [] + source: + - testsuites/samples/ticker/init.c + - testsuites/samples/ticker/tasks.c + stlib: [] + target: testsuites/samples/ticker.exe + type: build + use-after: [] + use-before: [] spec-info: dict: attributes: diff --git a/spec/spec/enabled-by.yml b/spec/spec/enabled-by.yml index fa7de056..ec13804f 100644 --- a/spec/spec/enabled-by.yml +++ b/spec/spec/enabled-by.yml @@ -10,7 +10,11 @@ spec-description: | conditions the specification item or parts of it are enabled. The expression is evaluated with the use of an *enabled set*. This is a set of strings which indicate enabled features. -spec-example: null +spec-example: | + enabled-by: + and: + - RTEMS_NETWORKING + - not: RTEMS_SMP spec-info: bool: description: | diff --git a/spec/spec/requirement.yml b/spec/spec/requirement.yml index fbbd5b3a..e38cc68e 100644 --- a/spec/spec/requirement.yml +++ b/spec/spec/requirement.yml @@ -10,7 +10,19 @@ links: spec-value: requirement uid: root spec-description: null -spec-example: null +spec-example: | + SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause + copyrights: + - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de + enabled-by: true + functional-type: capability + links: [] + rationale: | + It keeps you busy. + requirement-type: functional + text: | + The system shall do crazy things. + type: requirement spec-info: dict: attributes: -- cgit v1.2.3