diff options
author | Tiago Gomes <tiago.gomes@codethink.co.uk> | 2018-07-31 12:39:17 +0100 |
---|---|---|
committer | Tiago Gomes <tiago.avv@gmail.com> | 2018-08-02 11:24:43 +0000 |
commit | 33292be4618b83147258e729a44caa58859e4ba2 (patch) | |
tree | 9af95e3e64eb4b6818b1b7d40f17dc94d2caaf52 /doc | |
parent | e788bda4969de17178f3facc0d31b36c91121402 (diff) | |
download | buildstream-33292be4618b83147258e729a44caa58859e4ba2.tar.gz |
local plugin: validate project paths
The autotools example had to be copied over inside of the junction
example, as referring to a path outside of the project directory is
now disallowed.
Diffstat (limited to 'doc')
6 files changed, 55 insertions, 7 deletions
diff --git a/doc/examples/junctions/autotools/elements/base.bst b/doc/examples/junctions/autotools/elements/base.bst new file mode 100644 index 000000000..1b85a9e8c --- /dev/null +++ b/doc/examples/junctions/autotools/elements/base.bst @@ -0,0 +1,5 @@ +kind: stack +description: Base stack + +depends: +- base/alpine.bst diff --git a/doc/examples/junctions/autotools/elements/base/alpine.bst b/doc/examples/junctions/autotools/elements/base/alpine.bst new file mode 100644 index 000000000..cf85df5bf --- /dev/null +++ b/doc/examples/junctions/autotools/elements/base/alpine.bst @@ -0,0 +1,13 @@ +kind: import +description: | + + Alpine Linux base runtime + +sources: +- kind: tar + + # This is a post doctored, trimmed down system image + # of the Alpine linux distribution. + # + url: alpine:integration-tests-base.v1.x86_64.tar.xz + ref: 3eb559250ba82b64a68d86d0636a6b127aa5f6d25d3601a79f79214dc9703639 diff --git a/doc/examples/junctions/autotools/elements/hello.bst b/doc/examples/junctions/autotools/elements/hello.bst new file mode 100644 index 000000000..510f5b975 --- /dev/null +++ b/doc/examples/junctions/autotools/elements/hello.bst @@ -0,0 +1,21 @@ +kind: autotools +description: | + + Hello world example from automake + +variables: + + # The hello world example lives in the doc/amhello folder. + # + # Set the %{command-subdir} variable to that location + # and just have the autotools element run it's commands there. + # + command-subdir: doc/amhello + +sources: +- kind: tar + url: gnu:automake-1.16.tar.gz + ref: 80da43bb5665596ee389e6d8b64b4f122ea4b92a685b1dbd813cd1f0e0c2d83f + +depends: +- base.bst diff --git a/doc/examples/junctions/autotools/project.conf b/doc/examples/junctions/autotools/project.conf new file mode 100644 index 000000000..7ee58b589 --- /dev/null +++ b/doc/examples/junctions/autotools/project.conf @@ -0,0 +1,13 @@ +# Unique project name +name: autotools + +# Required BuildStream format version +format-version: 9 + +# Subdirectory where elements are stored +element-path: elements + +# Define some aliases for the tarballs we download +aliases: + alpine: https://gnome7.codethink.co.uk/tarballs/ + gnu: https://ftp.gnu.org/gnu/automake/ diff --git a/doc/examples/junctions/elements/hello-junction.bst b/doc/examples/junctions/elements/hello-junction.bst index dda865ecf..6d01e36a1 100644 --- a/doc/examples/junctions/elements/hello-junction.bst +++ b/doc/examples/junctions/elements/hello-junction.bst @@ -1,8 +1,4 @@ kind: junction - -# Specify the source of the BuildStream project -# We are going to use the autotools examples distributed with BuildStream in the -# doc/examples/autotools directory sources: - kind: local - path: ../autotools + path: autotools diff --git a/doc/source/advanced-features/junction-elements.rst b/doc/source/advanced-features/junction-elements.rst index 929ac1217..81fc01a05 100644 --- a/doc/source/advanced-features/junction-elements.rst +++ b/doc/source/advanced-features/junction-elements.rst @@ -21,8 +21,8 @@ Below is a simple example of bst file for a junction element: .. literalinclude:: ../../examples/junctions/elements/hello-junction.bst :language: yaml -This element imports the autotools example project found in the BuildStream -doc/examples/autotools subdirectory. +This element imports the autotools example subproject found in the +BuildStream doc/examples/junctions/autotools subdirectory. .. note:: |