unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Robert Vollmert <rob@vllmrt.net>
To: 38423@debbugs.gnu.org
Cc: Robert Vollmert <rob@vllmrt.net>
Subject: [bug#38423] [PATCH 09/49] gnu: Add ghc-wai-cors.
Date: Fri, 29 Nov 2019 12:37:11 +0100	[thread overview]
Message-ID: <20191129113751.82405-9-rob@vllmrt.net> (raw)
In-Reply-To: <20191129113751.82405-1-rob@vllmrt.net>

* gnu/packages/haskell-web.scm (ghc-wai-cors): New package.
---
 gnu/local.mk                                  |  1 +
 gnu/packages/haskell-web.scm                  | 42 +++++++++++++++++++
 .../ghc-wai-cors-skip-phantomjs-tests.patch   | 13 ++++++
 3 files changed, 56 insertions(+)
 create mode 100644 gnu/packages/patches/ghc-wai-cors-skip-phantomjs-tests.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index e49029a379..56ff1d0f7b 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -889,6 +889,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/ghc-monad-par-fix-tests.patch		\
   %D%/packages/patches/ghc-pandoc-fix-html-tests.patch		\
   %D%/packages/patches/ghc-pandoc-fix-latex-test.patch		\
+  %D%/packages/patches/ghc-wai-cors-skip-phantomjs-tests.patch	\
   %D%/packages/patches/ghostscript-no-header-id.patch		\
   %D%/packages/patches/ghostscript-no-header-uuid.patch		\
   %D%/packages/patches/ghostscript-no-header-creationdate.patch \
diff --git a/gnu/packages/haskell-web.scm b/gnu/packages/haskell-web.scm
index e337d33e18..7f54568399 100644
--- a/gnu/packages/haskell-web.scm
+++ b/gnu/packages/haskell-web.scm
@@ -1599,3 +1599,45 @@ requirements of downstream users (e.g. Debian).")
     (description
      "Provide a bridge between WAI and the websockets package.")
     (license license:expat)))
