From c74dd8def30b5dcd7dea7cb85bdec545946e231a Mon Sep 17 00:00:00 2001 From: John Soo Date: Wed, 12 Feb 2020 08:58:55 -0800 Subject: [PATCH 33/34] gnu: Add ghc-hsc2hs. * gnu/packages/haskell-xyz.scm (ghc-hsc2hs): New variable. --- gnu/packages/haskell-xyz.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm index bada021a36..8d69df1da9 100644 --- a/gnu/packages/haskell-xyz.scm +++ b/gnu/packages/haskell-xyz.scm @@ -5935,6 +5935,37 @@ that interconverts between various bibliography formats using a common MODS-format XML intermediate.") (license license:gpl2+))) +(define-public ghc-hsc2hs + (package + (name "ghc-hsc2hs") + (version "0.68.6") + (source + (origin + (method url-fetch) + (uri (string-append + "https://hackage.haskell.org/package/hsc2hs/hsc2hs-" + version + ".tar.gz")) + (sha256 + (base32 + "1clj6bgs9vmiv3mjzp82lvyyik5zr5411nxab7hydbrgq94pbk70")))) + (build-system haskell-build-system) + (native-inputs + `(("ghc-tasty" ,ghc-tasty) + ("ghc-tasty-hspec" ,ghc-tasty-hspec))) + (home-page + "http://hackage.haskell.org/package/hsc2hs") + (synopsis + "Preprocessor that helps with writing Haskell bindings to C code.") + (description + "The hsc2hs program can be used to automate some parts of the process of +writing Haskell bindings to C code. It reads an almost-Haskell source file +with embedded special constructs, and outputs a real Haskell file with these +constructs processed, based on information taken from some C headers. The +extra constructs provide Haskell counterparts of C types, values of C +constants, including sizes of C types, and access to fields of C structs.") + (license license:bsd-3))) + (define-public ghc-hslogger (package (name "ghc-hslogger") -- 2.25.0