mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-09 04:59:31 -06:00
75 lines
1.8 KiB
Plaintext
75 lines
1.8 KiB
Plaintext
To make and install GF2 (Version 2.1, 8/11/2004).
|
|
|
|
1. Unpack GF2 and go to the source directory (the place where this
|
|
INSTALL file is - so you have probably done this already!)
|
|
|
|
tar xvfz GF-2.1.tgz
|
|
cd GF-2.1/src
|
|
|
|
2. Make sure you have GHC (Glasgow Haskell Compiler), version 5.02 or later.
|
|
In Windows, you also need Cygwin.
|
|
|
|
ghc --version
|
|
|
|
3. If you are building the darcs version, run autoconf (in src/):
|
|
|
|
autoconf
|
|
|
|
4. Run configure
|
|
|
|
./configure
|
|
|
|
If you want to install the GF somewhere other than /usr/local, use
|
|
the --prefix flag. E.g.
|
|
|
|
./configure --prefix=/usr
|
|
|
|
To compile on Chalmers Solaris systems using VCS, use this configuration:
|
|
|
|
./configure CPPFLAGS="`lib__readline -I` `lib__ncurses -I`" LDFLAGS="`lib__readline -l` `lib__ncurses -l`"
|
|
|
|
If you experience problems with readline, try:
|
|
|
|
./configure --with-readline=no
|
|
|
|
You may need to run "make clean" after ./configure when you change the
|
|
readline setting.
|
|
|
|
5. Compile with make:
|
|
|
|
make
|
|
|
|
The binary is sent to the file GF/bin/gf
|
|
|
|
6. Move files to their right places:
|
|
|
|
make install
|
|
|
|
7. For a quick test:
|
|
Start gf, load a grammar and parse a string:
|
|
|
|
cd GF/grammars/basic
|
|
gf English.gf
|
|
|
|
-- when gf has started and shows the prompt >:
|
|
> p "every number is even or odd"
|
|
-- this is the response from GF:
|
|
PredA1 (Every Number) (DisjA1 Even Odd)
|
|
|
|
8. If you want to run the Java GUI, go back to GF2/src and also do
|
|
|
|
make install-java
|
|
|
|
Then edit the file GF2/bin/jgf by changing
|
|
the value of GFHOME to the location of your GF2/bin directory. Test the
|
|
GUI with some grammars:
|
|
|
|
cd ../examples/letter
|
|
gf <mkLetter.gfs
|
|
jgf Letter.gfcm
|
|
|
|
When the window opens, push the Random button.
|
|
|
|
Author: Aarne Ranta, Björn Bringert 8/11/2004 -- 18/10/2005
|
|
|