Import textproc/libmarisa
Provided and tested on amd64, aarch64 (rpi4), and mips64el (loongson) (with reduced input) by Yifei Zhan < openbsd () zhan ! science >. OK sthen@ if someone would like to import. I am also fine with this and build and test on amd64 works fine. ok inoguchi@
This commit is contained in:
parent
82d38feae6
commit
f56132d06a
32
textproc/libmarisa/Makefile
Normal file
32
textproc/libmarisa/Makefile
Normal file
@ -0,0 +1,32 @@
|
||||
# $OpenBSD: Makefile,v 1.1 2021/09/11 07:55:18 inoguchi Exp $
|
||||
|
||||
COMMENT = C++ library for MARISA matching algorithm
|
||||
|
||||
V = 0.2.6
|
||||
PKGNAME = libmarisa-${V}
|
||||
|
||||
GH_ACCOUNT = s-yata
|
||||
GH_PROJECT = marisa-trie
|
||||
GH_TAGNAME = v${V}
|
||||
|
||||
SHARED_LIBS += marisa 0.0 # 0.0
|
||||
|
||||
CATEGORIES = textproc
|
||||
|
||||
MAINTAINER = Yifei Zhan <openbsd@zhan.science>
|
||||
|
||||
# dual license: either BSD 2-clause or LGPLv2.1+
|
||||
PERMIT_PACKAGE = Yes
|
||||
|
||||
WANTLIB += ${COMPILER_LIBCXX} c m
|
||||
|
||||
AUTOCONF_VERSION = 2.69
|
||||
AUTOMAKE_VERSION = 1.15
|
||||
CONFIGURE_STYLE = autoreconf
|
||||
CONFIGURE_ARGS = CXX="${CXX}" CXXFLAGS="${CXXFLAGS}"
|
||||
|
||||
.if ${MACHINE_ARCH} == "amd64"
|
||||
CONFIGURE_ARGS += --enable-sse2
|
||||
.endif
|
||||
|
||||
.include <bsd.port.mk>
|
2
textproc/libmarisa/distinfo
Normal file
2
textproc/libmarisa/distinfo
Normal file
@ -0,0 +1,2 @@
|
||||
SHA256 (marisa-trie-0.2.6.tar.gz) = EGOifHieda+i7m8XFsxqVIZjHc/Lf01W1khdJGLlZt4=
|
||||
SIZE (marisa-trie-0.2.6.tar.gz) = 168332
|
16
textproc/libmarisa/patches/patch-tests_marisa-test_cc
Normal file
16
textproc/libmarisa/patches/patch-tests_marisa-test_cc
Normal file
@ -0,0 +1,16 @@
|
||||
$OpenBSD: patch-tests_marisa-test_cc,v 1.1 2021/09/11 07:55:18 inoguchi Exp $
|
||||
|
||||
Fix test on OpenBSD
|
||||
|
||||
Index: tests/marisa-test.cc
|
||||
--- tests/marisa-test.cc.orig
|
||||
+++ tests/marisa-test.cc
|
||||
@@ -18,7 +18,7 @@ void TestEmptyTrie() {
|
||||
#ifdef _MSC_VER
|
||||
EXCEPT(trie.write(::_fileno(stdout)), MARISA_STATE_ERROR);
|
||||
#else // _MSC_VER
|
||||
- EXCEPT(trie.write(::fileno(stdout)), MARISA_STATE_ERROR);
|
||||
+ EXCEPT(trie.write(fileno(stdout)), MARISA_STATE_ERROR);
|
||||
#endif // _MSC_VER
|
||||
EXCEPT(std::cout << trie, MARISA_STATE_ERROR);
|
||||
EXCEPT(marisa::fwrite(stdout, trie), MARISA_STATE_ERROR);
|
5
textproc/libmarisa/pkg/DESCR
Normal file
5
textproc/libmarisa/pkg/DESCR
Normal file
@ -0,0 +1,5 @@
|
||||
Matching Algorithm with Recursively Implemented StorAge (MARISA)
|
||||
is a static and space-efficient trie data structure. And libmarisa
|
||||
is a C++ library to provide an implementation of MARISA. Also, the
|
||||
package of libmarisa contains a set of command line tools for
|
||||
building and operating a MARISA-based dictionary.
|
25
textproc/libmarisa/pkg/PLIST
Normal file
25
textproc/libmarisa/pkg/PLIST
Normal file
@ -0,0 +1,25 @@
|
||||
@comment $OpenBSD: PLIST,v 1.1 2021/09/11 07:55:18 inoguchi Exp $
|
||||
@bin bin/marisa-benchmark
|
||||
@bin bin/marisa-build
|
||||
@bin bin/marisa-common-prefix-search
|
||||
@bin bin/marisa-dump
|
||||
@bin bin/marisa-lookup
|
||||
@bin bin/marisa-predictive-search
|
||||
@bin bin/marisa-reverse-lookup
|
||||
include/marisa/
|
||||
include/marisa.h
|
||||
include/marisa/agent.h
|
||||
include/marisa/base.h
|
||||
include/marisa/exception.h
|
||||
include/marisa/iostream.h
|
||||
include/marisa/key.h
|
||||
include/marisa/keyset.h
|
||||
include/marisa/query.h
|
||||
include/marisa/scoped-array.h
|
||||
include/marisa/scoped-ptr.h
|
||||
include/marisa/stdio.h
|
||||
include/marisa/trie.h
|
||||
@static-lib lib/libmarisa.a
|
||||
lib/libmarisa.la
|
||||
@lib lib/libmarisa.so.${LIBmarisa_VERSION}
|
||||
lib/pkgconfig/marisa.pc
|
Loading…
x
Reference in New Issue
Block a user