summaryrefslogtreecommitdiffstats
path: root/makefu/5pkgs/debmirror/default.nix
blob: d1f007de6831e58b6ec09328b0d7108f783088b2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
{ stdenv, pkgs, fetchgit }:

pkgs.perlPackages.buildPerlPackage rec {
  pname = "debmirror";
  version = "2.25";

  enableParallelBuilding = true;

  src = fetchgit {
    url = "https://anonscm.debian.org/git/collab-maint/debmirror.git";
    rev = "c77e5caa15a4ab6497db5d819614387e647ccf4e";
    sha256 = "1zp8ff9ajw22b4wradnw1hnfcpbyx5ibqzqgk6kp79nsj1dzmm0d";
  };
  preConfigure = ''
    touch Makefile.PL
  '';

  outputs = [ "out" ];

  buildPhase = ''
    make
  '';

  doCheck = false;

  installPhase = ''
    mkdir -p $out/bin $out/share/man/man1/
    cp debmirror mirror-size $out/bin
    cp debmirror.1 $out/share/man/man1/
  '';
  propagatedBuildInputs = (with pkgs.perlPackages; [ LockFileSimple LWP]) ++
    (with pkgs; [ rsync patch ed gzip diffutils findutils gnupg1 xz ]);

  meta = {
    description = "mirror apt repos";
    homepage = https://tracker.debian.org/pkg/debmirror;
    license = stdenv.lib.licenses.gpl2;
    platforms = stdenv.lib.platforms.linux;
    maintainers = with stdenv.lib.maintainers; [ makefu ];
  };
}