+
+(define-public ghc-wai-cors
+  (package
+    (name "ghc-wai-cors")
+    (version "0.2.6")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "https://hackage.haskell.org/package/wai-cors/wai-cors-"
+             version
+             ".tar.gz"))
+       (sha256
+        (base32
+         "11m9d8hn9pb9brprz0kglldmcqj83kjkjdwdpxdbl12430ii1ina"))
+       (patches (search-patches "ghc-wai-cors-skip-phantomjs-tests.patch"))))
+    (build-system haskell-build-system)
+    (arguments
+     ;; required for unclear reasons; those flags should default to false
+     `(#:configure-flags '("--flags=-wai-2" "--flags=-wai-1")))
+    (inputs
+     `(("ghc-attoparsec" ,ghc-attoparsec)
+       ("ghc-base-unicode-symbols"
+        ,ghc-base-unicode-symbols)
+       ("ghc-case-insensitive" ,ghc-case-insensitive)
+       ("ghc-http-types" ,ghc-http-types)
+       ("ghc-wai" ,ghc-wai)))
+    (native-inputs
+     `(("ghc-tasty" ,ghc-tasty)
+       ("ghc-tasty-hunit" ,ghc-tasty-hunit)
+       ("ghc-transformers-compat" ,ghc-transformers-compat)
+       ("ghc-wai-extra" ,ghc-wai-extra)
+       ("ghc-wai-websockets" ,ghc-wai-websockets)
+       ("ghc-warp" ,ghc-warp)
+       ("ghc-websockets" ,ghc-websockets)))
+    (home-page
+     "https://github.com/larskuhtz/wai-cors")
+    (synopsis "CORS for WAI")
+    (description
+     "This package provides an implemenation of Cross-Origin resource sharing
+(CORS) for Wai that aims to be compliant with http://www.w3.org/TR/cors.")
+    (license license:expat)))
diff --git a/gnu/packages/patches/ghc-wai-cors-skip-phantomjs-tests.patch b/gnu/packages/patches/ghc-wai-cors-skip-phantomjs-tests.patch
new file mode 100644
index 0000000000..ffb1929a03
--- /dev/null
+++ b/gnu/packages/patches/ghc-wai-cors-skip-phantomjs-tests.patch
@@ -0,0 +1,13 @@
+Skip phantomjs tests.
+
+--- a/wai-cors.cabal	2017-12-02 19:58:59.000000000 +0100
++++ b/wai-cors.cabal	2019-06-03 22:02:32.792000000 +0200
+@@ -102,6 +102,8 @@
+     ghc-options: -Wall
+ 
+ Test-Suite phantomjs
++    buildable: False
++
+     type: exitcode-stdio-1.0
+     default-language: Haskell2010
+     main-is: PhantomJS.hs
-- 
2.21.0 (Apple Git-122.2)

  parent reply	other threads:[~2019-11-29 11:39 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-29 11:35 [bug#38423] add postgrest Robert Vollmert
2019-11-29 11:37 ` [bug#38423] [PATCH 01/49] gnu: Add ghc-text-printer Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 02/49] gnu: Add ghc-text-latin1 Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 03/49] gnu: Add ghc-text-builder Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 04/49] gnu: Add ghc-text-short Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 05/49] gnu: Add ghc-data-checked Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 06/49] gnu: Add ghc-deferred-folds Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 07/49] gnu: Add ghc-websockets Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 08/49] gnu: Add ghc-wai-websockets Robert Vollmert
2019-11-29 11:37   ` Robert Vollmert [this message]
2019-11-29 11:37   ` [bug#38423] [PATCH 10/49] gnu: Add ghc-wai-middleware-static Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 11/49] gnu: Add ghc-wai-app-static Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 12/49] gnu: Add ghc-expiring-cache-map Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 13/49] gnu: Add ghc-insert-ordered-containers Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 14/49] gnu: Add ghc-protolude Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 15/49] gnu: Add ghc-mtl-compat Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 16/49] gnu: Add ghc-monad-time Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 17/49] gnu: Add ghc-bug Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 18/49] gnu: Add ghc-only Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 19/49] gnu: Add ghc-data-bword Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 20/49] gnu: Add ghc-data-dword Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 21/49] gnu: Add ghc-data-endian Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 22/49] gnu: Add ghc-data-serializer Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 23/49] gnu: Add ghc-data-textual Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 24/49] gnu: Add ghc-directory Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 25/49] gnu: Add ghc-network-ip Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 26/49] gnu: Add ghc-http-media Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 27/49] gnu: Add ghc-type-hint Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 28/49] gnu: Add ghc-concise Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 29/49] gnu: Add ghc-lens-aeson Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 30/49] gnu: Add ghc-placeholders Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 31/49] gnu: Add ghc-binary-parser Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 32/49] gnu: Add ghc-bytestring-tree-builder Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 33/49] gnu: Add ghc-bytestring-strict-builder Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 34/49] gnu: Add ghc-heredoc Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 35/49] gnu: Add ghc-interpolatedstring-perl6 Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 36/49] gnu: Add ghc-loch-th Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 37/49] gnu: Add ghc-ranged-sets Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 38/49] gnu: Add ghc-postgresql-binary Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 39/49] gnu: Add ghc-postgresql-libpq Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 40/49] gnu: Add ghc-hasql Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 41/49] gnu: Add ghc-hasql-pool Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 42/49] gnu: Add ghc-hasql-transaction Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 43/49] gnu: Add ghc-swagger2 Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 44/49] gnu: Add ghc-configurator-pg Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 45/49] gnu: Add ghc-cassava Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 46/49] gnu: Add ghc-tasty-hspec Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 47/49] gnu: Add ghc-jose Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 48/49] gnu: Add postgrest Robert Vollmert
2019-11-29 11:37   ` [bug#38423] [PATCH 49/49] gnu: Add postgrest service Robert Vollmert

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191129113751.82405-9-rob@vllmrt.net \
    --to=rob@vllmrt.net \
    --cc=38423@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).