diff --git a/doc/languages-frameworks/pkg-config.section.md b/doc/languages-frameworks/pkg-config.section.md index eecc84b4c1aa..fb6fee997d6f 100644 --- a/doc/languages-frameworks/pkg-config.section.md +++ b/doc/languages-frameworks/pkg-config.section.md @@ -6,7 +6,7 @@ Nixpkgs provides a couple of facilities for working with this tool. ## Writing packages providing pkg-config modules -Packages should set `meta.pkgConfigProvides` with the list of package config modules they provide. +Packages should set `meta.pkgConfigModules` with the list of package config modules they provide. They should also use `testers.testMetaPkgConfig` to check that the final built package matches that list. Additionally, the [`validatePkgConfig` setup hook](https://nixos.org/manual/nixpkgs/stable/#validatepkgconfig), will do extra checks on to-be-installed pkg-config modules. diff --git a/pkgs/tools/networking/curl/default.nix b/pkgs/tools/networking/curl/default.nix index 311e9e1b8c76..b91e7733ab23 100644 --- a/pkgs/tools/networking/curl/default.nix +++ b/pkgs/tools/networking/curl/default.nix @@ -33,6 +33,7 @@ , phpExtensions , python3 , tests +, testers , fetchpatch }: @@ -178,6 +179,7 @@ stdenv.mkDerivation (finalAttrs: { # Additional checking with support http3 protocol. # nginx-http3 = useThisCurl nixosTests.nginx-http3; nginx-http3 = nixosTests.nginx-http3; + pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; }; }; @@ -189,5 +191,6 @@ stdenv.mkDerivation (finalAttrs: { platforms = platforms.all; # Fails to link against static brotli or gss broken = stdenv.hostPlatform.isStatic && (brotliSupport || gssSupport); + pkgConfigModules = [ "libcurl" ]; }; }) diff --git a/pkgs/top-level/pkg-config/pkg-config-data.json b/pkgs/top-level/pkg-config/pkg-config-data.json index 61ed9098b919..758986390b22 100644 --- a/pkgs/top-level/pkg-config/pkg-config-data.json +++ b/pkgs/top-level/pkg-config/pkg-config-data.json @@ -445,6 +445,11 @@ "openssl" ] }, + "libcurl": { + "attrPath": [ + "curl" + ] + }, "libecpg": { "attrPath": [ "postgresql"