tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
file: Add `meta.pkgConfigModules` and test
Meet Barot
2 years ago
8264bd8b
af55c599
+10
-5
1 changed file
expand all
collapse all
unified
split
pkgs
tools
misc
file
default.nix
+10
-5
pkgs/tools/misc/file/default.nix
···
1
1
-
{ lib, stdenv, fetchurl, file, zlib, libgnurx }:
1
1
+
{ lib, stdenv, fetchurl, file, zlib, libgnurx
2
2
+
, testers
3
3
+
}:
2
4
3
5
# Note: this package is used for bootstrapping fetchurl, and thus
4
6
# cannot use fetchpatch! All mutable patches (generated by GitHub or
5
7
# cgit) that are needed here should be included directly in Nixpkgs as
6
8
# files.
7
9
8
8
-
stdenv.mkDerivation rec {
10
10
+
stdenv.mkDerivation (finalAttrs: {
9
11
pname = "file";
10
12
version = "5.45";
11
13
12
14
src = fetchurl {
13
15
urls = [
14
14
-
"https://astron.com/pub/file/${pname}-${version}.tar.gz"
15
15
-
"https://distfiles.macports.org/file/${pname}-${version}.tar.gz"
16
16
+
"https://astron.com/pub/file/${finalAttrs.pname}-${finalAttrs.version}.tar.gz"
17
17
+
"https://distfiles.macports.org/file/${finalAttrs.pname}-${finalAttrs.version}.tar.gz"
16
18
];
17
19
hash = "sha256-/Jf1ECm7DiyfTjv/79r2ePDgOe6HK53lwAKm0Jx4TYI=";
18
20
};
···
37
39
38
40
makeFlags = lib.optional stdenv.hostPlatform.isWindows "FILE_COMPILE=file";
39
41
42
42
+
passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage;
43
43
+
40
44
meta = with lib; {
41
45
homepage = "https://darwinsys.com/file";
42
46
description = "A program that shows the type of files";
43
47
maintainers = with maintainers; [ doronbehar ];
44
48
license = licenses.bsd2;
49
49
+
pkgConfigModules = [ "libmagic" ];
45
50
platforms = platforms.all;
46
51
mainProgram = "file";
47
52
};
48
48
-
}
53
53
+
})