diff options
author | Takashi Sakamoto <o-takashi@sakamocchi.jp> | 2023-10-03 08:17:35 +0900 |
---|---|---|
committer | 坂本 貴史 <o-takashi@sakamocchi.jp> | 2023-10-03 21:18:47 +0900 |
commit | 87e5e1384bff3f298051c048f2eafa6a69e8a6d7 (patch) | |
tree | 2840ce515081791d1403c728948b3e55f5c4c977 | |
parent | 7b84fdf6ea53848b7c466903ea003eacd2e7343b (diff) | |
download | libhinoko-87e5e1384bff3f298051c048f2eafa6a69e8a6d7.tar.gz |
ci: utilize meson subproject to satisfy dependency on libhinawa
The support for meson subproject enables to satisfy libhinawa dependency
without installing it. It is preferable.
Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
-rw-r--r-- | .github/workflows/build.yml | 72 |
1 files changed, 26 insertions, 46 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 89f01df..47da1b5 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,12 +2,6 @@ name: Build test on: [push, pull_request] -env: - KERNEL_ORG_WORKING_PATH: ${{ github.workspace }}/../kernel.org - LIBHINAWA_BUILD_PATH: $KERNEL_ORG_WORKING_PATH/libhinawa - LIBHINAWA_REPOSITORY_URL: https://github.com/alsa-project/libhinawa.git - LIBHINAWA_TAG: 2.6.0 - jobs: build_in_fedora_amd64_on_docker: runs-on: ubuntu-latest @@ -20,28 +14,21 @@ jobs: dnf -y install @development-tools dnf -y install meson gobject-introspection-devel systemd-devel dnf -y install gi-docgen python3-gobject - # Satisfy the dependency on libhinawa. - - name: make directory specific to software in kernel.org. - run: | - mkdir $KERNEL_ORG_WORKING_PATH - - name: Clone repository of libhinawa. - run: | - git clone --depth 1 --branch "${LIBHINAWA_TAG}" "${LIBHINAWA_REPOSITORY_URL}" "${LIBHINAWA_BUILD_PATH}" - - name: Initialize to build libhinawa. - run: | - cd "${LIBHINAWA_BUILD_PATH}" - meson setup --prefix=/usr build - - name: Install libhinawa. - run: | - cd "${LIBHINAWA_BUILD_PATH}" - meson install -C build - - name: Test installation of libhinawa. - run: | - cd "${LIBHINAWA_BUILD_PATH}" - python3 tests/fw-node - # Test to build libhinoko. - name: Checkout repository. uses: actions/checkout@v3 + - name: Create hinawa.wrap in subproject directory + run: | + mkdir subprojects + cat > subprojects/hinawa.wrap << EOF + [wrap-git] + directory = libhinawa + url = https://git.kernel.org/pub/scm/libs/ieee1394/libhinawa.git + revision = 2.6.1 + depth = 1 + + [provide] + hinawa = hinawa_dep + EOF - name: Initialization for build. run: | meson --prefix=/tmp. -Ddoc=true -Dwarning_level=3 . build @@ -70,28 +57,21 @@ jobs: DEBIAN_FRONTEND=noninteractive apt-get install -y git build-essential DEBIAN_FRONTEND=noninteractive apt-get install -y meson ninja-build libglib2.0-dev gobject-introspection libgirepository1.0-dev DEBIAN_FRONTEND=noninteractive apt-get install -y gi-docgen python3-gi - # Satisfy the dependency on libhinawa. - - name: make directory specific to software in kernel.org. - run: | - mkdir $KERNEL_ORG_WORKING_PATH - - name: Clone repository of libhinawa. - run: | - git clone --depth 1 --branch "${LIBHINAWA_TAG}" "${LIBHINAWA_REPOSITORY_URL}" "${LIBHINAWA_BUILD_PATH}" - - name: Initialize to build libhinawa. - run: | - cd "${LIBHINAWA_BUILD_PATH}" - meson setup --prefix=/usr build - - name: Install libhinawa. - run: | - cd "${LIBHINAWA_BUILD_PATH}" - meson install -C build - - name: Test installation of libhinawa. - run: | - cd "${LIBHINAWA_BUILD_PATH}" - python3 tests/fw-node - # Test to build libhinoko. - name: Checkout repository. uses: actions/checkout@v3 + - name: Create hinawa.wrap in subproject directory + run: | + mkdir subprojects + cat > subprojects/hinawa.wrap << EOF + [wrap-git] + directory = libhinawa + url = https://git.kernel.org/pub/scm/libs/ieee1394/libhinawa.git + revision = 2.6.1 + depth = 1 + + [provide] + hinawa = hinawa_dep + EOF - name: Initialization for build. run: | meson --prefix=/tmp. -Ddoc=true -Dwarning_level=3 . build |