17.8. cabal


Ports should not be created for Haskell libraries, see Section 6.30, “Haskell Libraries” for more information.

Possible arguments: (none), hpack

Sets default values and targets used to build Haskell software using Cabal. A build dependency on the Haskell compiler port (GHC) is added. If hpack argument is given, a build dependency on devel/hs-hpack is added and hpack is invoked at configuration step to generate .cabal file.

The framework provides the following variables:


If the software uses Haskell dependencies, list them in this variable. Each item should be present on Hackage and be listed in form packagename-0.1.2. Dependencies can have revisions, which are specified after the _ symbol. Automatic generation of dependency list is supported, see Section 6.5.9, “Building Haskell Applications with cabal.


List of flags to be passed to cabal-install during the configuring and building stage. The flags are passed verbatim.


List of executable files installed by the port. Default value: ${PORTNAME}. Items from this list are automatically added to pkg-plist.


If defined, do not add items from ${EXECUTABLES} to pkg-plist.


Adds items to ${USE_CABAL} depending on opt option.


Adds items to ${EXECUTABLES} depending on opt option.


If opt is enabled, append the value to ${CABAL_FLAGS}. Otherwise, append -value to disable the flag.


For an executable named FOO list Haskell packages, whose data files should be accessible by the executable.

All FreeBSD documents are available for download at https://download.freebsd.org/ftp/doc/

Questions that are not answered by the documentation may be sent to <freebsd-questions@FreeBSD.org>.
Send questions about this document to <freebsd-doc@FreeBSD.org>.