You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildstream.apache.org by tv...@apache.org on 2021/02/04 07:48:03 UTC

[buildstream] 01/01: doc/examples/flatpak-autotools: Use freedesktop-sdk 18.08

This is an automated email from the ASF dual-hosted git repository.

tvb pushed a commit to branch jjardon/use_freedesktop-sdk_18_08
in repository https://gitbox.apache.org/repos/asf/buildstream.git

commit 97a545c1939a943e2d78c19602f56e5e49bcfc32
Author: Javier Jardón <jj...@gnome.org>
AuthorDate: Tue Oct 16 17:29:58 2018 +0100

    doc/examples/flatpak-autotools: Use freedesktop-sdk 18.08
---
 doc/examples/flatpak-autotools/elements/base/sdk.bst |  16 ++++++++--------
 doc/examples/flatpak-autotools/elements/hello.bst    |   3 +++
 doc/examples/flatpak-autotools/files/links/lib64     |   1 +
 doc/examples/flatpak-autotools/keys/flathub.gpg      | Bin 0 -> 2844 bytes
 doc/examples/flatpak-autotools/keys/gnome-sdk.gpg    | Bin 629 -> 0 bytes
 doc/examples/flatpak-autotools/project.conf          |   2 +-
 doc/source/examples/flatpak-autotools.rst            |   4 ++--
 tests/examples/flatpak-autotools.py                  |  14 ++++++++------
 tests/integration/project/keys/gnome-sdk.gpg         | Bin 629 -> 0 bytes
 9 files changed, 23 insertions(+), 17 deletions(-)

diff --git a/doc/examples/flatpak-autotools/elements/base/sdk.bst b/doc/examples/flatpak-autotools/elements/base/sdk.bst
index 97089b8..da0d984 100644
--- a/doc/examples/flatpak-autotools/elements/base/sdk.bst
+++ b/doc/examples/flatpak-autotools/elements/base/sdk.bst
@@ -2,15 +2,15 @@ kind: import
 description: Import the base freedesktop SDK
 sources:
 - kind: ostree
-  url: gnomesdk:repo/
-  gpg-key: keys/gnome-sdk.gpg
+  url: flathub:repo/
+  gpg-key: keys/flathub.gpg
   (?):
-  - arch == "x86-64":
-      track: runtime/org.freedesktop.BaseSdk/x86_64/1.4
-      ref: 0d9d255d56b08aeaaffb1c820eef85266eb730cb5667e50681185ccf5cd7c882
-  - arch == "x86-32":
-      track: runtime/org.freedesktop.BaseSdk/i386/1.4
-      ref: 16036b747c1ec8e7fe291f5b1f667cb942f0267d08fcad962e9b7627d6cf1981
+  - arch == "x86_64":
+      track: runtime/org.freedesktop.Sdk/x86_64/18.08
+      ref: 03ebd5e0d55333b3926fba9ad7163a665a5f22f3eb94f6fc0d7cb55af8888c75
+  - arch == "i386":
+      track: runtime/org.freedesktop.Sdk/i386/18.08
+      ref: f7d80db9d0eb219eba0a8d9ed1ae4d09fbda708fb49fd218839cbd4d745b01cd
 config:
   source: files
   target: usr
diff --git a/doc/examples/flatpak-autotools/elements/hello.bst b/doc/examples/flatpak-autotools/elements/hello.bst
index bdc2004..6a1156e 100644
--- a/doc/examples/flatpak-autotools/elements/hello.bst
+++ b/doc/examples/flatpak-autotools/elements/hello.bst
@@ -4,6 +4,9 @@ description: Autotools project
 depends:
 - base.bst
 
+variables:
+  prefix: '/app'
+
 sources:
 - kind: local
   path: files/src
