diff options
author | Mateusz Piotrowski <0mp@FreeBSD.org> | 2020-09-22 20:43:19 +0000 |
---|---|---|
committer | Mateusz Piotrowski <0mp@FreeBSD.org> | 2020-09-22 20:43:19 +0000 |
commit | 6df5387bc4103a1fdf7ded2ae3524cef456581e2 (patch) | |
tree | e5bd898e618d9222e69394117b92be55d9d87694 /science/crf++ | |
parent | fbc199c7c7e345de33f50865b13d7fec926e920a (diff) | |
download | ports-6df5387bc4103a1fdf7ded2ae3524cef456581e2.tar.gz ports-6df5387bc4103a1fdf7ded2ae3524cef456581e2.zip |
Update to 0.59 (latest commit)
- Change MASTER_SITES to GitHub, where upstream moved
- Apply some patches from the GitHub Pull Requests to make the port build
(upstream seems to lost some files while migrating to GitHub) and patch
some bugs
- Set licenses
- Upstream does not tag releases on GitHub, so it's all guessing what the
real version is. 0.59 is what I found in the source code.
- Install examples; they are useful to test if the port is working
- Remove old patches, they are no longer needed
- Update WWW
Notes
Notes:
svn path=/head/; revision=549633
Diffstat (limited to 'science/crf++')
-rw-r--r-- | science/crf++/Makefile | 31 | ||||
-rw-r--r-- | science/crf++/distinfo | 9 | ||||
-rw-r--r-- | science/crf++/files/patch-feature__index.cpp | 21 | ||||
-rw-r--r-- | science/crf++/pkg-descr | 2 |
4 files changed, 33 insertions, 30 deletions
diff --git a/science/crf++/Makefile b/science/crf++/Makefile index f64ca10fce04..4ab25dadee10 100644 --- a/science/crf++/Makefile +++ b/science/crf++/Makefile @@ -2,18 +2,37 @@ # $FreeBSD$ PORTNAME= crf++ -PORTVERSION= 0.54 -PORTREVISION= 1 +# 0.59 as defined in +# https://github.com/taku910/crfpp/commit/d78526835e4cfcc4822156724edda8a3839327c2 +DISTVERSION= 0.59 CATEGORIES= science math -MASTER_SITES= SF/crfpp/crfpp/${PORTVERSION} -DISTNAME= CRF++-${PORTVERSION} +PATCH_SITES= https://patch-diff.githubusercontent.com/raw/taku910/crfpp/pull/:pr +PATCHFILES= 15.patch:-p1:pr \ + 16.patch:-p1:pr MAINTAINER= ports@FreeBSD.org COMMENT= Yet Another CRF toolkit -GNU_CONFIGURE= yes -INSTALL_TARGET= install-strip +LICENSE= BSD3CLAUSE LGPL21+ +LICENSE_COMB= dual +LICENS_BSD3CLAUSE= ${WRKSRC}/BSD +LICENS_LGPLv21+ = ${WRKSRC}/LGPL + USES= libtool +USE_GITHUB= yes +GH_ACCOUNT= taku910 +GH_PROJECT= crfpp +GH_TAGNAME= 1dc92a606f874a4fe52603803364cc1d90f952fb USE_LDCONFIG= yes +GNU_CONFIGURE= yes +INSTALL_TARGET= install-strip + +PORTEXAMPLES= JapaneseNE basenp chunking seg + +OPTIONS_DEFINE= EXAMPLES + +post-install-EXAMPLES-on: + @${MKDIR} ${STAGEDIR}${EXAPLESDIR} + (cd ${WRKSRC}/example && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR}) .include <bsd.port.mk> diff --git a/science/crf++/distinfo b/science/crf++/distinfo index 70e56cf6c118..af2b11f10ae2 100644 --- a/science/crf++/distinfo +++ b/science/crf++/distinfo @@ -1,2 +1,7 @@ -SHA256 (CRF++-0.54.tar.gz) = 8dab6e9ab71212b3d223588f6855384f2b29dada0a30d450266f8990ced63354 -SIZE (CRF++-0.54.tar.gz) = 809008 +TIMESTAMP = 1600806136 +SHA256 (taku910-crfpp-0.59-1dc92a606f874a4fe52603803364cc1d90f952fb_GH0.tar.gz) = 7f70e4113dd93caa34091e7f2df03ff75370934e3450c3a3b0d0a4afb11c8bd4 +SIZE (taku910-crfpp-0.59-1dc92a606f874a4fe52603803364cc1d90f952fb_GH0.tar.gz) = 864713 +SHA256 (15.patch) = eaf3408fcadf281eba05735af830acf82950a8da82e7cc565750a8e4d31d5480 +SIZE (15.patch) = 2376 +SHA256 (16.patch) = 5f27e76c8efac6c1fd4ac41c5925bda5b5c0063801a6a65fe311ff676e53cd1b +SIZE (16.patch) = 98664 diff --git a/science/crf++/files/patch-feature__index.cpp b/science/crf++/files/patch-feature__index.cpp deleted file mode 100644 index 042fafa6d42a..000000000000 --- a/science/crf++/files/patch-feature__index.cpp +++ /dev/null @@ -1,21 +0,0 @@ ---- feature_index.cpp.orig 2018-09-01 10:26:57 UTC -+++ feature_index.cpp -@@ -34,8 +34,7 @@ int EncoderFeatureIndex::getID(const char *key) { - std::map <std::string, std::pair<int, unsigned int> >::iterator - it = dic_.find(key); - if (it == dic_.end()) { -- dic_.insert(std::make_pair<std::string, std::pair<int, unsigned int> > -- (key, std::make_pair<int, unsigned int>(maxid_, 1))); -+ dic_.insert(std::make_pair(key, std::make_pair(maxid_, 1))); - int n = maxid_; - maxid_ += (key[0] == 'U' ? y_.size() : y_.size() * y_.size()); - return n; -@@ -171,7 +170,7 @@ void EncoderFeatureIndex::shrink(size_t freq) { - const std::string &key = it->first; - - if (it->second.second >= freq) { -- old2new.insert(std::make_pair<int, int>(it->second.first, new_maxid)); -+ old2new.insert(std::make_pair(it->second.first, new_maxid)); - it->second.first = new_maxid; - new_maxid += (key[0] == 'U' ? y_.size() : y_.size() * y_.size()); - ++it; diff --git a/science/crf++/pkg-descr b/science/crf++/pkg-descr index 74979ee280eb..dfc641cdb775 100644 --- a/science/crf++/pkg-descr +++ b/science/crf++/pkg-descr @@ -5,4 +5,4 @@ designed for generic purpose and will be applied to a variety of NLP tasks, such as Named Entity Recognition, Information Extraction and Text Chunking. -WWW: http://chasen.org/~taku/software/CRF++/ +WWW: https://taku910.github.io/crfpp/ |