appstream: Add meta.pkgConfigModules

This commit is contained in:
Rodney Lorrimar 2024-02-10 15:32:26 +08:00
parent bac7f13ded
commit 9c0c72dd2b
No known key found for this signature in database
GPG key ID: D8B75C95FB4D1143

View file

@ -25,10 +25,11 @@
, curl , curl
, systemd , systemd
, nixosTests , nixosTests
, testers
, withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd , withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation (finalAttrs: {
pname = "appstream"; pname = "appstream";
version = "1.0.1"; version = "1.0.1";
@ -37,7 +38,7 @@ stdenv.mkDerivation rec {
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "ximion"; owner = "ximion";
repo = "appstream"; repo = "appstream";
rev = "v${version}"; rev = "v${finalAttrs.version}";
sha256 = "sha256-ULqRHepWVuAluXsXJUoqxqJfrN168MGlwdVkoLLwSN0="; sha256 = "sha256-ULqRHepWVuAluXsXJUoqxqJfrN168MGlwdVkoLLwSN0=";
}; };
@ -97,9 +98,10 @@ stdenv.mkDerivation rec {
"-Dsystemd=false" "-Dsystemd=false"
]; ];
passthru = { passthru.tests = {
tests = { installed-tests = nixosTests.installed-tests.appstream;
installed-tests = nixosTests.installed-tests.appstream; pkg-config = testers.hasPkgConfigModules {
package = finalAttrs.finalPackage;
}; };
}; };
@ -115,5 +117,6 @@ stdenv.mkDerivation rec {
license = licenses.lgpl21Plus; license = licenses.lgpl21Plus;
mainProgram = "appstreamcli"; mainProgram = "appstreamcli";
platforms = platforms.unix; platforms = platforms.unix;
pkgConfigModules = [ "appstream" ];
}; };
} })