Difference between revisions of "User:Jatinluthra14"

From Apertium
Jump to navigation Jump to search
(Formatting changes,)
Line 1: Line 1:
Installing Apertium on Slackware
+
== Installing Apertium on Slackware ==
   
This Guide is for Latest Slackware 14.1
+
This guide is for Slackware 14.1.
   
  +
=== Preparation ===
* Change user to root and Navigate to other directory:
 
   
 
Change user to root and Navigate to other directory:
su
 
  +
cd ~/Downloads
 
  +
su
 
cd ~/Downloads
   
 
Enter password(if required).
 
Enter password(if required).
   
=== Install Slapt-get ===
+
=== Install slapt-get ===
  +
 
* For i386
 
* For i386
   
wget http://software.jaos.org/slackpacks/14.1/slapt-get/slapt-get-0.10.2r-i386-1.tgz
+
wget http://software.jaos.org/slackpacks/14.1/slapt-get/slapt-get-0.10.2r-i386-1.tgz
   
 
* For x86_64
 
* For x86_64
   
wget http://software.jaos.org/slackpacks/14.1-x86_64/slapt-get/slapt-get-0.10.2r-x86_64-1.tgz
+
wget http://software.jaos.org/slackpacks/14.1-x86_64/slapt-get/slapt-get-0.10.2r-x86_64-1.tgz
   
 
Assuming x86_64:
 
Assuming x86_64:
   
* Install the Package
+
* Install slapt-get
   
<code>installpkg slapt-get-0.10.2r-x86_64-1.tgz</code>
+
installpkg slapt-get-0.10.2r-x86_64-1.tgz
   
* Upgrade using Slapt-get:
+
* Upgrade the system:
   
<code>slapt-get --upgrade</code>
+
slapt-get --upgrade
   
=== Install dependencies, needed to build Apertium ===
+
=== Install dependencies needed to build Apertium ===
* Install can be done with Slackpkg as an alternative if slapt-get does not work.
 
   
 
* For i486:
 
* For i486:
  +
<code>slapt-get --install make-3.82-i486-3 gcc-4.7.1-i486-1 kernel-headers-3.2.29_smp-x86-1 libxml2-2.8.0-i486-1 libxslt-1.1.26-i486-2 subversion-1.7.6-i486-1 pkg-config-0.25-i486-1 automake-1.11.5-noarch-1 flex-2.5.35-i486-1 libtool-2.4.2-i486-1 pcre-8.33-i486-1</code>
+
slapt-get --install make-3.82-i486-3 gcc-4.7.1-i486-1 kernel-headers-3.2.29_smp-x86-1 libxml2-2.8.0-i486-1 libxslt-1.1.26-i486-2 subversion-1.7.6-i486-1 pkg-config-0.25-i486-1 automake-1.11.5-noarch-1 flex-2.5.35-i486-1 libtool-2.4.2-i486-1 pcre-8.33-i486-1
   
 
* For x86_64:
 
* For x86_64:
<code>slapt-get --install make-3.82-x86_64-4 gcc-4.8.2-x86_64-1 kernel-headers-3.10.17-x86-3 libxml2-2.9.1-x86_64-1 libxslt-1.1.28-x86_64-1 subversion-1.7.13-x86_64-1 pkg-config-0.25-x86_64-1 automake-1.11.5-noarch-1 flex-2.5.37-x86_64-1 libtool-2.4.2-x86_64-2 pcre-8.33-x86_64-1</code>
 
   
 
slapt-get --install make-3.82-x86_64-4 gcc-4.8.2-x86_64-1 kernel-headers-3.10.17-x86-3 libxml2-2.9.1-x86_64-1 libxslt-1.1.28-x86_64-1 subversion-1.7.13-x86_64-1 pkg-config-0.25-x86_64-1 automake-1.11.5-noarch-1 flex-2.5.37-x86_64-1 libtool-2.4.2-x86_64-2 pcre-8.33-x86_64-1
   
 
=== SVN Checkout ===
 
=== SVN Checkout ===
  +
 
SVN or Apache Subversion is a software versioning and revision control system distributed as free software under the Apache License. There are many language
 
SVN or Apache Subversion is a software versioning and revision control system distributed as free software under the Apache License. There are many language
Pairs in the trunk of apertium. First we will check the repositories.
+
pairs in the Apertium repository that can be installed. Firstly, check out the repositories:
  +
<code>
 
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/lttoolbox
+
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/lttoolbox
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium
+
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium-lex-tools
+
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium-lex-tools
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium-<language-pair>
+
svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium-<language-pair>
</code>
 
   
Change <language-pair> as your requirement for eg. en-es
+
Change <language-pair> to the language pair you want eg. en-es
   
 
=== Set up environment ===
 
=== Set up environment ===
  +
This is required for proper installation of apertium. It can be added in .bashrc to prevent typing every time you restart.
+
This is required for proper installation of Apertium. This section can be added into .bashrc so that you do not need to retype these when you open up a new terminal.
LD_LIBRARY_PATH=/usr/local/lib:${LD_LIBRARY_PATH}
 
  +
export LD_LIBRARY_PATH
 
PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:${PKG_CONFIG_PATH}
+
LD_LIBRARY_PATH=/usr/local/lib:${LD_LIBRARY_PATH}
export PKG_CONFIG_PATH</code>
+
export LD_LIBRARY_PATH
  +
PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:${PKG_CONFIG_PATH}
  +
