... | @@ -8,7 +8,7 @@ |
... | @@ -8,7 +8,7 @@ |
|
This almost does what we would want, but not quite. If you build this way it will always try to fetch your modules from the source specified in the manifest, but we want to use our local checkout instead. This is fine if you only build the `master` branch but MRs need to be able to change the source to their checkout.
|
|
This almost does what we would want, but not quite. If you build this way it will always try to fetch your modules from the source specified in the manifest, but we want to use our local checkout instead. This is fine if you only build the `master` branch but MRs need to be able to change the source to their checkout.
|
|
|
|
|
|
To achieve this we use the `--stop-at=module` argument which will build all of the dependencies up to your module from the manifest. Then we take over and need to install the application ourselves. This is why your config
|
|
To achieve this we use the `--stop-at=module` argument which will build all of the dependencies up to your module from the manifest. Then we take over and need to install the application ourselves. This is why your config
|
|
s `MESON_ARGS` variable needs to be kept in sync with your module's config options in the manifest.
|
|
s `CONFIGURE_ARGS` variable needs to be kept in sync with your module's config options in the manifest.
|
|
|
|
|
|
### Basic building with CI
|
|
### Basic building with CI
|
|
|
|
|
... | @@ -36,11 +36,11 @@ flatpak: |
... | @@ -36,11 +36,11 @@ flatpak: |
|
FLATPAK_MODULE: "app-name"
|
|
FLATPAK_MODULE: "app-name"
|
|
# Make sure to keep this in sync with the Flatpak manifest, all arguments
|
|
# Make sure to keep this in sync with the Flatpak manifest, all arguments
|
|
# are passed except the config-args because we build it ourselves
|
|
# are passed except the config-args because we build it ourselves
|
|
MESON_ARGS: "-Dtests=all"
|
|
CONFIGURE_ARGS: "-Dtests=all"
|
|
|
|
|
|
script:
|
|
script:
|
|
- flatpak-builder --stop-at=${FLATPAK_MODULE} app ${MANIFEST_PATH}
|
|
- flatpak-builder --stop-at=${FLATPAK_MODULE} app ${MANIFEST_PATH}
|
|
- flatpak build app meson --prefix=/app ${MESON_ARGS} _build
|
|
- flatpak build app meson --prefix=/app ${CONFIGURE_ARGS} _build
|
|
- flatpak build app ninja -C _build install
|
|
- flatpak build app ninja -C _build install
|
|
# Run tests inside the Flatpak env emulating a display
|
|
# Run tests inside the Flatpak env emulating a display
|
|
- xvfb-run -a -s "-screen 0 1024x768x24" flatpak build app ninja -C _build test
|
|
- xvfb-run -a -s "-screen 0 1024x768x24" flatpak build app ninja -C _build test
|
... | @@ -141,14 +141,14 @@ flatpak: |
... | @@ -141,14 +141,14 @@ flatpak: |
|
FLATPAK_MODULE: "app-name"
|
|
FLATPAK_MODULE: "app-name"
|
|
# Make sure to keep this in sync with the Flatpak manifest, all arguments
|
|
# Make sure to keep this in sync with the Flatpak manifest, all arguments
|
|
# are passed except the config-args because we build it ourselves
|
|
# are passed except the config-args because we build it ourselves
|
|
MESON_ARGS: "-Dtests=all"
|
|
CONFIGURE_ARGS: "-Dtests=all"
|
|
DBUS_ID: "org.gnome.AppName"
|
|
DBUS_ID: "org.gnome.AppName"
|
|
|
|
|
|
script:
|
|
script:
|
|
- flatpak-builder --stop-at=${FLATPAK_MODULE} app ${MANIFEST_PATH}
|
|
- flatpak-builder --stop-at=${FLATPAK_MODULE} app ${MANIFEST_PATH}
|
|
# Make sure to keep this in sync with the Flatpak manifest, all arguments
|
|
# Make sure to keep this in sync with the Flatpak manifest, all arguments
|
|
# are passed except the config-args because we build it ourselves
|
|
# are passed except the config-args because we build it ourselves
|
|
- flatpak build app meson --prefix=/app ${MESON_ARGS} _build
|
|
- flatpak build app meson --prefix=/app ${CONFIGURE_ARGS} _build
|
|
- flatpak build app ninja -C _build install
|
|
- flatpak build app ninja -C _build install
|
|
- flatpak-builder --finish-only --repo=repo app ${MANIFEST_PATH}
|
|
- flatpak-builder --finish-only --repo=repo app ${MANIFEST_PATH}
|
|
# Run automatic tests inside the Flatpak env
|
|
# Run automatic tests inside the Flatpak env
|
... | | ... | |