[commit: packages/xhtml] master: Update .cabal file & reduce CPP-processing to the bare minimum (eb81b30)

git at git.haskell.org git at git.haskell.org
Sat Jun 17 20:55:53 UTC 2017


Repository : ssh://git@git.haskell.org/xhtml

On branch  : master
Link       : http://git.haskell.org/packages/xhtml.git/commitdiff/eb81b3090ab78cd3a57507456d0401509204bc48

>---------------------------------------------------------------

commit eb81b3090ab78cd3a57507456d0401509204bc48
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date:   Tue Apr 18 11:25:42 2017 +0200

    Update .cabal file & reduce CPP-processing to the bare minimum


>---------------------------------------------------------------

eb81b3090ab78cd3a57507456d0401509204bc48
 Text/XHtml.hs                         |  4 ----
 Text/XHtml/BlockTable.hs              |  4 ----
 Text/XHtml/Debug.hs                   |  4 ----
 Text/XHtml/Extras.hs                  |  4 ----
 Text/XHtml/Frameset.hs                |  4 ----
 Text/XHtml/Frameset/Attributes.hs     |  4 ----
 Text/XHtml/Frameset/Elements.hs       |  4 ----
 Text/XHtml/Internals.hs               |  5 +----
 Text/XHtml/Strict.hs                  |  4 ----
 Text/XHtml/Strict/Attributes.hs       |  4 ----
 Text/XHtml/Strict/Elements.hs         |  4 ----
 Text/XHtml/Table.hs                   |  5 -----
 Text/XHtml/Transitional.hs            |  4 ----
 Text/XHtml/Transitional/Attributes.hs |  4 ----
 Text/XHtml/Transitional/Elements.hs   |  4 ----
 xhtml.cabal                           | 12 +++++++++---
 16 files changed, 10 insertions(+), 64 deletions(-)

diff --git a/Text/XHtml.hs b/Text/XHtml.hs
index 99b1cd2..8c89d8c 100644
--- a/Text/XHtml.hs
+++ b/Text/XHtml.hs
@@ -1,7 +1,3 @@
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
-
 -----------------------------------------------------------------------------
 -- |
 -- Module      :  Text.XHtml
diff --git a/Text/XHtml/BlockTable.hs b/Text/XHtml/BlockTable.hs
index 42718a8..499dd62 100644
--- a/Text/XHtml/BlockTable.hs
+++ b/Text/XHtml/BlockTable.hs
@@ -1,7 +1,3 @@
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
-
 -----------------------------------------------------------------------------
 -- |
 -- Module      :  Text.XHtml.BlockTable
diff --git a/Text/XHtml/Debug.hs b/Text/XHtml/Debug.hs
index aa07dd0..fc71d7a 100644
--- a/Text/XHtml/Debug.hs
+++ b/Text/XHtml/Debug.hs
@@ -1,8 +1,4 @@
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 -- | This module contains functions for displaying
 --   HTML as a pretty tree.
diff --git a/Text/XHtml/Extras.hs b/Text/XHtml/Extras.hs
index 835ca37..5208625 100644
--- a/Text/XHtml/Extras.hs
+++ b/Text/XHtml/Extras.hs
@@ -1,7 +1,3 @@
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
-
 module Text.XHtml.Extras where
 
 import Text.XHtml.Internals
