gitweb on Svarog

projekti pod git sistemom za održavanje verzija -- projects under the git version control system
updates to the install tutorial by Martin Ward
[mjc2wsl.git] / docs / install-fermat-on-linux.txt
index 4b2c1a5..ef964e9 100644 (file)
@@ -1,3 +1,4 @@
+
 How to install and use FermaT on a Linux machine
 ================================================
 
@@ -16,24 +17,32 @@ Dependencies
 ============
 
 GNU Compiler Collection (C)
------------------------------
+---------------------------
 
 For building FermaT you need a working C compiler, GCC recommended. In
 Ubuntu there is a convenient package "build-essential" that will
 install most of the needed packages for building software.
 
-use:
+Debian:
+
+  sudo apt-get install build-essential
+
+Mageia:
 
- sudo apt-get install build-essential 
+  urpmi gcc make
 
-When trying to build FermaT it migh complain about a missing
-"sys/cdefs.h". This file can be found in libc6-dev package, but you
-might also need to install "libc6-dev-i386" (even though it is a 64
-bit system, the shared file is in the old library).
+Fedora:
+
+  yum install gcc make
+
+When trying to build FermaT it might complain about a missing
+"sys/cdefs.h". This file can be found in libc6-dev package,
+but you might also need to install "libc6-dev-i386" (even though
+it is a 64 bit system, the shared file is in the old library).
 
 
 Perl
-------
+----
 
 Perl is included by default, but you also need some extra modules -
 Bit::Vector and Set::IntRange.
@@ -42,67 +51,97 @@ If these modules are not installed WSL will work in most cases, but
 not all. To be sure everything is ok run "make test" and check that
 all the tests succeeded.
 
+Debian:
+
 You can use "cpanm" command from the "cpanminus" package for
 installing modules. It will automatically find and install any missing
 module dependencies.
 
 You can install them globally on the system with 
 
- sudo cpanm Bit::Vector
- sudo cpanm Set::IntRange
 sudo cpanm Bit::Vector
 sudo cpanm Set::IntRange
 
 If you don't want to (or can't) install them globally, you can
 configure local modules. Try running cpanm without sudo for
 suggestions how to do this.
 
+Mageia, Fedora and other Linux versions:
+
+If your system does not have cpanm, you can use the CPAN module directly:
+
+  sudo perl -MCPAN -e shell
+
+This will start the CPAN shell. Type:
+
+  install Set::IntRange
+
+to install Set::IntRange and Bit::Vector.
+
 
 Main build
-===========
+==========
 
 You need to download and extract fermat3:
 
- wget http://www.cse.dmu.ac.uk/~mward/fermat3.tar.gz
- tar -xf fermat3.tar.gz
+  wget http://www.cse.dmu.ac.uk/~mward/fermat3.tar.gz
+     OR
+  wget http://www.gkc.org.uk/fermat3.tar.gz
+
+  tar -xf fermat3.tar.gz
 
+To compile and test FermaT:
 
-Once you are inside the folder you need to "source" the appropriate
-DOIT file. This will set up a few environment variables that are
-needed for FermaT to work and are also needed for the build process.
+  cd fermat3
+  make test
 
-For Ubuntu this will probably be bash:
+To run the FermaT scripts from the command line (wsl, dotrans,
+make-fermat etc) you need to ensure that the fermat3/bin directory
+is in your path and the FermaT environment variable is set.
 
- cd fermat3
- source DOIT.bash
+A simple way to do this is to "source" the appropriate DOIT file
+from the fermat3 directory.
 
-After that you can start the build and test process with
+Most Linux systems use the bash shell by default:
 
-  make test
+  cd fermat3
+  source DOIT.bash
+
+If you use csh or tcsh then:
 
-If everything is already built it will skip straith to the
-testing. You want to see all tests pass.
+  cd fermat3
+  source DOIT.csh
 
-You can alternatively start the build process directly with:
+After setting the envirotment variable and path, you can recompile FermaT
+with the command:
 
   make-fermat
 
+You can test some basic WSL commands with:
+
+  test-fermat
+
+and test some transformations with:
+
+  test-trans
 
 If everything is ok you should be able to enter "wsl" in the command
 line and get a usage message.
 
 
 Running WSL
-============
+===========
 
-FermaT does not install system-wide on it's own. If you want to use it
-in a command line you need to source DOIT again.  Since DOIT.bash uses
-pwd (print working directory) you need to run it in the fermat3
-directory.
+FermaT does not install system-wide on it's own.  If you want
+to use it in a command line you need to source DOIT again.
+Since DOIT.bash uses pwd (print working directory) you need to run
+it in the fermat3 directory.
 
-Alternatively you can make a copy of the file (let's call it
-myDOIT.bash) and change the line "Fermat=`pwd` to include the install
-folder directly, for instance if we extracted fermat3 in our home:
+Alternatively you can make a copy of the file (let's call it myDOIT.bash)
+and change the line "Fermat=`pwd` to refer to the install folder directly,
+for instance if we extracted fermat3 in our home:
 
-Fermat=/home/username/fermat3
+FermaT=/home/user/fermat3
 
 You can then run that file from anywhere and it will setup the values
 properly. For instance you can put this file somewhere on the PATH. A
@@ -110,7 +149,7 @@ convenient place is to make a "bin" folder in your home if there isn't
 one already. This will be included by bash automatically. Then
 you could run 
 
- source myDOIT.bash
 source myDOIT.bash
 
 from any terminal that you want to run WSL in.
 
@@ -121,5 +160,5 @@ these lines to your .bashrc file (in the home directory).
 End notes
 =========
 
-Copyright (C) 2014 Doni Pracner; Released under the GNU Free Documentation
+Copyright (C) 2014 Doni Pracner, Martin Ward; Released under the GNU Free Documentation
 Licence https://www.gnu.org/licenses/fdl.html
Svarog.pmf.uns.ac.rs/gitweb maintanance Doni Pracner