diff --git a/Data/SearchEngine/DocIdSet.hs b/Data/SearchEngine/DocIdSet.hs
--- a/Data/SearchEngine/DocIdSet.hs
+++ b/Data/SearchEngine/DocIdSet.hs
@@ -159,6 +159,7 @@
     basicLength          (MV_DocId v) = GMVec.basicLength v
     basicUnsafeSlice i l (MV_DocId v) = MV_DocId (GMVec.basicUnsafeSlice i l v)
     basicUnsafeNew     l              = MV_DocId `liftM` GMVec.basicUnsafeNew l
+    basicInitialize      (MV_DocId v) = GMVec.basicInitialize v
     basicUnsafeReplicate l x          = MV_DocId `liftM` GMVec.basicUnsafeReplicate l (unDocId x)
     basicUnsafeRead  (MV_DocId v) i   = DocId `liftM`    GMVec.basicUnsafeRead v i
     basicUnsafeWrite (MV_DocId v) i x = GMVec.basicUnsafeWrite v i (unDocId x)
@@ -172,6 +173,7 @@
     {-# INLINE basicUnsafeSlice #-}
     {-# INLINE basicOverlaps #-}
     {-# INLINE basicUnsafeNew #-}
+    {-# INLINE basicInitialize #-}
     {-# INLINE basicUnsafeReplicate #-}
     {-# INLINE basicUnsafeRead #-}
     {-# INLINE basicUnsafeWrite #-}
@@ -199,4 +201,3 @@
     {-# INLINE basicUnsafeIndexM #-}
     {-# INLINE basicUnsafeCopy #-}
     {-# INLINE elemseq #-}
-
diff --git a/Data/SearchEngine/TermBag.hs b/Data/SearchEngine/TermBag.hs
--- a/Data/SearchEngine/TermBag.hs
+++ b/Data/SearchEngine/TermBag.hs
@@ -101,7 +101,7 @@
 -- not make it easy to trim arrays.
 --
 denseTable :: [TermBag] -> (Vec.Vector TermId, Vec.Vector TermCount)
-denseTable termbags = 
+denseTable termbags =
     (tids, tcts)
   where
     -- First merge the TermIds into one array
@@ -218,8 +218,9 @@
 instance GMVec.MVector MVec.MVector TermId where
     basicLength          (MV_TermId v) = GMVec.basicLength v
     basicUnsafeSlice i l (MV_TermId v) = MV_TermId (GMVec.basicUnsafeSlice i l v)
-    basicUnsafeNew     l              = MV_TermId `liftM` GMVec.basicUnsafeNew l
-    basicUnsafeReplicate l x          = MV_TermId `liftM` GMVec.basicUnsafeReplicate l (unTermId x)
+    basicUnsafeNew     l               = MV_TermId `liftM` GMVec.basicUnsafeNew l
+    basicInitialize      (MV_TermId v) = GMVec.basicInitialize v
+    basicUnsafeReplicate l x           = MV_TermId `liftM` GMVec.basicUnsafeReplicate l (unTermId x)
     basicUnsafeRead  (MV_TermId v) i   = TermId `liftM`    GMVec.basicUnsafeRead v i
     basicUnsafeWrite (MV_TermId v) i x = GMVec.basicUnsafeWrite v i (unTermId x)
     basicClear       (MV_TermId v)     = GMVec.basicClear v
@@ -232,6 +233,7 @@
     {-# INLINE basicUnsafeSlice #-}
     {-# INLINE basicOverlaps #-}
     {-# INLINE basicUnsafeNew #-}
+    {-# INLINE basicInitialize #-}
     {-# INLINE basicUnsafeReplicate #-}
     {-# INLINE basicUnsafeRead #-}
     {-# INLINE basicUnsafeWrite #-}
@@ -259,4 +261,3 @@
     {-# INLINE basicUnsafeIndexM #-}
     {-# INLINE basicUnsafeCopy #-}
     {-# INLINE elemseq #-}
-
diff --git a/changelog b/changelog
--- a/changelog
+++ b/changelog
@@ -1,3 +1,6 @@
+0.2.1.4 Mikolaj Konarski <mikolaj@well-typed.com> August 2017
+        * Compatibility with GHC 8.0.2 and new package versions (no API changes)
+
 0.2.1.3 Duncan Coutts <duncan@well-typed.com> May 2015
         * Compatibility with GHC 7.10 (no API changes)
 
diff --git a/demo/ExtractNameTerms.hs b/demo/ExtractNameTerms.hs
--- a/demo/ExtractNameTerms.hs
+++ b/demo/ExtractNameTerms.hs
@@ -13,6 +13,7 @@
 import Data.Maybe (maybeToList)
 
 import Data.Functor.Identity
+import Control.Applicative
 import Control.Monad
 import Control.Monad.List
 import Control.Monad.Writer
@@ -57,7 +58,7 @@
     get >>= emit
 
 newtype Split a = Split (StateT String (ListT (WriterT [String] Identity)) a)
-  deriving (Monad, MonadPlus, MonadState String)
+  deriving (Functor, Applicative, Alternative, Monad, MonadPlus, MonadState String)
 
 emit :: String -> Split ()
 emit x = Split (lift (lift (tell [x])))
diff --git a/full-text-search.cabal b/full-text-search.cabal
--- a/full-text-search.cabal
+++ b/full-text-search.cabal
@@ -1,5 +1,5 @@
 name:                full-text-search
-version:             0.2.1.3
+version:             0.2.1.4
 synopsis:            In-memory full text search engine
 description:         An in-memory full text search engine library. It lets you
                      run full-text queries on a collection of your documents.
@@ -40,7 +40,7 @@
                      the library is used in the
                      <http://hackage.haskell.org/package/hackage-server hackage-server>
                      where it provides the backend for the package search feature.
-
+bug-reports:         https://github.com/well-typed/full-text-search/issues
 license:             BSD3
 license-file:        LICENSE
 author:              Duncan Coutts
@@ -53,8 +53,8 @@
 extra-source-files:  changelog
 
 source-repository head
-  type:              darcs
-  location:          http://code.haskell.org/full-text-search/
+  type:              git
+  location:          git@github.com:well-typed/full-text-search.git
 
 flag build-search-demo
   default:           False
@@ -77,9 +77,9 @@
                        RecordWildCards,
                        GeneralizedNewtypeDeriving,
                        ScopedTypeVariables
-  build-depends:       base       >=4.5  && <4.9,
+  build-depends:       base       >=4.5  && <5.9,
                        array      >=0.4  && <0.6,
-                       vector     >=0.10 && <0.11,
+                       vector     >=0.11 && <0.13,
                        containers >=0.4  && <0.6,
                        text       >=0.11 && <1.3
   default-language:    Haskell2010
@@ -103,11 +103,11 @@
   else
     build-depends:     full-text-search,
                        base, text, containers, array,
-                       tokenize      == 0.1.*,
+                       tokenize      >= 0.1,
                        snowball      == 1.0.*,
                        transformers,
-                       split         == 0.2.*,
-                       Cabal         >= 1.14 && < 1.20,
+                       split         >= 0.2,
+                       Cabal         >= 1.14 && < 3,
                        bytestring, filepath, directory, tar, time, mtl
   build-tools:         alex, happy
   default-language:    Haskell2010
@@ -124,12 +124,11 @@
                        containers,
                        text,
                        QuickCheck       ==2.*,
-                       tasty            ==0.8.*,
-                       tasty-quickcheck ==0.8.*
+                       tasty            >=0.8,
+                       tasty-quickcheck >=0.8
   other-modules:       Test.Data.SearchEngine.TermBag,
                        Test.Data.SearchEngine.DocIdSet,
                        Data.SearchEngine.DocTermIds,
                        Data.SearchEngine.DocIdSet
   default-language:    Haskell2010
   ghc-options:         -Wall
-
