packages feed

cl3-2.0.0.0: cl3.cabal

-- Initial cl3.cabal generated by cabal init.  For further documentation, 
-- see http://haskell.org/cabal/users-guide/

-- The name of the package.
name:                cl3

-- The package version.  See the Haskell package versioning policy (PVP) 
-- for standards guiding when and how versions should be incremented.
-- https://wiki.haskell.org/Package_versioning_policy
-- PVP summary:      +-+------- breaking API changes
--                   | | +----- non-breaking API additions
--                   | | | +--- code changes with no API change
version:             2.0.0.0

-- A short (one-line) description of the package.
synopsis:            Clifford Algebra of three dimensional space.

-- A longer description of the package.
description:         Haskell Library implementing standard functions for the Algebra of Physical Space Cl(3,0)

-- URL for the project homepage or repository.
homepage:            https://github.com/waivio/cl3

bug-reports:         https://github.com/waivio/cl3/issues

-- The license under which the package is released.
license:             BSD3

-- The file containing the license text.
license-file:        LICENSE

-- The package author(s).
author:              Nathan Waivio

-- An email address to which users can send suggestions, bug reports, and 
-- patches.
maintainer:          Nathan Waivio <nathan.waivio@gmail.com>

-- A copyright notice.
copyright:           Copyright (C) 2017-2020 Nathan Waivio

category:            Math, Algebra

build-type:          Simple

tested-with:         GHC == 7.8.4,
                     GHC == 7.10.3,
                     GHC == 8.0.2,
                     GHC == 8.2.2,
                     GHC == 8.4.2,
                     GHC == 8.4.4,
                     GHC == 8.6.5,
                     GHC == 8.8.3

-- Extra files to be distributed with the package, such as examples or a 
-- README.
extra-source-files:  ChangeLog.md,
                     README.md,
                     stack.yaml

-- Constraint on the version of Cabal needed to build this package.
cabal-version:       >=1.10

source-repository head
  type:     git
  location: https://github.com/waivio/cl3.git

flag do-no-derived-instances
  description: Disable derived instances to reduce noise when inspecting GHC Core
  manual:      True
  default:     False

flag do-no-random
  description: Build without random library support
  manual:      True
  default:     False

library
  -- Modules exported by the library.
  exposed-modules:
    Algebra.Geometric.Cl3,
    Algebra.Geometric.Cl3.JonesCalculus
  
  -- Compiler options
  ghc-options: -Wall -O2
  
  if flag(do-no-derived-instances)
    cpp-options: -DO_NO_DERIVED
  
  if flag(do-no-random)
    cpp-options: -DO_NO_RANDOM
  
  -- LANGUAGE extensions used by modules in this package.
  other-extensions:
    Safe,
    GADTSyntax,
    ViewPatterns,
    DeriveDataTypeable,
    DeriveGeneric,
    CPP,
    BangPatterns,
    MultiWayIf
  
  -- Other library packages from which modules are imported.
  build-depends:       
    base >=4.7 && <5,
    deepseq >=1.1 && <2
  
  if !flag(do-no-random)
    build-depends:
      random >=1.0 && <2
  
  -- Directories containing source files.
  hs-source-dirs:      src
  
  -- Base language which the package is written in.
  default-language:    Haskell2010

-- Criterion based test suite
test-suite test-cl3
  type: exitcode-stdio-1.0
  hs-source-dirs: tests
  main-is: TestCl3.hs
  ghc-options: -Wall -O2
  build-depends: 
    cl3,
    base >=4.7 && <5,
    criterion >=1.1 && <2,
    random >=1.0 && <2
  default-language: Haskell2010

-- Criterion based benchmark
benchmark bench-cl3-nbody
  type: exitcode-stdio-1.0
  hs-source-dirs: benchmarks
  main-is: NbodyGameCl3.hs
  ghc-options: -Wall -O2
  build-depends:
    cl3,
    base >=4.7 && <5,
    criterion >=1.1 && <2
  default-language: Haskell2010