@@ -8,6 +8,7 @@
;;; Copyright © 2022 Milran <milranmike@protonmail.com>
;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2023 gemmaro <gemmaro.dev@gmail.com>
+;;; Copyright © 2023 Jussi Timperi <jussi.timperi@iki.fi>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -29,6 +30,7 @@ (define-module (gnu packages language)
#:use-module (gnu packages anthy)
#:use-module (gnu packages autotools)
#:use-module (gnu packages audio)
+ #:use-module (gnu packages backup)
#:use-module (gnu packages base)
#:use-module (gnu packages compression)
#:use-module (gnu packages dbm)
@@ -40,6 +42,7 @@ (define-module (gnu packages language)
#:use-module (gnu packages gnome)
#:use-module (gnu packages gtk)
#:use-module (gnu packages ibus)
+ #:use-module (gnu packages icu4c)
#:use-module (gnu packages java)
#:use-module (gnu packages linux)
#:use-module (gnu packages llvm)
@@ -1179,3 +1182,33 @@ (define-public mecab-unidic
from the database are used as entries (heading terms).")
;; triple-licensed (at the user’s choice)
(license (list license:gpl2+ license:lgpl2.1 license:bsd-3))))
+
+(define-public hfst-ospell
+ (package
+ (name "hfst-ospell")
+ (version "0.5.3")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/hfst/hfst-ospell")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0n8zds3s3gj3fws6ghjr9cpgswasnjqr9rz4syxy2yq8n2fzb8fp"))))
+ (build-system gnu-build-system)
+ (arguments
+ (list
+ ;; Don't use obsolete XML libraries.
+ ;; see: https://github.com/hfst/hfst-ospell/issues/48
+ #:configure-flags #~'("--without-libxmlpp" "--without-tinyxml2"
+ "--enable-zhfst")))
+ (inputs (list icu4c libarchive))
+ (native-inputs (list autoconf automake libtool pkg-config))
+ (home-page "https://github.com/hfst/hfst-ospell")
+ (synopsis "HFST spell checker library and command line tool")
+ (description
+ "Minimal @acronym{HFST, Helsinki Finite-State Technology}
+optimized-lookup format based spell checker library and a demonstrational
+implementation of command line based spell checker.")
+ (license license:asl2.0)))