diff --git a/Text/XHtml/Frameset.hs b/Text/XHtml/Frameset.hs
index 453bff1..becfb39 100644
--- a/Text/XHtml/Frameset.hs
+++ b/Text/XHtml/Frameset.hs
@@ -1,7 +1,3 @@
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
-
 -- | Produces XHTML 1.0 Frameset.
 module Text.XHtml.Frameset (
      -- * Data types
diff --git a/Text/XHtml/Frameset/Attributes.hs b/Text/XHtml/Frameset/Attributes.hs
index 8465965..7aec0dd 100644
--- a/Text/XHtml/Frameset/Attributes.hs
+++ b/Text/XHtml/Frameset/Attributes.hs
@@ -1,8 +1,4 @@
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 module Text.XHtml.Frameset.Attributes where
 
diff --git a/Text/XHtml/Frameset/Elements.hs b/Text/XHtml/Frameset/Elements.hs
index f6de454..f925784 100644
--- a/Text/XHtml/Frameset/Elements.hs
+++ b/Text/XHtml/Frameset/Elements.hs
@@ -1,8 +1,4 @@
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 module Text.XHtml.Frameset.Elements where
 
diff --git a/Text/XHtml/Internals.hs b/Text/XHtml/Internals.hs
index 86f031e..7d5ac22 100644
--- a/Text/XHtml/Internals.hs
+++ b/Text/XHtml/Internals.hs
@@ -1,8 +1,5 @@
+{-# LANGUAGE CPP #-}
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 -----------------------------------------------------------------------------
 -- |
diff --git a/Text/XHtml/Strict.hs b/Text/XHtml/Strict.hs
index 73dd343..c51f9bf 100644
--- a/Text/XHtml/Strict.hs
+++ b/Text/XHtml/Strict.hs
@@ -1,7 +1,3 @@
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
-
 -- | Produces XHTML 1.0 Strict.
 module Text.XHtml.Strict (
      -- * Data types
diff --git a/Text/XHtml/Strict/Attributes.hs b/Text/XHtml/Strict/Attributes.hs
index 1fdc2de..468eb1a 100644
--- a/Text/XHtml/Strict/Attributes.hs
+++ b/Text/XHtml/Strict/Attributes.hs
@@ -1,8 +1,4 @@
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 module Text.XHtml.Strict.Attributes where
 
diff --git a/Text/XHtml/Strict/Elements.hs b/Text/XHtml/Strict/Elements.hs
index 367631e..25b94d4 100644
--- a/Text/XHtml/Strict/Elements.hs
+++ b/Text/XHtml/Strict/Elements.hs
@@ -1,8 +1,4 @@
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 module Text.XHtml.Strict.Elements where
 
diff --git a/Text/XHtml/Table.hs b/Text/XHtml/Table.hs
index b94b4db..c243673 100644
--- a/Text/XHtml/Table.hs
+++ b/Text/XHtml/Table.hs
@@ -1,8 +1,3 @@
-{-# LANGUAGE CPP #-}
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
-
 -- | Table combinators for XHTML.
 module Text.XHtml.Table (HtmlTable, HTMLTABLE(..),
                         (</>), above, (<->), beside, 
diff --git a/Text/XHtml/Transitional.hs b/Text/XHtml/Transitional.hs
index 99af40c..97f6430 100644
--- a/Text/XHtml/Transitional.hs
+++ b/Text/XHtml/Transitional.hs
@@ -1,7 +1,3 @@
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
-
 -- | Produces XHTML 1.0 Transitional.
 module Text.XHtml.Transitional (
      -- * Data types
diff --git a/Text/XHtml/Transitional/Attributes.hs b/Text/XHtml/Transitional/Attributes.hs
index fb78c63..95b2e8e 100644
--- a/Text/XHtml/Transitional/Attributes.hs
+++ b/Text/XHtml/Transitional/Attributes.hs
@@ -1,8 +1,4 @@
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 module Text.XHtml.Transitional.Attributes where
 
diff --git a/Text/XHtml/Transitional/Elements.hs b/Text/XHtml/Transitional/Elements.hs
index 7711b17..47303e3 100644
--- a/Text/XHtml/Transitional/Elements.hs
+++ b/Text/XHtml/Transitional/Elements.hs
@@ -1,8 +1,4 @@
 {-# OPTIONS_HADDOCK hide #-}
--- #hide
-#if __GLASGOW_HASKELL__ >= 701
-{-# LANGUAGE Safe #-}
-#endif
 
 module Text.XHtml.Transitional.Elements where
 
diff --git a/xhtml.cabal b/xhtml.cabal
index 42eb16f..6b7676e 100644
--- a/xhtml.cabal
+++ b/xhtml.cabal
@@ -13,15 +13,22 @@ Description:        This package provides combinators for producing
 Stability:          Stable
 Category:           Web, XML, Pretty Printer
 Homepage:           https://github.com/haskell/xhtml
+Bug-Reports:        https://github.com/haskell/xhtml/issues
 Build-type:         Simple
-Cabal-version:      >= 1.6
+Cabal-version:      >= 1.10
 
 Source-repository head
     type:           git
     location:       https://github.com/haskell/xhtml
 
 library
-    Build-depends:  base >= 4.0 && < 5.0
+    Default-Language: Haskell2010
+    Other-Extensions: CPP
+    if impl(ghc >= 7.2)
+        Default-Extensions: Safe
+
+    Build-depends:  base >= 4 && < 5
+
     Exposed-modules:
                     Text.XHtml,
                     Text.XHtml.Frameset,
@@ -41,4 +48,3 @@ library
                     Text.XHtml.Internals
 
     ghc-options:    -Wall -fwarn-tabs
-    Extensions:     CPP



More information about the ghc-commits mailing list