packages feed

gsl-random-0.1.1: gsl-random.cabal

name:            gsl-random
version:         0.1.1
homepage:        http://stat.stanford.edu/~patperry/code/gsl-random
synopsis:        Bindings the the GSL random number generation facilities.
description:
    Bindings to the GNU Scientific Library random number generators and random
    distributions.
    .
category:        Math
license:         BSD3
license-file:    LICENSE
copyright:       (c) 2008. Patrick Perry <patperry@stanford.edu>
author:          Patrick Perry
maintainer:      Patrick Perry <patperry@stanford.edu>
cabal-version: >= 1.2.0
build-type:      Simple
tested-with:     GHC ==6.8.3

extra-source-files:     README

-- Below are the flags for specifying which CBLAS to link with.  If no flag
-- is specified, the default is to use the unoptimized CBLAS that comes with 
-- the GSL.  To use the "custom" flag, you must edit the section at the end of
-- the file with the name and location of the CBLAS library you want to use.

flag atlas
    description:    Link with ATLAS.
    default:        False

flag gsl
    description:    Link with GSL unoptimized CBLAS.
    default:        False

flag mkl
    description:    Link with Intel MKL.
    default:        False

flag veclib
    description:    Link with Mac OS X vecLib.
    default:        False
    
flag custom
    description:    Link with a custom CBLAS.  
    default:        False
    -- You must edit this file below to use this option.  


library
    exposed-modules:    GSL.Random.Gen
                        GSL.Random.Dist
    other-modules:      GSL.Random.Gen.Internal

    ghc-options:        -Wall
    extensions:         ForeignFunctionInterface
    build-depends:      base

    if flag(atlas)
        extra-libraries:    gsl cblas atlas m
      
    if flag(gsl)
        extra-libraries:    gsl gslcblas m

    if flag(mkl)
      if arch(x86_64)
        extra-libraries:    gsl mkl_lapack mkl_intel_lp64 mkl_sequential mkl_core m
      else
        extra-libraries:    gsl mkl_lapack mkl_intel mkl_sequential mkl_core m

    if flag(veclib)
        extra-libraries:    gsl cblas m

    if flag(custom)
        -- CUSTOM CBLAS LIBS GO HERE
        extra-libraries:    
        
        -- PATH TO CUSTOM LIB DIR GOES HERE 
        extra-lib-dirs:     
    
    -- fall back to gsl cblas if no flag is specified
    if !flag(atlas) && !flag(gsl) && !flag(mkl) && !flag(veclib) && !flag(custom)
        extra-libraries:    gsl gslcblas m