diff options
Diffstat (limited to 'pkgs/applications/misc/sdcv/default.nix')
-rw-r--r-- | pkgs/applications/misc/sdcv/default.nix | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/pkgs/applications/misc/sdcv/default.nix b/pkgs/applications/misc/sdcv/default.nix new file mode 100644 index 000000000000..8ac4730de9a7 --- /dev/null +++ b/pkgs/applications/misc/sdcv/default.nix @@ -0,0 +1,31 @@ +{ stdenv, fetchurl, pkgconfig, glib, gettext }: + +stdenv.mkDerivation rec { + name= "sdcv-0.4.2"; + + meta = { + homepage = http://sdcv.sourceforge.net/; + description = "Console version of StarDict program"; + maintainers = with stdenv.lib.maintainers; [ lovek323 ]; + license = stdenv.lib.licenses.gpl2; + platforms = stdenv.lib.platforms.unix; + }; + + src = fetchurl { + url = "mirror://sourceforge/sdcv/${name}.tar.bz2"; + sha256 = "1cnyv7gd1qvz8ma8545d3aq726wxrx4km7ykl97831irx5wz0r51"; + }; + + patches = ( if stdenv.isDarwin + then [ ./sdcv.cpp.patch-darwin ./utils.hpp.patch ] + else [ ./sdcv.cpp.patch ] ); + + buildInputs = [ pkgconfig glib gettext ]; + + preBuild = '' + sed -i 's/guint32 page_size/size_t page_size/' src/lib/lib.cpp + ''; + + NIX_CFLAGS_COMPILE = "-D__GNU_LIBRARY__"; +} + |