diff --git a/LICENSE b/LICENSE
--- a/LICENSE
+++ b/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2015 Kai Zhang
+Copyright (c) 2016 Kai Zhang
 
 Permission is hereby granted, free of charge, to any person obtaining
 a copy of this software and associated documentation files (the
diff --git a/cbits/Selector.chs.c b/cbits/Selector.chs.c
deleted file mode 100644
--- a/cbits/Selector.chs.c
+++ /dev/null
@@ -1,21 +0,0 @@
-#include "IGraph/Internal/Selector.chs.h"
-igraph_vit_t * __c2hs_wrapped__igraph_vit_new(const igraph_t * graph,
-                                              igraph_vs_t * vs)
-{
-    return igraph_vit_new(graph, *vs);
-}
-igraph_eit_t * __c2hs_wrapped__igraph_eit_new(const igraph_t * graph,
-                                              igraph_es_t * es)
-{
-    return igraph_eit_new(graph, *es);
-}
-int __c2hs_wrapped__igraph_delete_vertices(igraph_t * graph,
-                                           const igraph_vs_t * vertices)
-{
-    return igraph_delete_vertices(graph, *vertices);
-}
-int __c2hs_wrapped__igraph_delete_edges(igraph_t * graph,
-                                        igraph_es_t * edges)
-{
-    return igraph_delete_edges(graph, *edges);
-}
diff --git a/cbits/Structure.chs.c b/cbits/Structure.chs.c
deleted file mode 100644
--- a/cbits/Structure.chs.c
+++ /dev/null
@@ -1,78 +0,0 @@
-#include "IGraph/Internal/Structure.chs.h"
-int __c2hs_wrapped__igraph_personalized_pagerank(const igraph_t * graph,
-                                                 igraph_pagerank_algo_t algo,
-                                                 igraph_vector_t * vector,
-                                                 igraph_real_t * value,
-                                                 const igraph_vs_t * vids,
-                                                 igraph_bool_t directed,
-                                                 igraph_real_t damping,
-                                                 igraph_vector_t * reset,
-                                                 const igraph_vector_t * weights,
-                                                 void * options)
-{
-    return igraph_personalized_pagerank(graph,
-                                        algo,
-                                        vector,
-                                        value,
-                                        *vids,
-                                        directed,
-                                        damping,
-                                        reset,
-                                        weights,
-                                        options);
-}
-int __c2hs_wrapped__igraph_pagerank(const igraph_t * graph,
-                                    igraph_pagerank_algo_t algo,
-                                    igraph_vector_t * vector,
-                                    igraph_real_t * value,
-                                    const igraph_vs_t * vids,
-                                    igraph_bool_t directed,
-                                    igraph_real_t damping,
-                                    const igraph_vector_t * weights,
-                                    void * options)
-{
-    return igraph_pagerank(graph,
-                           algo,
-                           vector,
-                           value,
-                           *vids,
-                           directed,
-                           damping,
-                           weights,
-                           options);
-}
-int __c2hs_wrapped__igraph_induced_subgraph(const igraph_t * graph,
-                                            igraph_t * res,
-                                            const igraph_vs_t * vids,
-                                            igraph_subgraph_implementation_t impl)
-{
-    return igraph_induced_subgraph(graph, res, *vids, impl);
-}
-int __c2hs_wrapped__igraph_closeness(const igraph_t * graph,
-                                     igraph_vector_t * res,
-                                     const igraph_vs_t * vids,
-                                     igraph_neimode_t mode,
-                                     const igraph_vector_t * weights,
-                                     igraph_bool_t normalized)
-{
-    return igraph_closeness(graph,
-                            res,
-                            *vids,
-                            mode,
-                            weights,
-                            normalized);
-}
-int __c2hs_wrapped__igraph_betweenness(const igraph_t * graph,
-                                       igraph_vector_t * res,
-                                       const igraph_vs_t * vids,
-                                       igraph_bool_t directed,
-                                       const igraph_vector_t * weights,
-                                       igraph_bool_t nobigint)
-{
-    return igraph_betweenness(graph,
-                              res,
-                              *vids,
-                              directed,
-                              weights,
-                              nobigint);
-}
diff --git a/cbits/haskelligraph.c b/cbits/haskelligraph.c
--- a/cbits/haskelligraph.c
+++ b/cbits/haskelligraph.c
@@ -1,6 +1,3 @@
-#ifndef HASKELL_IGRAPH
-#define HASKELL_IGRAPH
-
 #include <igraph/igraph.h>
 
 igraph_integer_t igraph_get_eid_(igraph_t* graph, igraph_integer_t pfrom, igraph_integer_t pto,
@@ -37,6 +34,3 @@
   /* attach attribute table */
   igraph_i_set_attribute_table(&igraph_cattribute_table);
 }
-
-
-#endif
diff --git a/haskell-igraph.cabal b/haskell-igraph.cabal
--- a/haskell-igraph.cabal
+++ b/haskell-igraph.cabal
@@ -2,7 +2,7 @@
 -- documentation, see http://haskell.org/cabal/users-guide/
 
 name:                haskell-igraph
-version:             0.1.0
+version:             0.2.0
 synopsis:            Imcomplete igraph bindings
 description:         This is an attempt to create a complete bindings for the
                      igraph<"http://igraph.org/c/"> library. Related work:
@@ -14,7 +14,7 @@
 copyright:           (c) 2016 Kai Zhang
 category:            Math
 build-type:          Simple
-cabal-version:       >=1.22
+cabal-version:       >=1.24
 
 Flag graphics
   Description: Enable graphics output
@@ -69,10 +69,9 @@
   hs-source-dirs:      src
   default-language:    Haskell2010
   build-tools:         c2hs >=0.25.0
-  C-Sources:
-    cbits/haskelligraph.c
-    cbits/Selector.chs.c
-    cbits/Structure.chs.c
+  c-sources:           cbits/haskelligraph.c
+  include-dirs:        cbits
+  includes:            cbits/haskelligraph.h
 
 test-suite tests
   type: exitcode-stdio-1.0
diff --git a/src/IGraph/Internal/Arpack.chs b/src/IGraph/Internal/Arpack.chs
--- a/src/IGraph/Internal/Arpack.chs
+++ b/src/IGraph/Internal/Arpack.chs
@@ -5,7 +5,7 @@
 import Foreign
 import Foreign.C.Types
 
-#include "cbits/haskelligraph.c"
+#include "haskelligraph.h"
 
 {#pointer *igraph_arpack_options_t as ArpackOptPtr foreign finalizer igraph_arpack_destroy newtype#}
 
diff --git a/src/IGraph/Internal/Clique.chs b/src/IGraph/Internal/Clique.chs
--- a/src/IGraph/Internal/Clique.chs
+++ b/src/IGraph/Internal/Clique.chs
@@ -10,7 +10,7 @@
 {#import IGraph.Internal.Graph #}
 {#import IGraph.Internal.Data #}
 
-#include "cbits/haskelligraph.c"
+#include "igraph/igraph.h"
 
 {#fun igraph_cliques as ^ { `IGraphPtr', `VectorPPtr', `Int', `Int' } -> `Int' #}
 
diff --git a/src/IGraph/Internal/Community.chs b/src/IGraph/Internal/Community.chs
--- a/src/IGraph/Internal/Community.chs
+++ b/src/IGraph/Internal/Community.chs
@@ -9,7 +9,7 @@
 {#import IGraph.Internal.Data #}
 {#import IGraph.Internal.Constants #}
 
-#include "cbits/haskelligraph.c"
+#include "igraph/igraph.h"
 
 {#fun igraph_community_spinglass as ^
 { `IGraphPtr'
diff --git a/src/IGraph/Internal/Constants.chs b/src/IGraph/Internal/Constants.chs
--- a/src/IGraph/Internal/Constants.chs
+++ b/src/IGraph/Internal/Constants.chs
@@ -3,7 +3,7 @@
 
 import Foreign
 
-#include "cbits/haskelligraph.c"
+#include "igraph/igraph.h"
 
 {#enum igraph_neimode_t as Neimode {underscoreToCase}
     deriving (Show, Eq) #}
diff --git a/src/IGraph/Internal/Data.chs b/src/IGraph/Internal/Data.chs
--- a/src/IGraph/Internal/Data.chs
+++ b/src/IGraph/Internal/Data.chs
@@ -10,7 +10,7 @@
 import Data.List (transpose)
 import Data.List.Split (chunksOf)
 
-#include "cbits/haskelligraph.c"
+#include "haskelligraph.h"
 
 {#pointer *igraph_vector_t as VectorPtr foreign finalizer igraph_vector_destroy newtype#}
 
diff --git a/src/IGraph/Internal/Graph.chs b/src/IGraph/Internal/Graph.chs
--- a/src/IGraph/Internal/Graph.chs
+++ b/src/IGraph/Internal/Graph.chs
@@ -10,7 +10,7 @@
 {#import IGraph.Internal.Data #}
 {#import IGraph.Internal.Constants #}
 
-#include "cbits/haskelligraph.c"
+#include "haskelligraph.h"
 
 {#pointer *igraph_t as IGraphPtr foreign finalizer igraph_destroy newtype#}
 
diff --git a/src/IGraph/Internal/Initialization.chs b/src/IGraph/Internal/Initialization.chs
--- a/src/IGraph/Internal/Initialization.chs
+++ b/src/IGraph/Internal/Initialization.chs
@@ -1,7 +1,7 @@
 {-# LANGUAGE ForeignFunctionInterface #-}
 module IGraph.Internal.Initialization where
 
-#include "cbits/haskelligraph.c"
+#include "haskelligraph.h"
 
 data HasInit
 
diff --git a/src/IGraph/Layout.hs b/src/IGraph/Layout.hs
--- a/src/IGraph/Layout.hs
+++ b/src/IGraph/Layout.hs
@@ -16,27 +16,27 @@
 import           IGraph.Internal.Data
 import           IGraph.Internal.Layout
 
-data LayoutMethod = KamadaKawai
-    { kk_seed      :: !(Maybe [(Double, Double)])
-    , kk_nIter     :: !Int
-    , kk_sigma     :: (Int -> Double) -- ^ The base standard deviation of position
-                                  -- change proposals
-    , kk_startTemp :: !Double  -- ^ The initial temperature for the annealing
-    , kk_coolFact  :: !Double  -- ^ The cooling factor for the simulated annealing
-    , kk_const     :: (Int -> Double)  -- ^ The Kamada-Kawai vertex attraction constant
-    }
-                  | LGL   -- ^ the Large Graph Layout algorithm
-    { lgl_nIter      :: !Int
-    , lgl_maxdelta   :: (Int -> Double)  -- ^ The maximum length of the move allowed for
-                               -- a vertex in a single iteration.
-                               -- A reasonable default is the number of vertices.
-    , lgl_area       :: (Int -> Double)  -- ^ This parameter gives the area of the square
-                           -- on which the vertices will be placed. A reasonable
-                           -- default value is the number of vertices squared.
-    , lgl_coolexp    :: !Double  -- ^ The cooling exponent. A reasonable default value is 1.5.
-    , lgl_repulserad :: (Int -> Double) -- ^ Determines the radius at which vertex-vertex repulsion cancels out attraction of adjacent vertices. A reasonable default value is area times the number of vertices.
-    , lgl_cellsize   :: (Int -> Double)
-    }
+data LayoutMethod =
+    KamadaKawai { kk_seed      :: !(Maybe [(Double, Double)])
+                , kk_nIter     :: !Int
+                , kk_sigma     :: (Int -> Double) -- ^ The base standard deviation of
+                -- position change proposals
+                , kk_startTemp :: !Double  -- ^ The initial temperature for the annealing
+                , kk_coolFact  :: !Double  -- ^ The cooling factor for the simulated annealing
+                , kk_const     :: (Int -> Double)  -- ^ The Kamada-Kawai vertex attraction constant
+                }
+  | LGL { lgl_nIter      :: !Int
+        , lgl_maxdelta   :: (Int -> Double)  -- ^ The maximum length of the move allowed
+        -- for a vertex in a single iteration. A reasonable default is the number of vertices.
+        , lgl_area       :: (Int -> Double)  -- ^ This parameter gives the area
+        -- of the square on which the vertices will be placed. A reasonable
+        -- default value is the number of vertices squared.
+        , lgl_coolexp    :: !Double  -- ^ The cooling exponent. A reasonable default value is 1.5.
+        , lgl_repulserad :: (Int -> Double) -- ^ Determines the radius at which
+        -- vertex-vertex repulsion cancels out attraction of adjacent vertices.
+        -- A reasonable default value is area times the number of vertices.
+        , lgl_cellsize   :: (Int -> Double)
+        }
 
 defaultKamadaKawai :: LayoutMethod
 defaultKamadaKawai = KamadaKawai
diff --git a/tests/Test/Basic.hs b/tests/Test/Basic.hs
--- a/tests/Test/Basic.hs
+++ b/tests/Test/Basic.hs
@@ -28,14 +28,14 @@
     ]
   where
     edgeList = sort $ unsafePerformIO $ randEdges 1000 100
-    gr = mkGraph (100,Nothing) (edgeList, Nothing) :: LGraph D () ()
-    simple = mkGraph (3,Nothing) ([(0,1),(1,2),(2,0)],Nothing) :: LGraph D () ()
+    gr = mkGraph (replicate 100 ()) $ zip edgeList $ repeat () :: LGraph D () ()
+    simple = mkGraph (replicate 3 ()) $ zip [(0,1),(1,2),(2,0)] $ repeat () :: LGraph D () ()
 
 graphEdit :: TestTree
 graphEdit = testGroup "Graph editing"
     [ testCase "" $ [(1,2)] @=? (sort $ edges simple') ]
   where
-    simple = mkGraph (3,Nothing) ([(0,1),(1,2),(2,0)],Nothing) :: LGraph U () ()
+    simple = mkGraph (replicate 3 ()) $ zip [(0,1),(1,2),(2,0)] $ repeat () :: LGraph U () ()
     simple' = runST $ do
         g <- thaw simple
         delEdges [(0,1),(0,2)] g
diff --git a/tests/Test/Structure.hs b/tests/Test/Structure.hs
--- a/tests/Test/Structure.hs
+++ b/tests/Test/Structure.hs
@@ -27,7 +27,7 @@
             , ["a","c"], [("a","c"), ("c","a")] )
     test (ori,ns,expect) = sort expect @=? sort result
       where
-        gr = fromLabeledEdges ori :: LGraph D String ()
+        gr = fromLabeledEdges $ zip ori $ repeat () :: LGraph D String ()
         ns' = map (head . getNodes gr) ns
         gr' = inducedSubgraph gr ns'
         result = map (nodeLab gr' *** nodeLab gr') $ edges gr'
