2021-01-15 22:18:51 +00:00
|
|
|
{lib, stdenv, fetchurl, libmtsupport, libfacet, libbtree, libmtquery, help2man} :
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "mt-utils";
|
|
|
|
version = "0.0.1alpha3";
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
src = fetchurl {
|
2021-09-18 10:52:07 +00:00
|
|
|
url = "mirror://sourceforge/multitran/mt-utils-${version}.tar.bz2";
|
2020-04-24 23:36:52 +00:00
|
|
|
sha256 = "e407702c90c5272882386914e1eeca5f6c5039393af9a44538536b94867b0a0e";
|
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ libmtsupport libfacet libbtree libmtquery help2man ];
|
|
|
|
|
|
|
|
patchPhase = ''
|
|
|
|
sed -i -e 's@\$(DESTDIR)/usr@'$out'@' \
|
|
|
|
-e 's@/usr/include/mt/support@${libmtsupport}/include/mt/support@' \
|
|
|
|
-e 's@/usr/include/btree@${libbtree}/include/btree@' \
|
|
|
|
-e 's@/usr/include/facet@${libfacet}/include/facet@' \
|
|
|
|
-e 's@/usr/include/mt/query@${libmtquery}/include/mt/query@' \
|
|
|
|
-e 's@-lmtquery@-lmtquery -lmtsupport -lfacet@' \
|
|
|
|
src/Makefile;
|
|
|
|
# Fixing multibyte locale output
|
|
|
|
sed -i -e 's@message.length()@message.length()*5@' \
|
|
|
|
src/converter.cc;
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = "http://multitran.sourceforge.net/";
|
|
|
|
description = "Multitran: simple command line utilities for dictionary maintenance";
|
2021-01-15 22:18:51 +00:00
|
|
|
license = lib.licenses.gpl2;
|
|
|
|
maintainers = with lib.maintainers; [viric];
|
|
|
|
platforms = with lib.platforms; linux;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|