Changes between Version 5 and Version 6 of Building/Preparation/FreeBSD


Ignore:
Timestamp:
Apr 14, 2013 8:00:36 PM (2 years ago)
Author:
pgj
Comment:

Add some links

Legend:

Unmodified
Added
Removed
Modified
  • Building/Preparation/FreeBSD

    v5 v6  
    66Building GHC on FreeBSD is currently supported on 8.1-RELEASE or later, on {{{i386}}} (x86) and {{{amd64}}} (x86_64) architectures.  One might be able to build GHC on different architectures and earlier versions but they are not maintained actively.  Note that 8.1-RELEASE is used for the FreeBSD nightly builds ([http://darcs.haskell.org/ghcBuilder/builders/pgj/ amd64 head], [http://darcs.haskell.org/ghcBuilder/builders/pgj2/ i386 head], [http://darcs.haskell.org/ghcBuilder/builders/pgj-freebsd-amd64-stable/ amd64 stable], [http://darcs.haskell.org/ghcBuilder/builders/pgj-freebsd-i386-stable/ i386 stable]).
    77
    8 ''Note that this section is intended for developers and early adopters primarily.  If you are just want to install GHC on your system, simply use the `devel/hs-haskell-platform` port instead.  This port does all the things described below for you.  It is usually kept updated to match the latest Haskell Platform specifications.''
     8''Note that this section is intended for developers and early adopters primarily.  If you are just want to install GHC on your system, simply use the [http://www.freshports.org/devel/hs-haskell-platform devel/hs-haskell-platform] port instead.  This port does all the things described below for you.  It is usually kept updated to match the latest Haskell Platform specifications.''
    99
    1010== Required Ports ==
     
    1212In order to be able to build GHC from source, the following ports have to be installed.
    1313
    14  * `converters/libiconv` (GNU libiconv)
    15  * `devel/autoconf` (GNU Autoconf)
    16  * `devel/git` (for getting and managing the GHC sources)
    17  * `devel/gmake` (GNU Make)
    18  * `devel/hs-alex` (alex)
    19  * `devel/hs-happy` (happy)
    20  * `ftp/curl` (HTTP support for git)
    21  * `lang/ghc` (bootstrap compiler, usually tracking Haskell Platform specifications)
    22  * `lang/perl5.14` (Perl)
    23  * `lang/python27` (Python, for the test suite)
    24  * `math/gmp` (GNU GMP)
     14 * [http://www.freshports.org/converters/libiconv/ converters/libiconv] (GNU libiconv)
     15 * [http://www.freshports.org/devel/autoconf devel/autoconf] (GNU Autoconf)
     16 * [http://www.freshports.org/devel/git devel/git] (for getting and managing the GHC sources)
     17 * [http://www.freshports.org/devel/gmake devel/gmake] (GNU Make)
     18 * [http://www.freshports.org/devel/hs-alex devel/hs-alex] (alex)
     19 * [http://www.freshports.org/devel/hs-happy devel/hs-happy] (happy)
     20 * [http://www.freshports.org/ftp/curl ftp/curl] (HTTP support for git)
     21 * [http://www.freshports.org/lang/ghc lang/ghc] (bootstrap compiler, usually tracking Haskell Platform specifications)
     22 * [http://www.freshports.org/lang/perl5.14 lang/perl5.14] (Perl)
     23 * [http://www.freshports.org/lang/python27 lang/python27] (Python, for the test suite)
     24 * [http://www.freshports.org/math/gmp math/gmp] (GNU GMP)
    2525
    26 Probably it is possible to use a [http://www.haskell.org/ghc/download_ghc_7_6_2#freebsd vanilla binary distribution] to bootstrap the build, but one must note that it is built on 8.1-RELEASE, hence it will require installing `misc/compat8x` in order to make it work on 9.x and later systems.
     26Probably it is possible to use a [http://www.haskell.org/ghc/download_ghc_7_6_2#freebsd vanilla binary distribution] to bootstrap the build, but one must note that it is built on 8.1-RELEASE, hence it will require installing [http://www.freshports.org/misc/compat8x misc/compat8x] in order to make it work on 9.x and later systems.
    2727
    2828== Optional Ports ==
     
    3030In addition to the required ones, there are some further ports to install for extras.
    3131
    32  * `devel/binutils` (for a more up-to-date version of the GNU toolchain, see Notes)
    33  * `devel/libffi` (for dynamic linking)
    34  * `devel/llvm` (for LLVM code generation)
    35  * `devel/hs-haskell-platform` (the complete Haskell Platform)
    36  * `devel/hs-hasktags` (for generating HTAGS files)
    37  * `devel/ncurses` (for a more up-to-date version for the `terminfo` library, see Notes)
    38  * `lang/gcc` (for GCC 4.6 or later, see Notes)
    39  * `print/hs-hscolour` (for !HsColourized Haddock documentation)
    40  * `textproc/dblatex` (for PDF documentation)
    41  * `textproc/docbook-xsl` (for XML documentation)
    42  * `textproc/libxslt` (for XML documentation)
     32 * [http://www.freshports.org/devel/binutils devel/binutils] (for a more up-to-date version of the GNU toolchain, see Notes)
     33 * [http://www.freshports.org/devel/libffi devel/libffi] (for dynamic linking)
     34 * [http://www.freshports.org/devel/llvm devel/llvm] (for LLVM code generation)
     35 * [http://www.freshports.org/devel/hs-haskell-platform devel/hs-haskell-platform] (the complete Haskell Platform)
     36 * [http://www.freshports.org/devel/hs-hasktags devel/hs-hasktags] (for generating HTAGS files)
     37 * [http://www.freshports.org/devel/ncurses devel/ncurses] (for a more up-to-date version for the `terminfo` library, see Notes)
     38 * [http://www.freshports.org/lang/gcc lang/gcc] (for GCC 4.6 or later, see Notes)
     39 * [http://www.freshports.org/print/hs-hscolour print/hs-hscolour] (for !HsColourized Haddock documentation)
     40 * [http://www.freshports.org/textproc/dblatex textproc/dblatex] (for PDF documentation)
     41 * [http://www.freshports.org/textproc/docbook-xsl textproc/docbook-xsl] (for XML documentation)
     42 * [http://www.freshports.org/textproc/libxslt textproc/libxslt] (for XML documentation)
    4343
    4444== Running `configure` ==
     
    7979Here is a random list of thoughts about things that are good to know when working on FreeBSD.
    8080
    81  - The FreeBSD base system contains GCC and the GNU toolchain (at least for the time being) but they are not or only slowly updated.  GCC is technically stuck at version 4.2.1 which may not be optimal for building GHC these days.  Hence it is highly recommended to use the toolchain (`devel/binutils`) and GCC (`lang/gcc`) from the Ports Collectiom instead.
     81 - The FreeBSD base system contains GCC and the GNU toolchain (at least for the time being) but they are not or only slowly updated.  GCC is technically stuck at version 4.2.1 which may not be optimal for building GHC these days.  Hence it is highly recommended to use the toolchain ([http://www.freshports.org/devel/binutils devel/binutil]) and GCC ([http://www.freshports.org/lang/gcc lang/gcc]) from the Ports Collection instead.
    8282
    83  - The FreeBSD base system is shipped with a version of `ncurses` but this may not be the latest.  Unfortunately, when `devel/ncurses` is installed one should add some extra lines to `mk/build.mk` to tell GNU make we want to use `ncurses` from `$LOCALBASE` (see above) instead, otherwise `terminfo` (which uses `ncurses`) becomes linked to `ncurses` in the base:
     83 - The FreeBSD base system is shipped with a version of `ncurses` but this may not be the latest.  Unfortunately, when [http://www.freshports.org/devel/ncurses devel/ncurses] is installed one should add some extra lines to `mk/build.mk` to tell GNU make we want to use `ncurses` from `$LOCALBASE` (see above) instead, otherwise `terminfo` (which uses `ncurses`) becomes linked to `ncurses` in the base:
    8484
    8585 {{{
     
    9292 - The GHC source code have an in-tree version of `libffi` and `gmp` which may work by accident -- especially if the version of `libgmp.so` and `libffi.so` matches the version installed by the ports.  But using them is not recommended as they could result in various strange build and run-time errors.  See the `configure` options to work around them.
    9393
    94  - Building GHC sources and Haskell sources in general could be sped up by setting up a `tmpfs(5)` partition.  (This is not created by the default install.)  Just replace the `/tmp` parition with a tmpfs-backed entry in `/etc/fstab`:
     94 - Building GHC sources and Haskell sources in general could be sped up by setting up a [http://www.freebsd.org/cgi/man.cgi?query=tmpfs&apropos=0&sektion=0&manpath=FreeBSD+9.1-stable&arch=default&format=html tmpfs(5)] partition.  (This is not created by the default install.)  Just replace the `/tmp` partition with a tmpfs-backed entry in `/etc/fstab`:
    9595
    9696 {{{