lol
1{ stdenv, fetchurl, which, bison, flex, libmaa, zlib, libtool }:
2
3stdenv.mkDerivation rec {
4 name = "dictd-${version}";
5 version = "1.12.1";
6
7 src = fetchurl {
8 url = "mirror://sourceforge/dict/dictd-${version}.tar.gz";
9 sha256 = "0min6v60b6z5mrymyjfwzx8nv6rdm8pd8phlwl6v2jl5vkngcdx2";
10 };
11
12 buildInputs = [ libmaa zlib ];
13
14 nativeBuildInputs = [ bison flex libtool which ];
15
16 # Makefile(.in) contains "clientparse.c clientparse.h: clientparse.y" which
17 # causes bison to run twice, and break the build when this happens in
18 # parallel. Test with "make -j clientparse.c clientparse.h". The error
19 # message may be "mv: cannot move 'y.tab.c' to 'clientparse.c'".
20 enableParallelBuilding = false;
21
22 patchPhase = "patch -p0 < ${./buildfix.diff}";
23 configureFlags = [
24 "--enable-dictorg"
25 "--datadir=/run/current-system/share/dictd"
26 ];
27
28 meta = with stdenv.lib; {
29 description = "Dict protocol server and client";
30 homepage = http://www.dict.org;
31 license = licenses.gpl2;
32 maintainers = with maintainers; [ ];
33 platforms = platforms.linux;
34 };
35}