alsa-core 0.5 → 0.5.0.1
raw patch · 2 files changed
+26/−18 lines, 2 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- alsa-core.cabal +24/−16
- src/Sound/ALSA/Exception.hs +2/−2
alsa-core.cabal view
@@ -1,14 +1,14 @@-Name: alsa-core-Version: 0.5-Copyright: Bjorn Bringert, Iavor S. Diatchki, Henning Thielemann-Maintainer: Henning Thielemann <alsa@henning-thielemann.de>-Author: Bjorn Bringert <bjorn@bringert.net>, Iavor S. Diatchki <iavor.diatchki@gmail.com>-Category: Sound, Music-License: BSD3-License-file: LICENSE-Homepage: http://www.haskell.org/haskellwiki/ALSA-Stability: Experimental-Build-Type: Simple+Name: alsa-core+Version: 0.5.0.1+Copyright: Bjorn Bringert, Iavor S. Diatchki, Henning Thielemann+Maintainer: Henning Thielemann <alsa@henning-thielemann.de>+Author: Henning Thielemann <alsa@henning-thielemann.de>, Bjorn Bringert <bjorn@bringert.net>, Iavor S. Diatchki <iavor.diatchki@gmail.com>+Category: Sound, Music+License: BSD3+License-file: LICENSE+Homepage: http://www.haskell.org/haskellwiki/ALSA+Stability: Experimental+Build-Type: Simple Cabal-Version: >= 1.8 Synopsis: Binding to the ALSA Library API (Exceptions).@@ -18,13 +18,18 @@ Source-Repository head type: darcs- location: http://code.haskell.org/~thielema/alsa-core/+ location: http://code.haskell.org/alsa/core/ Source-Repository this type: darcs- location: http://code.haskell.org/~thielema/alsa-core/- tag: 0.5+ location: http://code.haskell.org/alsa/core/+ tag: 0.5.0.1 +Flag pkgConfig+ Description: use pkg-config if it works+ -- http://hackage.haskell.org/trac/hackage/ticket/170+ Default: True+ Library Build-depends: extensible-exceptions >=0.1.1 && <0.2,@@ -36,5 +41,8 @@ Sound.ALSA.Exception GHC-Options: -Wall- Includes: alsa/asoundlib.h- Extra-libraries: asound+ If flag(pkgConfig)+ PkgConfig-depends: alsa >= 1.0.14+ Else+ Includes: alsa/asoundlib.h+ Extra-Libraries: asound
src/Sound/ALSA/Exception.hs view
@@ -12,7 +12,7 @@ import Data.Typeable (Typeable, ) import Foreign.C.Error (Errno(Errno), ePIPE, errnoToIOError, ) import Foreign.C.String (CString, peekCString, )-import Foreign.C.Types (CInt, )+import qualified Foreign.C.Types as C import Prelude hiding (catch, show, ) import qualified Prelude as P@@ -42,7 +42,7 @@ checkResult_ :: Integral a => String -> a -> IO () checkResult_ f r = checkResult f r >> return () -checkResultMaybe :: String -> (CInt -> a) -> (CInt -> Maybe a) -> CInt -> IO a+checkResultMaybe :: String -> (C.CInt -> a) -> (C.CInt -> Maybe a) -> C.CInt -> IO a checkResultMaybe f ok err x = if x >= 0 then return (ok x)