diff --git a/doc/examples/flatpak-autotools/files/links/lib64 b/doc/examples/flatpak-autotools/files/links/lib64
new file mode 120000
index 0000000..d4801c6
--- /dev/null
+++ b/doc/examples/flatpak-autotools/files/links/lib64
@@ -0,0 +1 @@
+usr/lib64
\ No newline at end of file
diff --git a/doc/examples/flatpak-autotools/keys/flathub.gpg b/doc/examples/flatpak-autotools/keys/flathub.gpg
new file mode 100644
index 0000000..79880f6
Binary files /dev/null and b/doc/examples/flatpak-autotools/keys/flathub.gpg differ
diff --git a/doc/examples/flatpak-autotools/keys/gnome-sdk.gpg b/doc/examples/flatpak-autotools/keys/gnome-sdk.gpg
deleted file mode 100644
index 8434b68..0000000
Binary files a/doc/examples/flatpak-autotools/keys/gnome-sdk.gpg and /dev/null differ
diff --git a/doc/examples/flatpak-autotools/project.conf b/doc/examples/flatpak-autotools/project.conf
index 401dc56..6ee309d 100644
--- a/doc/examples/flatpak-autotools/project.conf
+++ b/doc/examples/flatpak-autotools/project.conf
@@ -1,7 +1,7 @@
 name: flatpak-autotools
 
 aliases:
-  gnomesdk: https://sdk.gnome.org/
+  flathub: https://dl.flathub.org/
 
 element-path: elements
 
diff --git a/doc/source/examples/flatpak-autotools.rst b/doc/source/examples/flatpak-autotools.rst
index e7039af..60541a2 100644
--- a/doc/source/examples/flatpak-autotools.rst
+++ b/doc/source/examples/flatpak-autotools.rst
@@ -31,7 +31,7 @@ architecture. For this example we only support the ``i386`` and ``x86_64``
 architectures.
 
 Note that we've added a :ref:`source alias <project_source_aliases>` for
-the ``https://sdk.gnome.org/`` repository to download the SDK from.
+the ``https://dl.flathub.org/`` repository to download the SDK from.
 
 
 ``elements/base/sdk.bst``
@@ -47,7 +47,7 @@ download the Flatpak since these are hosted in OSTree repositories.
 While declaring the :mod:`ostree <sources.ostree>` source, we specify a GPG
 public key to verify the OSTree download. This configuration is optional
 but recommended for OSTree repositories. The key is stored in the project directory
-at ``keys/gnome-sdk.gpg``, and can be downloaded from https://sdk.gnome.org/keys/.
+at ``keys/flathub.gpg``, and it's included in the file at https://flathub.org/repo/flathub.flatpakrepo.
 
 We also use :ref:`conditional statements <format_directives_conditional>` to decide
 which branch to download.
diff --git a/tests/examples/flatpak-autotools.py b/tests/examples/flatpak-autotools.py
index 454b8d0..cd41233 100644
--- a/tests/examples/flatpak-autotools.py
+++ b/tests/examples/flatpak-autotools.py
@@ -47,11 +47,13 @@ def test_autotools_build(cli, tmpdir, datafiles):
     result = cli.run(project=project, args=['artifact', 'checkout', 'hello.bst', '--directory', checkout])
     assert result.exit_code == 0
 
-    assert_contains(checkout, ['/usr', '/usr/lib', '/usr/bin',
-                               '/usr/share',
-                               '/usr/bin/hello', '/usr/share/doc',
-                               '/usr/share/doc/amhello',
-                               '/usr/share/doc/amhello/README'])
+    assert_contains(checkout, ['/app', '/app/lib', '/app/bin',
+                               '/app/share', '/app/lib/debug',
+                               '/app/lib/debug/app', '/app/lib/debug/app/bin',
+                               '/app/lib/debug/app/bin/hello',
+                               '/app/bin/hello', '/app/share/doc',
+                               '/app/share/doc/amhello',
+                               '/app/share/doc/amhello/README'])
 
 
 # Test running an executable built with autotools
@@ -66,6 +68,6 @@ def test_autotools_run(cli, tmpdir, datafiles):
     result = cli.run(project=project, args=['build', 'hello.bst'])
     assert result.exit_code == 0
 
-    result = cli.run(project=project, args=['shell', 'hello.bst', '/usr/bin/hello'])
+    result = cli.run(project=project, args=['shell', 'hello.bst', '/app/bin/hello'])
     assert result.exit_code == 0
     assert result.output == 'Hello World!\nThis is amhello 1.0.\n'
diff --git a/tests/integration/project/keys/gnome-sdk.gpg b/tests/integration/project/keys/gnome-sdk.gpg
deleted file mode 100644
index 8434b68..0000000
Binary files a/tests/integration/project/keys/gnome-sdk.gpg and /dev/null differ