1
0
forked from GitHub/gf-core
Merge branch 'master' of www.grammaticalframework.org:/usr/local/www/GF
This commit is contained in:
Krasimir Angelov
2017-08-18 21:27:40 +02:00
15 changed files with 105 additions and 118 deletions

View File

@@ -98,14 +98,13 @@ execute command args =
showArg arg = if ' ' `elem` arg then "'" ++ arg ++ "'" else arg showArg arg = if ' ' `elem` arg then "'" ++ arg ++ "'" else arg
-- | This function is used to enable parallel compilation of the RGL and -- | This function is used to enable parallel compilation of the RGL and
-- example grammars, but it is commented out by default -- example grammars
-- to avoid casing problems for developers using Cabal<1.20
numJobs flags = numJobs flags =
if null n if null n
then ["-j","+RTS","-A20M","-N","-RTS"] then ["-j","+RTS","-A20M","-N","-RTS"]
else ["-j="++n,"+RTS","-A20M","-N"++n,"-RTS"] else ["-j="++n,"+RTS","-A20M","-N"++n,"-RTS"]
where where
-- buildNumJobs is only available in Cabal>=1.20 -- buildNumJobs is only available in Cabal>=1.20
n = {-case buildNumJobs flags of n = case buildNumJobs flags of
Flag mn | mn/=Just 1-> maybe "" show mn Flag mn | mn/=Just 1-> maybe "" show mn
_ ->-} "" _ -> ""

0
bin/build-binary-dist.sh Normal file → Executable file
View File

0
bin/gfmap Normal file → Executable file
View File

0
bin/update_html Normal file → Executable file
View File

6
debian/changelog vendored
View File

@@ -1,3 +1,9 @@
gf (3.9-1) vivid xenial zesty; urgency=low
* GF 3.9
-- Thomas Hallgren <hallgren@chalmers.se> Fri, 11 Aug 2017 20:00:00 +0200
gf (3.8-1) precise trusty vivid; urgency=low gf (3.8-1) precise trusty vivid; urgency=low
* GF 3.8 * GF 3.8

View File

