Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib, stdenv, fetchurl }:
2
3let
4 version = "2.5.1";
5in stdenv.mkDerivation rec {
6 pname = "libgnurx";
7 inherit version;
8 src = fetchurl {
9 url = "mirror://sourceforge/mingw/Other/UserContributed/regex/mingw-regex-${version}/mingw-${pname}-${version}-src.tar.gz";
10 sha256 = "0xjxcxgws3bblybw5zsp9a4naz2v5bs1k3mk8dw00ggc0vwbfivi";
11 };
12
13 # file looks for libgnurx.a when compiling statically
14 postInstall = lib.optionalString stdenv.hostPlatform.isStatic ''
15 ln -s $out/lib/libgnurx{.dll.a,.a}
16 '';
17
18 meta = {
19 platforms = lib.platforms.windows;
20 };
21}