12 # Note: this package is used for bootstrapping fetchurl, and thus
13 # cannot use fetchpatch! All mutable patches (generated by GitHub or
14 # cgit) that are needed here should be included directly in Nixpkgs as
17 stdenv.mkDerivation rec {
22 url = "https://ftp.gnu.org/gnu/libidn/${pname}-${version}.tar.gz";
23 hash = "sha256-TCGnkbYQuVGbnQ4SuAl78vNZsS+N2SZHYRqSnmv9fWQ=";
27 # Beware: non-bootstrap libidn2 is overridden by ./hack.nix
36 enableParallelBuilding = true;
38 # The above patch causes the documentation to be regenerated, so the
39 # documentation tools are required.
40 nativeBuildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
44 buildInputs = [ libunistring ] ++ lib.optional stdenv.hostPlatform.isDarwin libiconv;
45 depsBuildBuild = [ buildPackages.stdenv.cc ];
48 homepage = "https://www.gnu.org/software/libidn/#libidn2";
49 description = "Free software implementation of IDNA2008 and TR46";
52 Libidn2 is believed to be a complete IDNA2008 and TR46 implementation,
53 but has yet to be as extensively used as the IDNA2003 Libidn library.
55 The installed C library libidn2 is dual-licensed under LGPLv3+|GPLv2+,
56 while the rest of the package is GPLv3+. See the file COPYING for
61 license = with lib.licenses; [
66 platforms = lib.platforms.all;
67 maintainers = with lib.maintainers; [ fpletz ];