lol
1{ lib
2, stdenv
3, rustPlatform
4, fetchFromGitHub
5, pkg-config
6, openssl
7
8# darwin
9, Security
10
11# tests
12, firefox-esr-unwrapped
13, firefox-unwrapped
14, thunderbird-unwrapped
15}:
16
17let
18 pname = "dump_syms";
19 version = "2.2.2";
20in
21rustPlatform.buildRustPackage {
22 inherit pname version;
23
24 src = fetchFromGitHub {
25 owner = "mozilla";
26 repo = pname;
27 rev = "v${version}";
28 hash = "sha256-8kyicTtY7h1CDM4UGOHsppRRTraU6JLe24MKtoduiz0=";
29 };
30
31 cargoSha256 = "sha256-5WiGckh/jq7AHH3JWZL8tIsj1Gqr8iLX7IyppKsW96k=";
32
33 nativeBuildInputs = [
34 pkg-config
35 ];
36
37 buildInputs = [
38 openssl
39 ] ++ lib.optionals (stdenv.isDarwin) [
40 Security
41 ];
42
43 checkFlags = [
44 # Disable tests that require network access
45 # ConnectError("dns error", Custom { kind: Uncategorized, error: "failed to lookup address information: Temporary failure in name resolution" })) }', src/windows/pdb.rs:725:56
46 "--skip windows::pdb::tests::test_ntdll"
47 "--skip windows::pdb::tests::test_oleaut32"
48 ];
49
50 passthru.tests = {
51 inherit firefox-esr-unwrapped firefox-unwrapped thunderbird-unwrapped;
52 };
53
54 meta = with lib; {
55 changelog = "https://github.com/mozilla/dump_syms/releases/tag/v${version}";
56 description = "Command-line utility for parsing the debugging information the compiler provides in ELF or stand-alone PDB files";
57 license = licenses.asl20;
58 homepage = "https://github.com/mozilla/dump_syms/";
59 maintainers = with maintainers; [ hexa ];
60 };
61}