forgejo-lts: 7.0.10 -> 7.0.11
[NixPkgs.git] / pkgs / by-name / re / readstat / package.nix
blob6abae18c5c66a5ad17e4542690fb7df7a8e2f737
1 { lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pkg-config, libiconv }:
3 stdenv.mkDerivation rec {
4   pname = "readstat";
5   version = "1.1.9";
7   src = fetchFromGitHub {
8     owner = "WizardMac";
9     repo = "ReadStat";
10     rev = "v${version}";
11     sha256 = "sha256-4lRJgZPB2gfaQ9fQKvDDpGhy1eDNT/nT1QmeZlCmCis=";
12   };
14   patches = [
15     (fetchpatch {
16       url = "https://github.com/WizardMac/ReadStat/commit/211c342a1cfe46fb7fb984730dd7a29ff4752f35.patch";
17       hash = "sha256-nkaEgusylVu7NtzSzBklBuOnqO9qJPovf0qn9tTE6ls=";
18     })
20     # Backport use-after-free:
21     #   https://github.com/WizardMac/ReadStat/pull/298
22     (fetchpatch {
23       url = "https://github.com/WizardMac/ReadStat/commit/718d49155e327471ed9bf4a8c157f849f285b46c.patch";
24       hash = "sha256-9hmuFa05b4JlxSzquIxXArOGhbi27A+3y5gH1IDg+R0=";
25     })
26   ];
28   nativeBuildInputs = [ pkg-config autoreconfHook ];
30   buildInputs = [ libiconv ];
32   enableParallelBuilding = true;
34   meta = {
35     homepage = "https://github.com/WizardMac/ReadStat";
36     description = "Command-line tool (+ C library) for converting SAS, Stata, and SPSS files";
37     license = lib.licenses.mit;
38     maintainers = with lib.maintainers; [ swflint ];
39     platforms = lib.platforms.all;
40   };