export PKG_CONFIG_PATH</code>
   
 
=== Compiling ===
 
=== Compiling ===
Line 64: Line 69:
 
Then in each directory run:
 
Then in each directory run:
   
<code>./autogen.sh
+
./autogen.sh
make
+
make
make install
+
make install
ldconfig</code>
+
ldconfig
   
 
=== Finishing up and Testing===
 
=== Finishing up and Testing===
   
 
* Now, exit root shell:
 
* Now, exit root shell:
  +
<code>exit</code>
 
  +
exit
   
 
* To test:
 
* To test:
  +
<code>echo "Hello World" | apertium <language-pair></code>
+
echo "Hello World" | apertium <language-pair>
  +
  +
== Troubleshooting ==
   
 
=== Slackpkg ===
 
=== Slackpkg ===
This section is an alternative to Slapt-get if it not works for you.
 
<code>wget http://www.slackpkg.org/stable/slackpkg-2.82.0-noarch-2.tgz</code>
 
installpkg slackpkg-2.82.0-noarch-2.tgz
 
   
 
Installation of the packages can be done with slackpkg if slapt-get does not work.
* Configure the mirrors by "pico /etc/slackpkg/mirrors"
 
  +
and commenting the mirrors not required by adding # symbol at starting of line.
 
 
wget http://www.slackpkg.org/stable/slackpkg-2.82.0-noarch-2.tgz
 
installpkg slackpkg-2.82.0-noarch-2.tgz
  +
 
* Configure the mirrors by "pico /etc/slackpkg/mirrors" and commenting out the mirrors not required by adding # symbol at starting of line.
   
 
* Update the gpg by using "slackpkg update gpg"
 
* Update the gpg by using "slackpkg update gpg"
Line 89: Line 99:
 
* Upgrade using Slackpkg:
 
* Upgrade using Slackpkg:
   
slackpkg update
+
slackpkg update
slackpkg install-new
+
slackpkg install-new
slackpkg upgrade-all
+
slackpkg upgrade-all

Revision as of 14:34, 16 December 2015

Installing Apertium on Slackware

This guide is for Slackware 14.1.

Preparation

Change user to root and Navigate to other directory:

   su
   cd ~/Downloads

Enter password(if required).

Install slapt-get

  • For i386
   wget http://software.jaos.org/slackpacks/14.1/slapt-get/slapt-get-0.10.2r-i386-1.tgz
  • For x86_64
   wget http://software.jaos.org/slackpacks/14.1-x86_64/slapt-get/slapt-get-0.10.2r-x86_64-1.tgz

Assuming x86_64:

  • Install slapt-get
   installpkg slapt-get-0.10.2r-x86_64-1.tgz
  • Upgrade the system:
   slapt-get --upgrade

Install dependencies needed to build Apertium

  • For i486:
   slapt-get --install make-3.82-i486-3 gcc-4.7.1-i486-1 kernel-headers-3.2.29_smp-x86-1 libxml2-2.8.0-i486-1 libxslt-1.1.26-i486-2 subversion-1.7.6-i486-1 pkg-config-0.25-i486-1 automake-1.11.5-noarch-1 flex-2.5.35-i486-1 libtool-2.4.2-i486-1 pcre-8.33-i486-1
  • For x86_64:
   slapt-get --install make-3.82-x86_64-4 gcc-4.8.2-x86_64-1 kernel-headers-3.10.17-x86-3 libxml2-2.9.1-x86_64-1 libxslt-1.1.28-x86_64-1 subversion-1.7.13-x86_64-1 pkg-config-0.25-x86_64-1 automake-1.11.5-noarch-1 flex-2.5.37-x86_64-1 libtool-2.4.2-x86_64-2 pcre-8.33-x86_64-1

SVN Checkout

SVN or Apache Subversion is a software versioning and revision control system distributed as free software under the Apache License. There are many language pairs in the Apertium repository that can be installed. Firstly, check out the repositories:

   svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/lttoolbox
   svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium
   svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium-lex-tools
   svn checkout https://svn.code.sf.net/p/apertium/svn/trunk/apertium-<language-pair>

Change <language-pair> to the language pair you want eg. en-es

Set up environment

This is required for proper installation of Apertium. This section can be added into .bashrc so that you do not need to retype these when you open up a new terminal.

   LD_LIBRARY_PATH=/usr/local/lib:${LD_LIBRARY_PATH}
   export LD_LIBRARY_PATH
   PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:${PKG_CONFIG_PATH}
   export PKG_CONFIG_PATH

Compiling

  • Change to each directory in order: lttoolbox, apertium, apertium-lex-tools, apertium-<language-pair> using cd

Then in each directory run:

   ./autogen.sh
   make
   make install
   ldconfig

Finishing up and Testing

  • Now, exit root shell:
exit
  • To test:
echo "Hello World" | apertium <language-pair>

Troubleshooting

Slackpkg

Installation of the packages can be done with slackpkg if slapt-get does not work.

   wget http://www.slackpkg.org/stable/slackpkg-2.82.0-noarch-2.tgz
   installpkg slackpkg-2.82.0-noarch-2.tgz
  • Configure the mirrors by "pico /etc/slackpkg/mirrors" and commenting out the mirrors not required by adding # symbol at starting of line.
  • Update the gpg by using "slackpkg update gpg"
  • Upgrade using Slackpkg:
   slackpkg update
   slackpkg install-new
   slackpkg upgrade-all