diff options
author | demon <demon@FreeBSD.org> | 2014-08-31 04:42:53 +0800 |
---|---|---|
committer | demon <demon@FreeBSD.org> | 2014-08-31 04:42:53 +0800 |
commit | 5aaca09379650e1d3281ee4d15b69f3d44eda671 (patch) | |
tree | 61e99ad306aa2d66d63916d4677068603ad6a0af /textproc | |
parent | 78d0203916fdc0836ce512f72883a08d543977a7 (diff) | |
download | freebsd-ports-gnome-5aaca09379650e1d3281ee4d15b69f3d44eda671.tar.gz freebsd-ports-gnome-5aaca09379650e1d3281ee4d15b69f3d44eda671.tar.zst freebsd-ports-gnome-5aaca09379650e1d3281ee4d15b69f3d44eda671.zip |
New port: kenlm.
KenLM Language Model Toolkit.
KenLM estimates, filters, and queries language models.
WWW: https://kheafield.com/code/kenlm/
Diffstat (limited to 'textproc')
-rw-r--r-- | textproc/Makefile | 1 | ||||
-rw-r--r-- | textproc/kenlm/Makefile | 27 | ||||
-rw-r--r-- | textproc/kenlm/distinfo | 2 | ||||
-rw-r--r-- | textproc/kenlm/files/patch-Jamroot | 10 | ||||
-rw-r--r-- | textproc/kenlm/files/patch-jam-files-sanity.jam | 11 | ||||
-rw-r--r-- | textproc/kenlm/pkg-descr | 5 | ||||
-rw-r--r-- | textproc/kenlm/pkg-plist | 7 |
7 files changed, 63 insertions, 0 deletions
diff --git a/textproc/Makefile b/textproc/Makefile index 65789e378431..cd9feb227dfa 100644 --- a/textproc/Makefile +++ b/textproc/Makefile @@ -324,6 +324,7 @@ SUBDIR += jrefentry SUBDIR += jshon SUBDIR += kdiff3 + SUBDIR += kenlm SUBDIR += kibana SUBDIR += kmfl-european-latin SUBDIR += kmfl-khmer diff --git a/textproc/kenlm/Makefile b/textproc/kenlm/Makefile new file mode 100644 index 000000000000..e4dbd4aba08a --- /dev/null +++ b/textproc/kenlm/Makefile @@ -0,0 +1,27 @@ +# Created by: Dmitry Sivachenko <demon@FreeBSD.org> +# $FreeBSD$ + +PORTNAME= kenlm +PORTVERSION= 20140830 +CATEGORIES= textproc +MASTER_SITES= http://kheafield.com/code/ +DISTNAME= ${PORTNAME} + +MAINTAINER= demon@FreeBSD.org +COMMENT= KenLM Language Model Toolkit + +BUILD_DEPENDS= bjam:${PORTSDIR}/devel/boost-jam +LIB_DEPENDS= libboost_thread.so:${PORTSDIR}/devel/boost-libs + +USES+= compiler:c++11-lang +USE_LDCONFIG= yes +WRKSRC= ${WRKDIR}/${PORTNAME} +MAKE_ENV+= BOOST_BUILD_PATH=${WRKSRC}/jam-files/boost-build + +do-build: + cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${LOCALBASE}/bin/bjam --toolset=${CHOSEN_COMPILER_TYPE} --with-boost=${LOCALBASE} ${_MAKE_JOBS} + +do-install: + cd ${WRKSRC}/bin && ${INSTALL_PROGRAM} lmplz fragment query filter build_binary dump_counts cat_compressed ${STAGEDIR}${PREFIX}/bin/ + +.include <bsd.port.mk> diff --git a/textproc/kenlm/distinfo b/textproc/kenlm/distinfo new file mode 100644 index 000000000000..9ff4a22d6400 --- /dev/null +++ b/textproc/kenlm/distinfo @@ -0,0 +1,2 @@ +SHA256 (kenlm.tar.gz) = e9e5d985d563ade1f0ba89a8058e9bcc5c491f77efe8b48906e8de94e9c4f569 +SIZE (kenlm.tar.gz) = 849428 diff --git a/textproc/kenlm/files/patch-Jamroot b/textproc/kenlm/files/patch-Jamroot new file mode 100644 index 000000000000..2da5ab30c245 --- /dev/null +++ b/textproc/kenlm/files/patch-Jamroot @@ -0,0 +1,10 @@ +--- Jamroot.orig 2014-04-02 19:33:24.000000000 +0400 ++++ Jamroot 2014-08-31 00:34:40.000000000 +0400 +@@ -63,6 +63,6 @@ + + install-bin-libs lm//programs util//programs kenlm ; + install-headers headers : [ glob-tree *.hh : dist include ] : . ; +-alias install : prefix-bin prefix-lib prefix-include ; ++alias install : prefix-bin prefix-lib ; + explicit headers ; + explicit install ; diff --git a/textproc/kenlm/files/patch-jam-files-sanity.jam b/textproc/kenlm/files/patch-jam-files-sanity.jam new file mode 100644 index 000000000000..344ddccb47bf --- /dev/null +++ b/textproc/kenlm/files/patch-jam-files-sanity.jam @@ -0,0 +1,11 @@ +--- jam-files/sanity.jam.orig 2014-04-21 07:58:19.000000000 +0400 ++++ jam-files/sanity.jam 2014-08-31 00:16:40.000000000 +0400 +@@ -148,7 +148,7 @@ rule boost-lib ( name macro : deps * ) { + + #Argument is e.g. 103600 + rule boost ( min-version ) { +- local cmd = "bash -c \"g++ "$(I-boost-include)" -dM -x c++ -E /dev/null -include boost/version.hpp 2>/dev/null |grep '#define BOOST_'\"" ; ++ local cmd = "bash -c \"CC "$(I-boost-include)" -dM -x c++ -E /dev/null -include boost/version.hpp 2>/dev/null |grep '#define BOOST_'\"" ; + local boost-shell = [ SHELL "$(cmd)" : exit-status ] ; + if $(boost-shell[2]) != 0 && $(CLEANING) = no { + echo Failed to run "$(cmd)" ; diff --git a/textproc/kenlm/pkg-descr b/textproc/kenlm/pkg-descr new file mode 100644 index 000000000000..5c0e6df3caa6 --- /dev/null +++ b/textproc/kenlm/pkg-descr @@ -0,0 +1,5 @@ +KenLM Language Model Toolkit. + +KenLM estimates, filters, and queries language models. + +WWW: https://kheafield.com/code/kenlm/ diff --git a/textproc/kenlm/pkg-plist b/textproc/kenlm/pkg-plist new file mode 100644 index 000000000000..92ce43cf7df5 --- /dev/null +++ b/textproc/kenlm/pkg-plist @@ -0,0 +1,7 @@ +bin/build_binary +bin/cat_compressed +bin/dump_counts +bin/filter +bin/fragment +bin/lmplz +bin/query |