From 3617be6fd74030fd18e64cfae43adb51ed5312bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?B=C3=B8rre=20Gaup?= Date: Tue, 3 Sep 2024 10:09:44 +0200 Subject: [PATCH] Updated Linux instructions --- infra/GettingStartedOnLinux.md | 111 +++------------------------------ 1 file changed, 10 insertions(+), 101 deletions(-) diff --git a/infra/GettingStartedOnLinux.md b/infra/GettingStartedOnLinux.md index b6e0eafb..e4ec9374 100644 --- a/infra/GettingStartedOnLinux.md +++ b/infra/GettingStartedOnLinux.md @@ -6,109 +6,18 @@ Note that this documentation is relevant when you want to participate in **build ## Installing required auxiliary programs -You need a number of tools for the build chain. Installation **differs** depending on what Linux distribution you have, Ubuntu, Fedora or Centos: +### Add the apertium nightly repository -### Ubuntu (all this in one command) +`wget https://apertium.projectjj.com/apt/install-nightly.sh -O - | sudo bash` -``` -sudo apt-get install autoconf automake libtool libsaxonb-java python3-pip \ -python3-lxml python3-bs4 python3-html5lib libxml-twig-perl antiword xsltproc \ -poppler-utils wget python3-svn wv python3-feedparser subversion openjdk-11-jdk cmake \ -python3-tidylib python3-yaml libxml-libxml-perl libtext-brew-perl icu-devtools -``` - -### Fedora (18) (this is 3 separate commands) - -``` -sudo yum install autoconf automake libtool saxon python-pip \ -python-lxml python-beautifulsoup4 python3-PyYAML \ -python-unittest2 perl-XML-Twig antiword pysvn wv libxslt poppler python-tidy \ -wget python-feedparser subversion java-1.7.0-openjdk cmake cpan perl-XML-LibXML - -sudo pip install pyth pytidylib - -sudo cpan install Text::Brew -``` - -### Centos 6.4 (this is 3 separate commands) - -``` -sudo yum install autoconf automake libtool saxon python-pip \ -python-lxml python-beautifulsoup4 \ -python-unittest2 perl-XML-Twig antiword libxslt poppler \ -wget python-feedparser wv pysvn subversion java-1.7.0-openjdk cmake cpan perl-XML-LibXML +Install development tools (this is for Debian-based systems, e.g. Ubuntu. For Fedora systems, use `dnf` to install packages). -sudo pip install pyth pytidylib - -sudo cpan install Text::Brew +```sh +sudo apt-get install hfst apertium-dev cg3 divvun-gramcheck \ +python3-libdivvun autoconf automake libtool libsaxonb-java xsltproc \ +poppler-utils wget git subversion openjdk-11-jdk cmake \ +python3-yaml icu-devtools python3-corpustools python3-gtgramtools \ +apertium-all-dev libdivvun-dev libhfst-dev git git-lfs ``` -# Installing HFST, our linguistic compiler - -You need tools to convert your linguistic source code (lexicons, morphology, -phonology, syntax, etc.) into usefull tools like analysers, generators, -hyphenators and spellers. - -**NB!** The information below is up-to-date as of **HFST 3.16**. - -Run **ONE OF** these sets of commands (_ubuntu_ **or** _fedora_, if you installed Linux-on-Windows as part of this documentation, you should choose the **ubuntu** commands): - -\*\*On all Linux distros: get the `install-nightly.sh` file - -``` -wget https://apertium.projectjj.com/apt/install-nightly.sh -O - | sudo bash -``` - -Thereafter, the different distros have different installation commands: - -**On Linux ubuntu:** - -``` -sudo apt-get -f install apertium-all-dev -``` - -**On Linux centos (e.g. on gtlab, gtweb):** - -``` -sudo yum install apertium-all-devel -``` - -**On Linux fedora (e.g. on gtlab, gtweb):** - -``` -sudo dnf install apertium-all-devel -``` - -The shell script will download and install prebuilt binaries for these three programs for morphology, syntax and machine translations: - -- hfst -- vislcg3 -- apertium - -You get the latest version of all required tools in one go, no compilation required! :) -Rerun with regular intervals to get the latest updates. - -This is our default compiler, and it builds all our tools. It is open source, and it is needed for turning your morphology and lexicon into spellcheckers and other useful programs. - -# Some alternative compilers, strictly speaking not needed - -The following two programs are **not needed**, we just refer to them since the source code is compatible with them: - -- If you need a fast compiler for development work you may also install the [Xerox tools](https://web.archive.org/web/20220303052838/https://web.stanford.edu/~laurik/fsmbook/home.html). - It is freely available but is not open source and can not turn the analysers into spellers. The software itself is found under the link - [NewSoftware](https://web.archive.org/web/20220303052838/https://web.stanford.edu/~laurik/.book2software/), - **Binaries Only** is enough. Unpack the files and store them in e.g. - `/usr/local/bin/`. - - **Update:** Lauri Karttunen died in the spring of 2022, and his home page at Standford — with the downloadable software — is not available anymore. The software is still available via the [Wayback Machine](https://web.archive.org). The download links above are updated accordingly. -- You may also use [Foma](https://fomafst.github.io/), but for most languages on this site you will in any case need the program _hfst-twolc_ (a program in the hfst family) for the morphophonology. - -# Installing an editor - -You will need a text editor for writing the source files. Here are some suggestions: - -- [Visual Studio Code (VSCode)](https://code.visualstudio.com/docs/setup/linux) is a nice editor, running on both Windows, Linux and Mac -- [Atom](http://atom.io), see how to [install it on Linux](https://flight-manual.atom.io/getting-started/sections/installing-atom/) -- [gedit](http://projects.gnome.org/gedit/) is the traditional Linux editor -- [kate](http://kate-editor.org/) - -# Now go back to to [Getting Started page](GettingStarted.html) for the next step towards building, using and developing the linguistic analysers. +Now go back to to [Getting Started page](GettingStarted.html) for the next step towards building, using and developing the linguistic analysers.