summary refs log tree commit diff
path: root/pkgs/os-specific/linux/iptables/default.nix
blob: 0b4b492d3180201670f64135fd4fd3eea181e1d7 (plain) (blame)
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
{stdenv, fetchurl}:

stdenv.mkDerivation rec {
  name = "iptables-1.4.8";

  src = fetchurl {
    url = "http://www.netfilter.org/projects/iptables/files/${name}.tar.bz2";
    sha256 = "1d6wykz1x2h0hp03akpm5gdgnamb1ij1nxzx3w3lhdvbzjwpbaxq";
  };

  # Install header files required by miniupnpd.
  postInstall =
    ''
      cp include/iptables.h $out/include
      cp include/libiptc/libiptc.h include/libiptc/ipt_kernel_headers.h $out/include/libiptc
      mkdir $out/include/iptables
      cp include/iptables/internal.h $out/include/iptables
      mkdir $out/include/net
      cp -prd include/net/netfilter $out/include/net/netfilter
      mkdir $out/include/linux
    '';

  meta = {
    description = "A program to configure the Linux IP packet filtering ruleset";
    homepage = http://www.netfilter.org/projects/iptables/index.html;
  };
}