Skip to content

Commit

Permalink
chore: move to up-to-date yap agent
Browse files Browse the repository at this point in the history
  • Loading branch information
M0Rf30 committed Dec 16, 2023
1 parent 0d26e88 commit 1fc7208
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 41 deletions.
34 changes: 18 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,26 +25,29 @@ jobs:
run: echo "::set-output name=version::$(cat packages/cie-middleware/PKGBUILD | grep pkgver | cut -d\" -f2)"
id: version

- name: ccache
uses: hendrikmuhs/ccache-action@v1

- name: Build
run: |
docker run -v $(pwd)/.ccache:/ccache -v $(pwd):/project -e CCACHE_DIR=/ccache packagefoundation/yap-ubuntu-focal:latest build ubuntu-focal packages/deb
docker run -v $(pwd)/.ccache:/ccache -v $(pwd):/project -e CCACHE_DIR=/ccache packagefoundation/yap-rocky-8:latest build rocky-8 packages/rpm
mkdir artifacts_ci
sudo mv artifacts/*.deb artifacts_ci
sudo mv artifacts/*.rpm artifacts_ci
for i in $(ls artifacts_ci/); do sha256sum artifacts_ci/$i >> artifacts_ci/SHA256SUMS; done
docker run --entrypoint=bash -v $(pwd):/project m0rf30/yap-ubuntu-focal:latest -c "cd /project; \
yap prepare ubuntu-focal; \
yap build ubuntu-focal /project/packages/deb; \
yap build ubuntu-focal /project/packages"
docker run --entrypoint=bash -v $(pwd):/project m0rf30/yap-rocky-8:latest -c "cd /project; \
yap prepare rocky-8; \
dnf -y install dnf-plugins-core epel-release; \
dnf config-manager --set-enabled powertools; \
yap build rocky-8 /project/packages"
for i in $(ls artifacts/); do sha256sum artifacts/$i >> SHA256SUMS; done
for i in $(ls artifacts/x86_64/); do sha256sum artifacts/x86_64/$i >> SHA256SUMS; done
- name: Archive production artifacts
uses: actions/upload-artifact@v3
with:
name: "cie-middleware-${{ steps.version.outputs.version }}"
path: |
artifacts_ci/*.deb
artifacts/SHA256SUMS
artifacts/*.deb
artifacts/x86_64/*.rpm
SHA256SUMS
- uses: "marvinpinto/action-automatic-releases@latest"
with:
Expand All @@ -53,7 +56,6 @@ jobs:
prerelease: false
title: "cie-middleware-${{ steps.version.outputs.version }}"
files: |
artifacts_ci/*.deb
artifacts_ci/*.rpm
artifacts_ci/SHA256SUMS
artifacts/*.deb
artifacts/x86_64/*.rpm
SHA256SUMS
27 changes: 12 additions & 15 deletions packages/cie-middleware/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,24 @@ pkgrel="1"
pkgdesc="A fork of Middleware della CIE (Carta di Identità Elettronica) per Linux"
maintainer="M0Rf30"
url="https://github.com/italia/cie-middleware-linux"
arch=("amd64")
license=("BSD-3")
arch=("x86_64")
license=("BSD-3-Clause")
section="utils"
priority="optional"
sources=(
source=(
"https://github.com/M0Rf30/cie-middleware-linux/archive/refs/tags/${pkgver}-podofo.tar.gz"
"https://downloads.gradle-dn.com/distributions/gradle-7.4.2-bin.zip"
"https://services.gradle.org/distributions/gradle-8.5-bin.zip"
)
sources__pacman=(
source__pacman=(
"https://github.com/M0Rf30/cie-middleware-linux/archive/refs/tags/${pkgver}-podofo.tar.gz"
)

hashsums=(
"skip"
"skip"
sha256sums=(
"SKIP"
"SKIP"
)
hashsums__pacman=(
"skip"
sha256sums__pacman=(
"SKIP"
)
depends__apt=(
"cryptopp"
Expand All @@ -37,7 +37,6 @@ depends__apt=(
"pcscd"
)
makedepends__apt=(
"ccache"
"g++"
"libcurl4-openssl-dev"
"libfontconfig1-dev"
Expand Down Expand Up @@ -66,7 +65,6 @@ depends__pacman=(
"podofo"
)
makedepends__pacman=(
"ccache"
"crypto++"
"curl"
"fontconfig"
Expand Down Expand Up @@ -96,7 +94,6 @@ depends__yum=(
"podofo-libs"
)
makedepends__yum=(
"ccache"
"cryptopp-devel"
"fontconfig-devel"
"freetype-devel"
Expand Down Expand Up @@ -126,7 +123,7 @@ build__yum() {
export JAVA_HOME=/usr/lib/jvm/java-11-openjdk/

cd "${srcdir}/${pkgname}-linux-${pkgver}-podofo"
../gradle-7.4.2/bin/gradle -b cie-java/build.gradle standalone
../gradle-8.5/bin/gradle -b cie-java/build.gradle standalone
meson builddir libs
meson configure -Dprefix=/usr builddir
meson compile -C builddir
Expand All @@ -137,7 +134,7 @@ build__apt() {
pip3 install ninja==1.10.2.3 meson==0.61.1

cd "${srcdir}/${pkgname}-linux-${pkgver}-podofo"
../gradle-7.4.2/bin/gradle -b cie-java/build.gradle standalone
../gradle-8.5/bin/gradle -b cie-java/build.gradle standalone

meson builddir libs
meson configure -Dprefix=/usr builddir
Expand Down
6 changes: 3 additions & 3 deletions packages/cryptopp/PKGBUILD → packages/deb/cryptopp/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ pkgname="cryptopp"
pkgver="8.6.0"
pkgrel="1"
pkgdesc="A free C++ class library of cryptographic schemes"
arch=("amd64")
arch=("x86_64")
maintainer="M0Rf30"
url="https://www.cryptopp.com/"
section="libs"
priority="important"
sources=(
source=(
"https://github.com/weidai11/cryptopp/archive/69bf6b53052b59ccb57ce068ce741988ae087317.tar.gz"
)
hashsums=(
sha256sums=(
"SKIP"
)

Expand Down
7 changes: 2 additions & 5 deletions packages/deb/yap.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,8 @@
"output": "artifacts",
"Projects": [
{
"name": "../cryptopp",
"name": "cryptopp",
"install": true
},
{
"name": "../cie-middleware"
}
]
}
}
4 changes: 2 additions & 2 deletions packages/rpm/yap.json → packages/yap.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"output": "artifacts",
"Projects": [
{
"name": "../cie-middleware"
"name": "cie-middleware"
}
]
}
}

0 comments on commit 1fc7208

Please sign in to comment.