defpkgbuild(npth, #:pkgname, "npth", #:pkgver, "1.6", #:pkgrel, 1, #:pkgdesc, "Portable threads library for GnuPG", #:arch, [#:x86-64, #:aarch64], #:url, "https://gnupg.org/related_software/npth/", #:license, "LGPL-2.0-or-later", #:depends, ["musl"], #:source, ["https://gnupg.org/ftp/gcrypt/npth/npth-1.6.tar.bz2"], #:sha256sums, ["1393abd9adcf0762d34798dc34fdcf4d0d22a8410721e76f1e3afcd1daa4e2d1"], #:build, fn() { run("vinix-configure", "npth-1.6/configure") run("make") }, #:check, fn() { run("vinix-run", "--library-path", "src/.libs", "tests/.libs/t-thread") run("vinix-run", "--library-path", "src/.libs", "tests/.libs/t-mutex") run("vinix-run", "--library-path", "src/.libs", "tests/.libs/t-fork") }, #:package, fn() { run("make", "install", string-append("DESTDIR=", pkgdir())) run("find", pkgdir(), "-name", "*.la", "-delete") run("install", "-Dm644", "npth-1.6/COPYING.LIB", string-append(pkgdir(), "/usr/share/licenses/npth/COPYING.LIB")) })