@@ -7,21 +7,21 @@ Grammatical Framework Download and Installation
%!postproc(html): <TD><I> <TD><small> %!postproc(html): <TD><I> <TD><small>
%!postproc(html): </I></TD> </small></TD> %!postproc(html): </I></TD> </small></TD>
**GF 3.9** will be released on ?? August 2017. **GF 3.8** was released on 22 June 2016.
What's new? See the [Release notes release-3.9.html]. What's new? See the [Release notes release-3.8.html].
== Binary packages == == Binary packages ==
|| Platform | Download | Features | How to install || Platform | Download | Features | How to install
| macOS | [gf-3.9.pkg gf-3.9.pkg] | //GF+S+C+J+P// | Double-click on the package icon (*) | Mac OS X | [gf-3.8.pkg gf-3.8.pkg] | //GF+S+C+P// | Double-click on the package icon (*)
| macOS | [gf-3.9-bin-intel-mac.tar.gz gf-3.9-bin-intel-mac.tar.gz] | //GF+S+C+J+P// | ``sudo tar -C /usr/local -zxf gf-3.9-bin-intel-mac.tar.gz`` | Mac OS X | [gf-3.8-bin-intel-mac.tar.gz gf-3.8-bin-intel-mac.tar.gz] | //GF+S+C+P// | ``sudo tar -C /usr/local -zxf gf-3.8-bin-intel-mac.tar.gz``
%| Fedora (32-bit) | [Fedora RPMs /~hallgren/tmp/Fedora/] | //GF+S+C+J+P// | ``sudo rpm -i ...`` %| Fedora (32-bit) | [Fedora RPMs /~hallgren/tmp/Fedora/] | //GF+S+C+J+P// | ``sudo rpm -i ...``
| Ubuntu (32-bit) | [gf_3.9-1_i386.deb gf_3.9-1_i386.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.9-1_i386.deb`` | Ubuntu (32-bit) | [gf_3.8-1_i386.deb gf_3.8-1_i386.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.8-1_i386.deb``
| Ubuntu (64-bit) | [gf_3.9-1_amd64.deb gf_3.9-1_amd64.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.9-1_amd64.deb`` | Ubuntu (64-bit) | [gf_3.8-1_amd64.deb gf_3.8-1_amd64.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.8-1_amd64.deb``
| Windows | [gf-3.9-bin-windows.zip gf-3.9-bin-windows.zip] | //GF+S// | ``unzip gf-3.9-bin-windows.zip`` | Windows | [gf-3.8-bin-windows.zip gf-3.8-bin-windows.zip] | //GF+S// | ``unzip gf-3.8-bin-windows.zip``
%| MINGW | [gf-3.9-bin-i686-MINGW32_NT-6.1.tar.gz gf-3.9-bin-i686-MINGW32_NT-6.1.tar.gz] | //GF+S+C// | ``tar -C / gf-3.9-bin-i686-MINGW32_NT-6.1.tar.gz`` %| MINGW | [gf-3.8-bin-i686-MINGW32_NT-6.1.tar.gz gf-3.8-bin-i686-MINGW32_NT-6.1.tar.gz] | //GF+S+C// | ``tar -C / gf-3.8-bin-i686-MINGW32_NT-6.1.tar.gz``
%| ... | ... | ... | ... %| ... | ... | ... | ...
Features: GF = GF shell and grammar compiler and the Resource Grammar Library, Features: GF = GF shell and grammar compiler and the Resource Grammar Library,
@@ -44,14 +44,13 @@ variables, see Inari's notes on
%(which is started with ``C:\MinGW\msys\1.0\msys.bat``). %(which is started with ``C:\MinGW\msys\1.0\msys.bat``).
%It should work out of the box without any additional settings. %It should work out of the box without any additional settings.
The ``.deb`` packages should work on Ubuntu 16.04 and 17.04 and similar The ``.deb`` packages should work on Ubuntu 12.04, 14.04 and 16.04 and similar
Linux distributions. Linux distributions.
The packages for macOS (Mac OS X) should work on at The packages for Mac OS X should work on at least 10.9, 10.10 and 10.11 (Mavericks, Yosemite and El Capitan).
least 10.11 and 10.12 (El Capitan and Sierra).
(*) **Note** that for compatibility with OS X 10.11 and newer, (*) **Note** that for compatibility with OS X 10.11,
``gf-3.9.pkg`` will install the ``gf`` executable in ``/usr/local/bin`` ``gf-3.8.pkg`` will install the ``gf`` executable in ``/usr/local/bin``
instead of ``/usr/bin``, so make sure ``/usr/local/bin`` is in your ``$PATH``. instead of ``/usr/bin``, so make sure ``/usr/local/bin`` is in your ``$PATH``.
Also, if you still have an older version of GF installed in ``/usr/bin``, Also, if you still have an older version of GF installed in ``/usr/bin``,
remove it and/or make sure ``/usr/local/bin`` comes before ``/usr/bin`` remove it and/or make sure ``/usr/local/bin`` comes before ``/usr/bin``
@@ -63,7 +62,7 @@ You can install them in other locations, but then you need to set the
``GF_LIB_PATH`` environment variable: ``GF_LIB_PATH`` environment variable:
``` ```
export GF_LIB_PATH=/usr/local/share/gf-3.9/lib export GF_LIB_PATH=/usr/local/share/gf-3.8/lib
``` ```
where ``/usr/local`` should be replaced with the path to the location where you where ``/usr/local`` should be replaced with the path to the location where you
@@ -85,7 +84,7 @@ circumstances the prodedure is fairly simple:
You can also download the full source package from here: You can also download the full source package from here:
[``gf-3.9.tar.gz`` gf-3.9.tar.gz]. [``gf-3.8.tar.gz`` gf-3.8.tar.gz].
=== Notes === === Notes ===
@@ -116,21 +115,21 @@ manually. Here is one way to do this:
**Note 2**. **Note 2**.
The GF source code has been updated to compile with GHC 8.2.1. Using older The GF source code has been updated to compile with GHC 8.0.1. Using older
versions of GHC (e.g. 8.0.x and 7.10.3) should still work too. versions of GHC (7.10.3, 7.10.2, 7.8, 7.6) should work too.
%=== Known problems === === Known problems ===
%
%There seems to be a bug in some versions of Cabal that can cause There seems to be a bug in some versions of Cabal that can cause
%
%``` ```
% Distribution/Simple/PackageIndex.hs:124:8-13: Assertion failed Distribution/Simple/PackageIndex.hs:124:8-13: Assertion failed
%``` ```
%
%if the same version of GF is if the same version of GF is
%already installed. If you encounter this, you can use ``ghc-pkg unregister gf`` already installed. If you encounter this, you can use ``ghc-pkg unregister gf``
%to remove the installed version of GF and ``ghc-pkg list gf`` to verify that to remove the installed version of GF and ``ghc-pkg list gf`` to verify that
%it is gone. it is gone.
==Installing from the latest developer source code== ==Installing from the latest developer source code==
@@ -138,7 +137,7 @@ The first time:
%, assuming you already have the Haskell Platform and darcs %, assuming you already have the Haskell Platform and darcs
``` ```
git clone https://github.com/GrammaticalFramework/GF.git darcs get --lazy http://www.grammaticalframework.org/ GF
cd GF cd GF
cabal install cabal install
``` ```
@@ -147,13 +146,13 @@ Subsequently:
``` ```
cd GF cd GF
git pull darcs pull -a
cabal install cabal install
``` ```
%Alternatively, you can get the code from the Alternatively, you can get the code from the
%[GF GitHub https://github.com/GrammaticalFramework/GF/] mirror, which is [GF GitHub https://github.com/GrammaticalFramework/GF/] mirror, which is
%updated nightly. updated nightly.
The above notes for installing from source apply also in these cases. The above notes for installing from source apply also in these cases.
For more info on working with the GF source code, see the For more info on working with the GF source code, see the
@@ -161,7 +160,6 @@ For more info on working with the GF source code, see the
==Older releases== ==Older releases==
- [GF 3.8 index-3.8.html] (June 2016)
- [GF 3.7.1 index-3.7.1.html] (October 2015) - [GF 3.7.1 index-3.7.1.html] (October 2015)
- [GF 3.7 index-3.7.html] (June 2015) - [GF 3.7 index-3.7.html] (June 2015)
- [GF 3.6 index-3.6.html] (June 2014) - [GF 3.6 index-3.6.html] (June 2014)

View File

@@ -7,21 +7,22 @@ Grammatical Framework Download and Installation
%!postproc(html): <TD><I> <TD><small> %!postproc(html): <TD><I> <TD><small>
%!postproc(html): </I></TD> </small></TD> %!postproc(html): </I></TD> </small></TD>
**GF 3.8** was released on 22 June 2016. **GF 3.9** was released on 11 August 2017.
What's new? See the [Release notes release-3.8.html]. What's new? See the [Release notes release-3.9.html].
== Binary packages == == Binary packages ==
|| Platform | Download | Features | How to install || Platform | Download | Features | How to install
| Mac OS X | [gf-3.8.pkg gf-3.8.pkg] | //GF+S+C+P// | Double-click on the package icon (*) | macOS | [gf-3.9.pkg gf-3.9.pkg] | //GF+S+C+J+P// | Double-click on the package icon
| Mac OS X | [gf-3.8-bin-intel-mac.tar.gz gf-3.8-bin-intel-mac.tar.gz] | //GF+S+C+P// | ``sudo tar -C /usr/local -zxf gf-3.8-bin-intel-mac.tar.gz`` | macOS | [gf-3.9-bin-intel-mac.tar.gz gf-3.9-bin-intel-mac.tar.gz] | //GF+S+C+J+P// | ``sudo tar -C /usr/local -zxf gf-3.9-bin-intel-mac.tar.gz``
%| Fedora (32-bit) | [Fedora RPMs /~hallgren/tmp/Fedora/] | //GF+S+C+J+P// | ``sudo rpm -i ...`` %| Fedora (32-bit) | [Fedora RPMs /~hallgren/tmp/Fedora/] | //GF+S+C+J+P// | ``sudo rpm -i ...``
| Ubuntu (32-bit) | [gf_3.8-1_i386.deb gf_3.8-1_i386.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.8-1_i386.deb`` %| Raspian 8.0 | [gf_3.9-1_armhf.deb gf_3.9-1_armhf.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.9-1_armhf.deb``
| Ubuntu (64-bit) | [gf_3.8-1_amd64.deb gf_3.8-1_amd64.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.8-1_amd64.deb`` | Ubuntu (32-bit) | [gf_3.9-1_i386.deb gf_3.9-1_i386.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.9-1_i386.deb``
| Windows | [gf-3.8-bin-windows.zip gf-3.8-bin-windows.zip] | //GF+S// | ``unzip gf-3.8-bin-windows.zip`` | Ubuntu (64-bit) | [gf_3.9-1_amd64.deb gf_3.9-1_amd64.deb] | //GF+S+C+J+P// | ``sudo dpkg -i gf_3.9-1_amd64.deb``
%| MINGW | [gf-3.8-bin-i686-MINGW32_NT-6.1.tar.gz gf-3.8-bin-i686-MINGW32_NT-6.1.tar.gz] | //GF+S+C// | ``tar -C / gf-3.8-bin-i686-MINGW32_NT-6.1.tar.gz`` | Windows | [gf-3.9-bin-windows.zip gf-3.9-bin-windows.zip] | //GF+S// | ``unzip gf-3.9-bin-windows.zip``
%| MINGW | [gf-3.9-bin-i686-MINGW32_NT-6.1.tar.gz gf-3.9-bin-i686-MINGW32_NT-6.1.tar.gz] | //GF+S+C// | ``tar -C / gf-3.9-bin-i686-MINGW32_NT-6.1.tar.gz``
%| ... | ... | ... | ... %| ... | ... | ... | ...
Features: GF = GF shell and grammar compiler and the Resource Grammar Library, Features: GF = GF shell and grammar compiler and the Resource Grammar Library,
@@ -44,17 +45,18 @@ variables, see Inari's notes on
%(which is started with ``C:\MinGW\msys\1.0\msys.bat``). %(which is started with ``C:\MinGW\msys\1.0\msys.bat``).
%It should work out of the box without any additional settings. %It should work out of the box without any additional settings.
The ``.deb`` packages should work on Ubuntu 12.04, 14.04 and 16.04 and similar The ``.deb`` packages should work on Ubuntu 16.04 and 17.04 and similar
Linux distributions. Linux distributions.
The packages for Mac OS X should work on at least 10.9, 10.10 and 10.11 (Mavericks, Yosemite and El Capitan). The packages for macOS (Mac OS X) should work on at
least 10.11 and 10.12 (El Capitan and Sierra).
(*) **Note** that for compatibility with OS X 10.11, %(*) **Note** that for compatibility with OS X 10.11 and newer,
``gf-3.8.pkg`` will install the ``gf`` executable in ``/usr/local/bin`` %``gf-3.9.pkg`` will install the ``gf`` executable in ``/usr/local/bin``
instead of ``/usr/bin``, so make sure ``/usr/local/bin`` is in your ``$PATH``. %instead of ``/usr/bin``, so make sure ``/usr/local/bin`` is in your ``$PATH``.
Also, if you still have an older version of GF installed in ``/usr/bin``, %Also, if you still have an older version of GF installed in ``/usr/bin``,
remove it and/or make sure ``/usr/local/bin`` comes before ``/usr/bin`` %remove it and/or make sure ``/usr/local/bin`` comes before ``/usr/bin``
in your ``$PATH`` so you don't accidentally run the old version. %in your ``$PATH`` so you don't accidentally run the old version.
The Mac OS and Linux ``.tar.gz`` packages are designed to be installed in The Mac OS and Linux ``.tar.gz`` packages are designed to be installed in
``/usr/local``. ``/usr/local``.
@@ -62,7 +64,7 @@ You can install them in other locations, but then you need to set the
``GF_LIB_PATH`` environment variable: ``GF_LIB_PATH`` environment variable:
``` ```
export GF_LIB_PATH=/usr/local/share/gf-3.8/lib export GF_LIB_PATH=/usr/local/share/gf-3.9/lib
``` ```
where ``/usr/local`` should be replaced with the path to the location where you where ``/usr/local`` should be replaced with the path to the location where you
@@ -84,7 +86,7 @@ circumstances the prodedure is fairly simple:
You can also download the full source package from here: You can also download the full source package from here:
[``gf-3.8.tar.gz`` gf-3.8.tar.gz]. [``gf-3.9.tar.gz`` gf-3.9.tar.gz].
=== Notes === === Notes ===
@@ -115,21 +117,21 @@ manually. Here is one way to do this:
**Note 2**. **Note 2**.
The GF source code has been updated to compile with GHC 8.0.1. Using older The GF source code has been updated to compile with GHC 8.2.1. Using older
versions of GHC (7.10.3, 7.10.2, 7.8, 7.6) should work too. versions of GHC (e.g. 8.0.x and 7.10.3) should still work too.
=== Known problems === %=== Known problems ===
%
There seems to be a bug in some versions of Cabal that can cause %There seems to be a bug in some versions of Cabal that can cause
%
``` %```
Distribution/Simple/PackageIndex.hs:124:8-13: Assertion failed % Distribution/Simple/PackageIndex.hs:124:8-13: Assertion failed
``` %```
%
if the same version of GF is %if the same version of GF is
already installed. If you encounter this, you can use ``ghc-pkg unregister gf`` %already installed. If you encounter this, you can use ``ghc-pkg unregister gf``
to remove the installed version of GF and ``ghc-pkg list gf`` to verify that %to remove the installed version of GF and ``ghc-pkg list gf`` to verify that
it is gone. %it is gone.
==Installing from the latest developer source code== ==Installing from the latest developer source code==
@@ -137,7 +139,7 @@ The first time:
%, assuming you already have the Haskell Platform and darcs %, assuming you already have the Haskell Platform and darcs
``` ```
darcs get --lazy http://www.grammaticalframework.org/ GF git clone https://github.com/GrammaticalFramework/GF.git
cd GF cd GF
cabal install cabal install
``` ```
@@ -146,13 +148,13 @@ Subsequently:
``` ```
cd GF cd GF
darcs pull -a git pull
cabal install cabal install
``` ```
Alternatively, you can get the code from the %Alternatively, you can get the code from the
[GF GitHub https://github.com/GrammaticalFramework/GF/] mirror, which is %[GF GitHub https://github.com/GrammaticalFramework/GF/] mirror, which is
updated nightly. %updated nightly.
The above notes for installing from source apply also in these cases. The above notes for installing from source apply also in these cases.
For more info on working with the GF source code, see the For more info on working with the GF source code, see the
@@ -160,6 +162,7 @@ For more info on working with the GF source code, see the
==Older releases== ==Older releases==
- [GF 3.8 index-3.8.html] (June 2016)
- [GF 3.7.1 index-3.7.1.html] (October 2015) - [GF 3.7.1 index-3.7.1.html] (October 2015)
- [GF 3.7 index-3.7.html] (June 2015) - [GF 3.7 index-3.7.html] (June 2015)
- [GF 3.6 index-3.6.html] (June 2014) - [GF 3.6 index-3.6.html] (June 2014)

View File

@@ -24,6 +24,11 @@ Over 200 changes have been pushed to the source repository since
===GF compiler and run-time library=== ===GF compiler and run-time library===
====New features and notable changes====
- Support for language-specific depencency configurations (in addition to abstract syntax based ones); see ``help vd`` in the GF shell
- An experimental support for sentence lookup which makes it possible - An experimental support for sentence lookup which makes it possible
to find the sentence from the grammar that matches best a set of keywords. to find the sentence from the grammar that matches best a set of keywords.
Right now it is usable only with controlled languages since it might be Right now it is usable only with controlled languages since it might be
@@ -34,19 +39,10 @@ very innefficient for some grammars.
- The API in the Java binding is extended and it covers more from - The API in the Java binding is extended and it covers more from
the full functionality of the C runtime. the full functionality of the C runtime.
====New features and notable changes====
- Support for language-specific depencency configurations (in addition to abstract syntax based ones); see ``help vd`` in the GF shell
====Other changes and bug fixes====
- ...
====Changes of interest to compiler developers==== ====Changes of interest to compiler developers====
- The compiler source code has been updated for compatibility with GHC 8.2.1 - The compiler source code has been updated for compatibility with GHC 8.2.1.
===Resource Grammar Library=== ===Resource Grammar Library===
@@ -62,18 +58,15 @@ the full functionality of the C runtime.
- Various fixes for several languages. - Various fixes for several languages.
- ...
- Various fixes in the translation dictionaries.
- Numerous fixes in the translation dictionaries.
- ...
===Apps and Cloud services=== ===Apps and Cloud services===
- PGF service: support for language-specific depencency configurations in - PGF service: support for language-specific depencency configurations in
``command=deptree``. ``command=deptree``.
- ...
-------------------- --------------------

View File

@@ -1,7 +1,7 @@
name: gf name: gf
version: 3.8-darcs version: 3.9-git
cabal-version: >= 1.10 cabal-version: >= 1.20
build-type: Custom build-type: Custom
license: OtherLicense license: OtherLicense
license-file: LICENSE license-file: LICENSE
@@ -57,6 +57,7 @@ flag interrupt
flag server flag server
Description: Include --server mode Description: Include --server mode
Default: True Default: True
flag network-uri flag network-uri
description: Get Network.URI from the network-uri package description: Get Network.URI from the network-uri package
default: True default: True
@@ -68,6 +69,7 @@ flag network-uri
flag custom-binary flag custom-binary
Description: Use a customised version of the binary package Description: Use a customised version of the binary package
Default: True Default: True
Manual: True
flag c-runtime flag c-runtime
Description: Include functionality from the C run-time library (which must be installed already) Description: Include functionality from the C run-time library (which must be installed already)
@@ -75,7 +77,7 @@ flag c-runtime
Library Library
default-language: Haskell2010 default-language: Haskell2010
build-depends: base >= 4.5 && <5, build-depends: base >= 4.6 && <5,
array, array,
containers, containers,
bytestring, bytestring,

View File

@@ -81,7 +81,7 @@ function sitesearch() {
<li><a href="http://ci.zjyto.net/job/GF/job/Build/"><img src="http://ci.zjyto.net/job/GF/job/Build/badge/icon" alt="GF build status"></a> <li><a href="http://ci.zjyto.net/job/GF/job/Build/"><img src="http://ci.zjyto.net/job/GF/job/Build/badge/icon" alt="GF build status"></a>
--> -->
<li><a href="doc/gf-developers.html">GF Developers Guide</a> <li><a href="doc/gf-developers.html">GF Developers Guide</a>
<li><A HREF="https://github.com/GrammaticalFramework/GF/">GitHub mirror</A> <li><A HREF="https://github.com/GrammaticalFramework/GF/">GF on GitHub</A>
<li><A HREF="https://github.com/GrammaticalFramework/gf-contrib/">Contibutions GitHub</A> <li><A HREF="https://github.com/GrammaticalFramework/gf-contrib/">Contibutions GitHub</A>
<li><A HREF="http://code.google.com/p/grammatical-framework/wiki/SideBar?tm=6">Wiki</A> <li><A HREF="http://code.google.com/p/grammatical-framework/wiki/SideBar?tm=6">Wiki</A>
<li><a href="/~hallgren/gf-experiment/browse/">Browse Source Code</a> <li><a href="/~hallgren/gf-experiment/browse/">Browse Source Code</a>
@@ -89,7 +89,7 @@ function sitesearch() {
</ul> </ul>
<h4>Develop Applications</h4> <h4>Develop Applications</h4>
<ul> <ul>
<li><a href="http://hackage.haskell.org/package/gf-3.7.1/docs/PGF.html">PGF library API (Haskell)</a> <li><a href="http://hackage.haskell.org/package/gf-3.9/docs/PGF.html">PGF library API (Haskell)</a>
<li><a href="doc/python-api.html">PGF library API (Python)</a> <li><a href="doc/python-api.html">PGF library API (Python)</a>
<li><a href="doc/java-api/index.html">PGF library API (Java)</a> <li><a href="doc/java-api/index.html">PGF library API (Java)</a>
<li><a href="doc/dotNet-api/index.html">PGF library API (.NET)</a> <li><a href="doc/dotNet-api/index.html">PGF library API (.NET)</a>
@@ -120,6 +120,8 @@ document.write('<div style="float: right; margin-top: 3ex;"> <form onsubmit="re
<div class=news2> <div class=news2>
<table class=news> <table class=news>
<tr><td>2016-08-11:<td><strong>GF 3.9 released!</strong>
<a href="download/release-3.9.html">Release notes</a>.
<tr><td>2017-06-29:<td>GF is moving to <a href="https://github.com/GrammaticalFramework/GF/">GitHub</a>! <tr><td>2017-06-29:<td>GF is moving to <a href="https://github.com/GrammaticalFramework/GF/">GitHub</a>!
<tr><td>2017-03-13:<td><strong>GF Summer School in Riga (Latvia), 14-25 August 2017</strong> <tr><td>2017-03-13:<td><strong>GF Summer School in Riga (Latvia), 14-25 August 2017</strong>
<a href="http://school.grammaticalframework.org/2017/">Summer <a href="http://school.grammaticalframework.org/2017/">Summer

View File

@@ -1,13 +1,7 @@
-- | Isolate backwards incompatible library changes to 'catch' and 'try' -- | Backwards compatible 'catch' and 'try'
{-# LANGUAGE CPP #-}
module GF.System.Catch where module GF.System.Catch where
import qualified System.IO.Error as S import qualified System.IO.Error as S
-- ** Backwards compatible try and catch -- ** Backwards compatible try and catch
#if MIN_VERSION_base(4,4,0)
catch = S.catchIOError catch = S.catchIOError
try = S.tryIOError try = S.tryIOError
#else
catch = S.catch
try = S.try
#endif

View File

@@ -1,7 +1,6 @@
{-# LANGUAGE CPP,ForeignFunctionInterface #-} {-# LANGUAGE ForeignFunctionInterface #-}
-- | A variant of 'Control.Concurrent.setNumCapabilities' that automatically -- | A variant of 'Control.Concurrent.setNumCapabilities' that automatically
-- detects the number of processors in the system, and is available -- detects the number of processors in the system.
-- even when compiling with GHC<7.6.
module GF.System.Concurrency( module GF.System.Concurrency(
-- * Controlling parallelism -- * Controlling parallelism
setNumCapabilities,getNumberOfProcessors) where setNumCapabilities,getNumberOfProcessors) where
@@ -16,13 +15,8 @@ import Foreign.C.Types(CInt(..))
-- hasn't already been set with @+RTS -N/n/ -RTS@. -- hasn't already been set with @+RTS -N/n/ -RTS@.
setNumCapabilities opt_n = setNumCapabilities opt_n =
do n <- maybe getNumberOfProcessors return opt_n do n <- maybe getNumberOfProcessors return opt_n
#if MIN_VERSION_base(4,6,0)
C.setNumCapabilities n C.setNumCapabilities n
return True return True
#else
n_now <- C.getNumCapabilities
return (n==n_now)
#endif
-- | Returns the number of processors in the system. -- | Returns the number of processors in the system.
getNumberOfProcessors = fmap fromEnum c_getNumberOfProcessors getNumberOfProcessors = fmap fromEnum c_getNumberOfProcessors

View File

@@ -1,5 +1,5 @@
AC_INIT(Portable Grammar Format library, 0.1.pre, AC_INIT(Portable Grammar Format library, 0.1-pre,
https://code.google.com/p/grammatical-framework/, http://www.grammaticalframework.org/,
libpgf) libpgf)
AC_PREREQ(2.58) AC_PREREQ(2.58)

0
src/runtime/c/setup.sh Normal file → Executable file
View File

View File

@@ -1,4 +1,4 @@
{-# LANGUAGE CPP, BangPatterns #-} {-# LANGUAGE BangPatterns #-}
module PGF.Optimize module PGF.Optimize
( optimizePGF ( optimizePGF
, updateProductionIndices , updateProductionIndices
@@ -11,11 +11,7 @@ import PGF.Macros
import Data.List (mapAccumL) import Data.List (mapAccumL)
import Data.Array.IArray import Data.Array.IArray
import Data.Array.MArray import Data.Array.MArray
#if MIN_VERSION_base(4,6,0)
import Data.Array.Unsafe as U(unsafeFreeze) import Data.Array.Unsafe as U(unsafeFreeze)
#else
import Data.Array.ST as U(unsafeFreeze)
#endif
import Data.Array.ST import Data.Array.ST
import Data.Array.Unboxed import Data.Array.Unboxed
import qualified Data.Map as Map import qualified Data.Map as Map