name:                nanomsg-haskell
version:             0.1.0
synopsis:
  Bindings to the nanomsg library
description:
  This is a Haskell binding for the nanomsg library: <http://nanomsg.org/>.

  There's support for blocking send and recv, a non-blocking receive,
  and for all the socket types and the functions you need to wire
  them up and tear them down again.

  Most sockets options are available through accessor and mutator
  functions. Sockets are typed, transports are not.

homepage:            https://github.com/ivarnymoen/nanomsg-haskell
license:             MIT
license-file:        LICENSE
author:              See AUTHORS file
maintainer:          <ivar.nymoen@gmail.com>
copyright:           Copyright (c) 2013 the nanomsg-haskell authors
category:            Network
build-type:          Simple
cabal-version:       >=1.8

library
  hs-source-dirs:    src
  ghc-options:       -O2 -Wall
  exposed-modules:   Nanomsg
  extensions:        ForeignFunctionInterface, DeriveDataTypeable
  includes:          nanomsg/nn.h
  extra-libraries:   nanomsg
  build-depends:
    base == 4.*,
    bytestring >= 0.9.0 && < 0.11

test-suite tests
  type:              exitcode-stdio-1.0
  hs-source-dirs:    tests
  main-is:           Properties.hs
  ghc-options:       -O2 -Wall -threaded
  build-depends:
    base == 4.*,
    bytestring >= 0.9.0 && < 0.11,
    nanomsg-haskell,
    QuickCheck,
    test-framework,
    test-framework-quickcheck2,
    test-framework-th

source-repository head
  type:              git
  location:          https://github.com/ivarnymoen/nanomsg-haskell

benchmark send-messages
  type:              exitcode-stdio-1.0
  main-is:           SendMessages.hs
  ghc-options:       -O2 -Wall -threaded
  hs-source-dirs:    benchmarks
  build-depends:
    base == 4.*,
    bytestring >= 0.9.0 && < 0.11,
    nanomsg-haskell,
    criterion

benchmark vs-zeromq-bindings
  type:              exitcode-stdio-1.0
  main-is:           Zmq.hs
  ghc-options:       -O2 -Wall -threaded
  hs-source-dirs:    benchmarks
  build-depends:
    base == 4.*,
    bytestring >= 0.9.0 && < 0.11,
    nanomsg-haskell,
    zeromq3-haskell,
    criterion