| 1 | defpkgbuild(gpgme, |
| 2 | #:pkgname, "gpgme", |
| 3 | #:pkgver, "1.24.1", |
| 4 | #:pkgrel, 1, |
| 5 | #:pkgdesc, "GnuPG cryptography API for package signature verification", |
| 6 | #:arch, [#:x86-64, #:aarch64], |
| 7 | #:url, "https://gnupg.org/software/gpgme/", |
| 8 | #:license, "LGPL-2.1-or-later", |
| 9 | #:depends, ["musl", "libgpg-error", "libassuan"], |
| 10 | ; The vpac runtime adds GnuPG for the OpenPGP engine. |
| 11 | #:source, ["https://www.gnupg.org/ftp/gcrypt/gpgme/gpgme-1.24.1.tar.bz2", |
| 12 | "https://raw.githubusercontent.com/alpinelinux/aports/a7de3e63cc8015474a4feadd8bb7c0ecc097b1fa/community/gpgme/lfs64.patch", "context.c"], |
| 13 | #:sha256sums, ["ea05d0258e71061d61716584ec34cef59330a91340571edc46b78374973ba85f", |
| 14 | "12bebd3d827910a58d4348cd107e0698ed4bb89a2a704cae950548f10b1a0b78", |
| 15 | "dc13a94a479b1fdeb3bb2062b72748a3f6e22f9dd5ffaa3cee235c00c5efe883"], |
| 16 | #:prepare, fn() { |
| 17 | run("patch", "--batch", "-d", "gpgme-1.24.1", "-p1", "-i", "../lfs64.patch") |
| 18 | }, |
| 19 | #:build, fn() { |
| 20 | root := get-environment-variable("VPAC_MAKEPKG_ROOT") |
| 21 | run("vinix-configure", "gpgme-1.24.1/configure", "--enable-languages=", "--disable-gpg-test", |
| 22 | string-append("--with-libgpg-error-prefix=", root, "/usr"), string-append("--with-libassuan-prefix=", root, "/usr")) |
| 23 | run("make") |
| 24 | }, |
| 25 | #:check, fn() { |
| 26 | run("vinix-cc", "-Isrc", "context.c", "-Lsrc/.libs", "-lgpgme", "-o", "context") |
| 27 | run("vinix-run", "--library-path", "src/.libs", "./context") |
| 28 | }, |
| 29 | #:package, fn() { |
| 30 | run("make", "install", string-append("DESTDIR=", pkgdir())) |
| 31 | run("rm", "-f", string-append(pkgdir(), "/usr/share/info/dir")) |
| 32 | run("find", pkgdir(), "-name", "*.la", "-delete") |
| 33 | run("install", "-Dm644", "gpgme-1.24.1/COPYING.LESSER", string-append(pkgdir(), "/usr/share/licenses/gpgme/COPYING.LESSER")) |
| 34 | }) |
| 35 | |