Accepting request 491660 from home:jengelh:dev
OBS-URL: https://build.opensuse.org/request/show/491660 OBS-URL: https://build.opensuse.org/package/show/devel:tools/hfst?expand=0&rev=1
This commit is contained in:
commit
978d64d854
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
## Default LFS
|
||||||
|
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.png filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||||
|
*.zst filter=lfs diff=lfs merge=lfs -text
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
.osc
|
3
hfst-3.12.2.tar.gz
Normal file
3
hfst-3.12.2.tar.gz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:1573c2d91f3834687fb4e2cbe950c3f08e6794293996c8afeb0d5a941c48a4a3
|
||||||
|
size 3285488
|
36
hfst-nodate.diff
Normal file
36
hfst-nodate.diff
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
Date: 2014-09-12 12:01:59.975770528 +0200
|
||||||
|
From: Jan Engelhardt <jengelh@inai.de>
|
||||||
|
|
||||||
|
__DATE__ and __TIME__ is useless because we may rebuild regularly,
|
||||||
|
automatically, and when we do, it changes the binary output for
|
||||||
|
no reason, defeating the "same result" checker.
|
||||||
|
|
||||||
|
---
|
||||||
|
tools/src/hfst-optimized-lookup.cc | 1 -
|
||||||
|
tools/src/hfst-proc/hfst-proc.cc | 1 -
|
||||||
|
2 files changed, 2 deletions(-)
|
||||||
|
|
||||||
|
Index: hfst-3.12.2/tools/src/hfst-optimized-lookup.cc
|
||||||
|
===================================================================
|
||||||
|
--- hfst-3.12.2.orig/tools/src/hfst-optimized-lookup.cc
|
||||||
|
+++ hfst-3.12.2/tools/src/hfst-optimized-lookup.cc
|
||||||
|
@@ -97,7 +97,6 @@ bool print_version(void)
|
||||||
|
std::cout <<
|
||||||
|
"\n" <<
|
||||||
|
PACKAGE_STRING << std::endl <<
|
||||||
|
- __DATE__ << " " __TIME__ << std::endl <<
|
||||||
|
"copyright (C) 2009 University of Helsinki\n";
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
Index: hfst-3.12.2/tools/src/hfst-proc/hfst-proc.cc
|
||||||
|
===================================================================
|
||||||
|
--- hfst-3.12.2.orig/tools/src/hfst-proc/hfst-proc.cc
|
||||||
|
+++ hfst-3.12.2/tools/src/hfst-proc/hfst-proc.cc
|
||||||
|
@@ -154,7 +154,6 @@ bool print_version(void)
|
||||||
|
" (" << PACKAGE_STRING << ")" <<
|
||||||
|
#endif
|
||||||
|
std::endl <<
|
||||||
|
- __DATE__ << " " __TIME__ << std::endl <<
|
||||||
|
"copyright (C) 2009-2011 University of Helsinki\n";
|
||||||
|
return true;
|
||||||
|
}
|
28
hfst-scripts-install.diff
Normal file
28
hfst-scripts-install.diff
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
Date: 2014-09-12 12:01:17.376375609 +0200
|
||||||
|
From: Jan Engelhardt <jengelh@inai.de>
|
||||||
|
|
||||||
|
build: resolve bogus installation of hfst_foma causing trouble
|
||||||
|
|
||||||
|
hsft_foma is not a script, and it is installed by
|
||||||
|
back-ends/foma/Makefile.am already. Do not install it twice.
|
||||||
|
|
||||||
|
---
|
||||||
|
scripts/Makefile.am | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
Index: hfst-3.12.2/scripts/Makefile.am
|
||||||
|
===================================================================
|
||||||
|
--- hfst-3.12.2.orig/scripts/Makefile.am
|
||||||
|
+++ hfst-3.12.2/scripts/Makefile.am
|
||||||
|
@@ -16,9 +16,9 @@
|
||||||
|
## along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
if GENERATE_FOMA_WRAPPER
|
||||||
|
-bin_SCRIPTS = hfst-foma-wrapper.sh hfst-foma ${top_srcdir}/back-ends/foma/hfst_foma$(EXEEXT)
|
||||||
|
+bin_SCRIPTS = hfst-foma-wrapper.sh hfst-foma
|
||||||
|
EXTRA_DIST=hfst-foma generate-cc-files.sh
|
||||||
|
-AM_INSTALLCHECK_STD_OPTIONS_EXEMPT=hfst-foma-wrapper.sh hfst-foma ${top_srcdir}/back-ends/foma/hfst_foma$(EXEEXT)
|
||||||
|
+AM_INSTALLCHECK_STD_OPTIONS_EXEMPT=hfst-foma-wrapper.sh hfst-foma
|
||||||
|
else
|
||||||
|
EXTRA_DIST=generate-cc-files.sh
|
||||||
|
endif
|
60
hfst-split-libs.diff
Normal file
60
hfst-split-libs.diff
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
From: Jan Engelhardt <jengelh@inai.de>
|
||||||
|
Date: 2014-09-12 10:29:55.446630599 +0200
|
||||||
|
X-Upstream: likely not
|
||||||
|
|
||||||
|
Install sublibraries such that we can make them separate packages
|
||||||
|
and tag these with their licenses.
|
||||||
|
---
|
||||||
|
back-ends/foma/Makefile.am | 6 +++++-
|
||||||
|
back-ends/openfst/src/lib/Makefile.am | 3 ++-
|
||||||
|
back-ends/sfst/Makefile.am | 3 ++-
|
||||||
|
3 files changed, 9 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
Index: hfst-3.12.2/back-ends/foma/Makefile.am
|
||||||
|
===================================================================
|
||||||
|
--- hfst-3.12.2.orig/back-ends/foma/Makefile.am
|
||||||
|
+++ hfst-3.12.2/back-ends/foma/Makefile.am
|
||||||
|
@@ -8,12 +8,16 @@ if WANT_MINGW
|
||||||
|
AM_CPPFLAGS += -D__NO_MINGW_LFS
|
||||||
|
endif
|
||||||
|
|
||||||
|
-noinst_LTLIBRARIES = libfoma.la
|
||||||
|
+lib_LTLIBRARIES = libfoma.la
|
||||||
|
+libfoma_la_LDFLAGS = -release hfst -version-number 0 -no-undefined
|
||||||
|
libfoma_la_SOURCES = int_stack.c define.c determinize.c apply.c \
|
||||||
|
rewrite.c lexcread.c topsort.c flags.c minimize.c reverse.c \
|
||||||
|
extract.c sigma.c structures.c constructions.c \
|
||||||
|
coaccessible.c io.c utf8.c spelling.c dynarray.c mem.c stringhash.c \
|
||||||
|
trie.c lex.lexc.c lex.yy.c regex.c
|
||||||
|
+if GENERATE_FOMA_WRAPPER
|
||||||
|
+libfoma_la_LIBADD = -lz
|
||||||
|
+endif
|
||||||
|
|
||||||
|
hfst_foma_LDADD = $(top_builddir)/back-ends/foma/libfoma.la
|
||||||
|
|
||||||
|
Index: hfst-3.12.2/back-ends/openfst/src/lib/Makefile.am
|
||||||
|
===================================================================
|
||||||
|
--- hfst-3.12.2.orig/back-ends/openfst/src/lib/Makefile.am
|
||||||
|
+++ hfst-3.12.2/back-ends/openfst/src/lib/Makefile.am
|
||||||
|
@@ -11,6 +11,7 @@
|
||||||
|
|
||||||
|
AUTOMAKE_OPTIONS=subdir-objects
|
||||||
|
AM_CPPFLAGS = -I $(srcdir)/../include $(ICU_CPPFLAGS)
|
||||||
|
-noinst_LTLIBRARIES = libfst.la
|
||||||
|
+lib_LTLIBRARIES = libfst.la
|
||||||
|
+libfst_la_LDFLAGS = -release hfst -version-number 0 -no-undefined
|
||||||
|
libfst_la_SOURCES = compat.cc flags.cc fst.cc properties.cc \
|
||||||
|
symbol-table.cc symbol-table-ops.cc util.cc
|
||||||
|
Index: hfst-3.12.2/back-ends/sfst/Makefile.am
|
||||||
|
===================================================================
|
||||||
|
--- hfst-3.12.2.orig/back-ends/sfst/Makefile.am
|
||||||
|
+++ hfst-3.12.2/back-ends/sfst/Makefile.am
|
||||||
|
@@ -1,6 +1,7 @@
|
||||||
|
AM_CPPFLAGS=-Wno-deprecated
|
||||||
|
|
||||||
|
-noinst_LTLIBRARIES = libsfst.la
|
||||||
|
+lib_LTLIBRARIES = libsfst.la
|
||||||
|
+libsfst_la_LDFLAGS = -release hfst -version-number 0 -no-undefined
|
||||||
|
libsfst_la_SOURCES = alphabet.cc basic.cc utf8.cc compact.cc fst.cc \
|
||||||
|
operators.cc determinise.cc generate.cc hopcroft.cc
|
||||||
|
|
41
hfst-wrong-flags.diff
Normal file
41
hfst-wrong-flags.diff
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
Date: 2014-09-12 11:37:08.444984219 +0200
|
||||||
|
From: Jan Engelhardt <jengelh@inai.de>
|
||||||
|
|
||||||
|
build: fix potential linking hazards
|
||||||
|
|
||||||
|
-L/-l belong into LDADD/LIBADD, *not* LDFLAGS.
|
||||||
|
|
||||||
|
---
|
||||||
|
back-ends/foma/Makefile.am | 11 +++++------
|
||||||
|
1 file changed, 5 insertions(+), 6 deletions(-)
|
||||||
|
|
||||||
|
Index: hfst-3.12.2/back-ends/foma/Makefile.am
|
||||||
|
===================================================================
|
||||||
|
--- hfst-3.12.2.orig/back-ends/foma/Makefile.am
|
||||||
|
+++ hfst-3.12.2/back-ends/foma/Makefile.am
|
||||||
|
@@ -17,20 +17,19 @@ libfoma_la_SOURCES = int_stack.c define.
|
||||||
|
|
||||||
|
hfst_foma_LDADD = $(top_builddir)/back-ends/foma/libfoma.la
|
||||||
|
|
||||||
|
+hfst_foma_LDADD += -lz
|
||||||
|
if WANT_READLINE
|
||||||
|
-hfst_foma_LDFLAGS=-lreadline -lz
|
||||||
|
-else
|
||||||
|
-hfst_foma_LDFLAGS=-lz
|
||||||
|
+hfst_foma_LDADD += -lreadline
|
||||||
|
endif
|
||||||
|
|
||||||
|
if HAVE_TERMCAP
|
||||||
|
-hfst_foma_LDFLAGS += -ltermcap
|
||||||
|
+hfst_foma_LDADD += -ltermcap
|
||||||
|
else
|
||||||
|
if HAVE_NCURSES
|
||||||
|
-hfst_foma_LDFLAGS += -lncurses
|
||||||
|
+hfst_foma_LDADD += -lncurses
|
||||||
|
else
|
||||||
|
if HAVE_CURSES
|
||||||
|
-hfst_foma_LDFLAGS += -lcurses
|
||||||
|
+hfst_foma_LDADD += -lcurses
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
endif
|
12
hfst.changes
Normal file
12
hfst.changes
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Apr 27 16:53:12 UTC 2017 - jengelh@inai.de
|
||||||
|
|
||||||
|
- Update to new upstream release 3.12.2
|
||||||
|
* Implement hfst-twolc as a single program instead of a script. Get
|
||||||
|
rid of hfst-twolc-system and hfst-twolc-loc tools.
|
||||||
|
- Remove hfst-badcode.diff (applied upstream)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Sep 11 22:28:33 UTC 2014 - jengelh@inai.de
|
||||||
|
|
||||||
|
- Initial package for build.opensuse.org (version 3.7.2)
|
168
hfst.spec
Normal file
168
hfst.spec
Normal file
@ -0,0 +1,168 @@
|
|||||||
|
#
|
||||||
|
# spec file for package hfst
|
||||||
|
#
|
||||||
|
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||||
|
#
|
||||||
|
# All modifications and additions to the file contributed by third parties
|
||||||
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
|
# upon. The license for this file, and modifications and additions to the
|
||||||
|
# file, is the same license as for the pristine package itself (unless the
|
||||||
|
# license for the pristine package is not an Open Source License, in which
|
||||||
|
# case the license is the MIT License). An "Open Source License" is a
|
||||||
|
# license that conforms to the Open Source Definition (Version 1.9)
|
||||||
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||||
|
#
|
||||||
|
|
||||||
|
|
||||||
|
Name: hfst
|
||||||
|
Version: 3.12.2
|
||||||
|
Release: 0
|
||||||
|
Summary: Helsinki Finite-State Transducer Technology
|
||||||
|
License: GPL-3.0+ and GPL-3.0 and GPL-2.0+ and GPL-2.0 and GPL-3.0 and Apache-2.0
|
||||||
|
Group: Development/Tools/Other
|
||||||
|
Url: http://www.ling.helsinki.fi/kieliteknologia/tutkimus/hfst/
|
||||||
|
|
||||||
|
Source: https://github.com/hfst/hfst/releases/download/v%version/hfst-%version.tar.gz
|
||||||
|
Patch2: hfst-wrong-flags.diff
|
||||||
|
Patch3: hfst-split-libs.diff
|
||||||
|
Patch4: hfst-scripts-install.diff
|
||||||
|
Patch5: hfst-nodate.diff
|
||||||
|
BuildRequires: autoconf
|
||||||
|
BuildRequires: automake
|
||||||
|
BuildRequires: bison
|
||||||
|
BuildRequires: doxygen
|
||||||
|
BuildRequires: fdupes
|
||||||
|
BuildRequires: flex
|
||||||
|
BuildRequires: gcc-c++
|
||||||
|
BuildRequires: libtool
|
||||||
|
BuildRequires: ncurses-devel
|
||||||
|
BuildRequires: pkg-config
|
||||||
|
BuildRequires: python
|
||||||
|
BuildRequires: readline-devel
|
||||||
|
BuildRequires: pkgconfig(glib-2.0)
|
||||||
|
BuildRequires: pkgconfig(libxml-2.0)
|
||||||
|
BuildRequires: pkgconfig(zlib)
|
||||||
|
Requires: grep
|
||||||
|
Requires: sed
|
||||||
|
|
||||||
|
%description
|
||||||
|
The Helsinki Finite-State Transducer software is intended for the
|
||||||
|
implementation of morphological analyzers and other tools which are
|
||||||
|
based on weighted and unweighted finite-state transducer technology.
|
||||||
|
|
||||||
|
%package -n libfoma-hfst0
|
||||||
|
Summary: Multi-purpose finite-state toolkit
|
||||||
|
Group: System/Libraries
|
||||||
|
License: GPL-2.0
|
||||||
|
|
||||||
|
%description -n libfoma-hfst0
|
||||||
|
Foma is a multi-purpose finite-state toolkit designed for
|
||||||
|
applications ranging from natural language processing and research in
|
||||||
|
automata theory. It should be upwardly compatible with Xerox xfst and
|
||||||
|
lexc, with the exception of binary file reading and writing.
|
||||||
|
|
||||||
|
%package -n libfst-hfst0
|
||||||
|
Summary: OpenFST Finite State Transducer library
|
||||||
|
Group: System/Libraries
|
||||||
|
License: Apache-2.0
|
||||||
|
|
||||||
|
%description -n libfst-hfst0
|
||||||
|
OpenFst is a library for constructing, combining, optimizing, and
|
||||||
|
searching weighted finite-state transducers (FSTs).
|
||||||
|
|
||||||
|
%package -n libhfst49
|
||||||
|
Summary: Helsinki Finite-State Transducer Technology Libraries
|
||||||
|
Group: System/Libraries
|
||||||
|
License: GPL-3.0
|
||||||
|
|
||||||
|
%description -n libhfst49
|
||||||
|
The Helsinki Finite-State Transducer software is intended for the
|
||||||
|
implementation of morphological analyzers and other tools which are
|
||||||
|
based on weighted and unweighted finite-state transducer technology.
|
||||||
|
|
||||||
|
%package -n libsfst-hfst0
|
||||||
|
Summary: SFST Finite State Tools
|
||||||
|
Group: System/Libraries
|
||||||
|
License: GPL-2.0
|
||||||
|
# HFST is missing the license file; a look in SFST upstream code
|
||||||
|
# (https://code.google.com/p/cistern/wiki/SFST) reveals it is GPL-2.0.
|
||||||
|
|
||||||
|
%description -n libsfst-hfst0
|
||||||
|
SFST is a toolkit for the implementation of morphological analyzers
|
||||||
|
and other tools which are based on finite state transducer
|
||||||
|
technology.
|
||||||
|
|
||||||
|
%package devel
|
||||||
|
Summary: Development files for the Helsinki Finite-State Transducer
|
||||||
|
Group: Development/Libraries/C and C++
|
||||||
|
License: GPL-3.0
|
||||||
|
Requires: libhfst49 = %version
|
||||||
|
|
||||||
|
%description devel
|
||||||
|
The Helsinki Finite-State Transducer software is intended for the
|
||||||
|
implementation of morphological analyzers and other tools which are
|
||||||
|
based on weighted and unweighted finite-state transducer technology.
|
||||||
|
|
||||||
|
This subpackage contains the files necessary to build programs that
|
||||||
|
want to make use of the HFST library.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q
|
||||||
|
%patch -P 2 -P 3 -P 4 -P 5 -p1
|
||||||
|
|
||||||
|
%build
|
||||||
|
autoreconf -fiv
|
||||||
|
%configure --disable-static --with-unicode-handler=glib --with-readline \
|
||||||
|
--enable-all-tools --includedir="%_includedir/%name"
|
||||||
|
make %{?_smp_mflags}
|
||||||
|
|
||||||
|
%install
|
||||||
|
%make_install
|
||||||
|
rm -f "%buildroot/%_libdir"/*.la
|
||||||
|
# headers not installed
|
||||||
|
rm -f "%buildroot/%_libdir/"{libfoma,libfst,libsfst}.so
|
||||||
|
%fdupes %buildroot/%_prefix
|
||||||
|
|
||||||
|
%post -n libfoma-hfst0 -p /sbin/ldconfig
|
||||||
|
%postun -n libfoma-hfst0 -p /sbin/ldconfig
|
||||||
|
%post -n libfst-hfst0 -p /sbin/ldconfig
|
||||||
|
%postun -n libfst-hfst0 -p /sbin/ldconfig
|
||||||
|
%post -n libhfst49 -p /sbin/ldconfig
|
||||||
|
%postun -n libhfst49 -p /sbin/ldconfig
|
||||||
|
%post -n libsfst-hfst0 -p /sbin/ldconfig
|
||||||
|
%postun -n libsfst-hfst0 -p /sbin/ldconfig
|
||||||
|
|
||||||
|
%files
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%_bindir/hfst*
|
||||||
|
%_mandir/man1/*.1*
|
||||||
|
%doc AUTHORS COPYING NEWS README
|
||||||
|
|
||||||
|
%files -n libfoma-hfst0
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%_libdir/libfoma-hfst.so.0*
|
||||||
|
%doc back-ends/foma/COPYING
|
||||||
|
|
||||||
|
%files -n libfst-hfst0
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%_libdir/libfst-hfst.so.0*
|
||||||
|
%doc back-ends/openfst/COPYING
|
||||||
|
|
||||||
|
%files -n libhfst49
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%_libdir/libhfst.so.49*
|
||||||
|
|
||||||
|
%files -n libsfst-hfst0
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%_libdir/libsfst-hfst.so.0*
|
||||||
|
|
||||||
|
%files devel
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%_includedir/*
|
||||||
|
%_libdir/libhfst.so
|
||||||
|
%_libdir/pkgconfig/*.pc
|
||||||
|
%_datadir/aclocal/
|
||||||
|
|
||||||
|
%changelog
|
Loading…
Reference in New Issue
Block a user