packages feed

PortFusion-1.0.3: PortFusion.cabal

name:          PortFusion
version:       1.0.3
stability:     stable on all operating systems
synopsis:      CORSIS PortFusion : High-performance Distributed Proxy
description:   PortFusion is a minimalistic, cross-platform, transport-layer distributed reverse / forward proxy for TCP released under GPLv3.
               .
               A single package that makes the most of each platform by tapping into their unique capabilities, combining this power with an intuitive interface, beautiful design and Haskell's excellent support for unprecedented levels of concurrency and parallelism.
               .
               It strives for the smallest source code size while delivering maximum throughput with near zero overhead.
               .
               [Official Binaries]
               are available for download from <http://fusion.corsis.eu> for Windows, Linux, OS X and FreeBSD.
copyright:     Copyright © 2012 Cetin Sert
license:       GPL-3
license-file:  LICENSE
author:        Cetin Sert <fusion@corsis.eu>
maintainer:    Cetin Sert <fusion@corsis.eu>
homepage:      http://fusion.corsis.eu
package-url:   http://fusion.corsis.eu
bug-reports:   http://github.com/corsis/PortFusion/issues
category:      System, Network
build-type:    Simple
cabal-version: >=1.6



extra-source-files: res/*.svg
                    res/osx/*.icns
                    res/osx/*.hqx
                    res/win/*.rc
                    res/win/*.bat
                    res/win/*.ico
                    res/win/*.res



source-repository head
    type:      git
    location:  git://github.com/corsis/PortFusion.git


flag static
    description: enable fullly static linking
    default    : False


flag llvm
    description: compile via LLVM
    default    : False



executable PortFusion
    hs-source-dirs:  src
    main-is:         Main.hs
    buildable:       True
    extensions:      ScopedTypeVariables CPP BangPatterns
                     TypeSynonymInstances TypeOperators OverloadedStrings
                     DeriveDataTypeable PostfixOperators TupleSections
    build-depends:   base       >= 4     && <= 5,
                     bytestring >= 0.9   && <= 1,
                     vector     >= 0.9.1 && <= 1,
                     splice     >= 0.6   && <= 1
    if os(mingw32)
      build-depends: network    >= 2.3.0.13
      ld-options:    res\win\PortFusion.res
    else
      build-depends: network    -any


    ghc-options:     -W -O2 -O3 -threaded -fspec-constr-count=16

    if flag(static)
      ghc-options:   -static
      ld-options:    -static

    if flag(llvm)
      ghc-options:   -fllvm -optlo-O3 -msse4.2


--------------------------------------------------------------------------------


   -- CORSIS Build Name Components
   --
   -- Below is only used to generate standard build names each time a PortFusion
   -- binary is compiled using Cabal; can be simply replaced with:
   --
   --   cpp-options: -D__OS__="SOME OS" -D__ARCH__="SOME ARCH"
   --

    if os(linux)
       cpp-options: -D__OS__="Linux"
    else
       if os(mingw32)
         cpp-options: -D__OS__="Windows"
       else
         if os(freebsd)
           cpp-options: -D__OS__="FreeBSD"
         else
           if os(openbsd) || os(netbsd)
             cpp-options: -D__OS__="BSD"
           else
             if os(darwin)
               cpp-options: -D__OS__="MacOS"
             else
               if os(solaris)
                 cpp-options: -D__OS__="Solaris"
               else
--                 if os(gnu) || os(hurd)
--                   cpp-options: -D__OS__="HURD"
--                 else
                   cpp-options: -D__OS__="Generic"


    if arch(i386)
       cpp-options: -D__ARCH__="x86"
    else
       if arch(x86_64)
         cpp-options: -D__ARCH__="x86-64"
       else
         if arch(arm)
           cpp-options: -D__ARCH__="ARM"
         else
--           if arch(powerpc)
--             cpp-options: -D__ARCH__="PowerPC"
--           else
--             if arch(powerpc64)
--               cpp-options: -D__ARCH__="PowerPC-64"
--             else
               if arch(sparc)
                 cpp-options: -D__ARCH__="SPARC"
               else
                 if arch(ia64)
                   cpp-options: -D__ARCH__="Itanium-64"
                 else
                   if arch(mips)
                     cpp-options: -D__ARCH__="MIPS"
                   else
                     cpp-options: -D__ARCH__="Unknown"