diff --git a/Network/Curl.hs b/Network/Curl.hs
--- a/Network/Curl.hs
+++ b/Network/Curl.hs
@@ -286,7 +286,7 @@
   return ()
 
 -- Use 'callbackWriter' instead.
-{-# OBSOLETE #-}
+{-# DEPRECATED #-}
 easyWriter :: (String -> IO ()) -> WriteFunction
 easyWriter = callbackWriter
 
diff --git a/Network/Curl/Code.hs b/Network/Curl/Code.hs
--- a/Network/Curl/Code.hs
+++ b/Network/Curl/Code.hs
@@ -1,4 +1,5 @@
-{-# OPTIONS -fffi -fvia-C -#include "curl/curl.h" #-}
+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# OPTIONS -fvia-C -#include "curl/curl.h" #-}
 --------------------------------------------------------------------
 -- |
 -- Module    : Curl.Code
diff --git a/Network/Curl/Easy.hs b/Network/Curl/Easy.hs
--- a/Network/Curl/Easy.hs
+++ b/Network/Curl/Easy.hs
@@ -1,4 +1,5 @@
-{-# OPTIONS -fffi -fvia-C -#include "curl/curl.h" #-}
+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# OPTIONS -fvia-C -#include "curl/curl.h" #-}
 --------------------------------------------------------------------
 -- |
 -- Module    : Curl.Easy
@@ -168,25 +169,25 @@
   "curl_easy_reset" easy_reset :: CurlH -> IO ()
 
 foreign import ccall
-  "curl_easy_setopt" easy_setopt_long :: CurlH -> Int -> Long -> IO CInt
+  "curl_easy_setopt_long" easy_setopt_long :: CurlH -> Int -> Long -> IO CInt
 
 foreign import ccall
-  "curl_easy_setopt" easy_setopt_llong :: CurlH -> Int -> LLong -> IO CInt
+  "curl_easy_setopt_longlong" easy_setopt_llong :: CurlH -> Int -> LLong -> IO CInt
 
 foreign import ccall
-  "curl_easy_setopt" easy_setopt_string :: CurlH -> Int -> Ptr CChar -> IO CInt
+  "curl_easy_setopt_string" easy_setopt_string :: CurlH -> Int -> Ptr CChar -> IO CInt
 
 foreign import ccall
-  "curl_easy_setopt" easy_setopt_ptr :: CurlH -> Int -> Ptr a -> IO CInt
+  "curl_easy_setopt_ptr" easy_setopt_ptr :: CurlH -> Int -> Ptr a -> IO CInt
 
 foreign import ccall
-  "curl_easy_setopt" easy_setopt_fptr :: CurlH -> Int -> FunPtr a -> IO CInt
+  "curl_easy_setopt_ptr" easy_setopt_fptr :: CurlH -> Int -> FunPtr a -> IO CInt
 
 foreign import ccall
-  "curl_easy_setopt" easy_setopt_wfun :: CurlH -> Int -> FunPtr WriteFunction -> IO CInt
+  "curl_easy_setopt_ptr" easy_setopt_wfun :: CurlH -> Int -> FunPtr WriteFunction -> IO CInt
 
 foreign import ccall
-  "curl_easy_setopt" easy_setopt_rfun :: CurlH -> Int -> FunPtr ReadFunctionPrim -> IO CInt
+  "curl_easy_setopt_ptr" easy_setopt_rfun :: CurlH -> Int -> FunPtr ReadFunctionPrim -> IO CInt
 
 
 foreign import ccall "wrapper"
diff --git a/Network/Curl/Info.hs b/Network/Curl/Info.hs
--- a/Network/Curl/Info.hs
+++ b/Network/Curl/Info.hs
@@ -1,4 +1,5 @@
-{-# OPTIONS -fffi -fvia-C -#include "curl/curl.h" #-}
+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# OPTIONS -fvia-C -#include "curl/curl.h" #-}
 --------------------------------------------------------------------
 -- |
 -- Module    : Network.Curl.Info
@@ -132,7 +133,7 @@
 getInfoStr :: Curl -> String -> Long -> IO InfoValue
 getInfoStr h loc tg =
      alloca $ \ ps -> do
-        rc <- curlPrim h $ \_ p -> easy_getinfo_str p (stringTag + tg) ps
+        rc <- curlPrim h $ \_ p -> easy_getinfo_str p tg ps
         case rc of
           0 -> do
              s <- peek ps
@@ -144,7 +145,7 @@
 getInfoLong :: Curl -> String -> Long -> IO InfoValue
 getInfoLong h loc tg =
      alloca $ \ pl -> do
-        rc <- curlPrim h $ \_ p -> easy_getinfo_long p (longTag + tg) pl
+        rc <- curlPrim h $ \_ p -> easy_getinfo_long p tg pl
         case rc of
           0 -> do
              l <- peek pl
@@ -154,7 +155,7 @@
 getInfoDouble :: Curl -> String -> Long -> IO InfoValue
 getInfoDouble h loc tg =
      alloca $ \ pd -> do
-        rc <- curlPrim h $ \_ p -> easy_getinfo_double p (doubleTag + tg) pd
+        rc <- curlPrim h $ \_ p -> easy_getinfo_double p tg pd
         case rc of
           0 -> do
              d <- peek pd
@@ -164,7 +165,7 @@
 getInfoSList :: Curl -> String -> Long -> IO InfoValue
 getInfoSList h loc tg =
      alloca $ \ ps -> do
-        rc <- curlPrim h $ \_ p -> easy_getinfo_slist p (slistTag + tg) ps
+        rc <- curlPrim h $ \_ p -> easy_getinfo_slist p tg ps
         case rc of
           0 -> do
              p <- peek ps
@@ -183,13 +184,13 @@
 
 -- FFI decls
 foreign import ccall
-  "curl_easy_getinfo" easy_getinfo_long :: CurlH -> Long -> Ptr Long -> IO CInt
+  "curl_easy_getinfo_long" easy_getinfo_long :: CurlH -> Long -> Ptr Long -> IO CInt
 
 foreign import ccall
-  "curl_easy_getinfo" easy_getinfo_str  :: CurlH -> Long -> Ptr CString -> IO CInt
+  "curl_easy_getinfo_string" easy_getinfo_str  :: CurlH -> Long -> Ptr CString -> IO CInt
 
 foreign import ccall
-  "curl_easy_getinfo" easy_getinfo_double :: CurlH -> Long -> Ptr Double -> IO CInt
+  "curl_easy_getinfo_double" easy_getinfo_double :: CurlH -> Long -> Ptr Double -> IO CInt
 
 foreign import ccall
-  "curl_easy_getinfo" easy_getinfo_slist :: CurlH -> Long -> Ptr (Ptr (Ptr CChar)) -> IO CInt
+  "curl_easy_getinfo_slist" easy_getinfo_slist :: CurlH -> Long -> Ptr (Ptr (Ptr CChar)) -> IO CInt
diff --git a/Network/Curl/Opts.hs b/Network/Curl/Opts.hs
--- a/Network/Curl/Opts.hs
+++ b/Network/Curl/Opts.hs
@@ -165,24 +165,27 @@
  | CurlHttpTransferDecoding Bool        -- ^ Disable transfer decoding; if disabled, curl will turn off chunking.
  | CurlHttpContentDecoding  Bool        -- ^ Disable content decoding, getting the raw bits.
 
+instance Show CurlOption where
+  show x = showCurlOption x
+
 data HttpVersion
  = HttpVersionNone
  | HttpVersion10
  | HttpVersion11
-   deriving ( Enum )
+   deriving ( Enum,Show )
 
 data TimeCond
  = TimeCondNone
  | TimeCondIfModSince
  | TimeCondIfUnmodSince
  | TimeCondLastMode
-   deriving ( Enum )
+   deriving ( Enum, Show )
  
 data NetRcOption
  = NetRcIgnored
  | NetRcOptional
  | NetRcRequired
-   deriving ( Enum )
+   deriving ( Enum, Show )
 
 data HttpAuth
  = HttpAuthNone
@@ -192,6 +195,7 @@
  | HttpAuthNTLM
  | HttpAuthAny
  | HttpAuthAnySafe
+   deriving ( Enum, Show )
 
 toHttpAuthMask :: [HttpAuth] -> Long
 toHttpAuthMask [] = 0
@@ -214,6 +218,7 @@
  | SSHAuthPassword
  | SSHAuthHost
  | SSHAuthKeyboard
+   deriving ( Show )
 
 
 toSSHAuthMask :: [SSHAuthType] -> Long
@@ -511,3 +516,147 @@
 
 u_cptr :: Unmarshaller a -> Int -> Ptr CChar -> IO a
 u_cptr um x p = u_ptr um x (castPtr p)
+
+showCurlOption :: CurlOption -> String
+showCurlOption o = 
+  case o of
+    CurlFileObj p  -> "CurlFileObj " ++ show p
+    CurlURL u      -> "CurlURL " ++ show u
+    CurlPort p     -> "CurlPort " ++ show p
+    CurlProxy s    -> "CurlProxy " ++ show s
+    CurlUserPwd p  -> "CurlUserPwd " ++ show p
+    CurlProxyUserPwd p -> "CurlProxyUserPwd " ++ show p
+    CurlRange p -> "CurlRange " ++ show p
+    CurlInFile p -> "CurlInFile " ++ show p
+    CurlErrorBuffer p -> "CurlErrorBuffer " ++ show p
+    CurlWriteFunction{} -> "CurlWriteFunction <fun>"
+    CurlReadFunction{}  -> "CurlReadFunction <fun>"
+    CurlTimeout l       -> "CurlTimeout " ++ show l
+    CurlInFileSize l    -> "CurlInFileSize " ++ show l
+    CurlPostFields p    -> "CurlPostFields " ++ show p
+    CurlReferer p       -> "CurlReferer " ++ show p
+    CurlFtpPort p       -> "CurlFtpPort " ++ show p
+    CurlUserAgent p     -> "CurlUserAgent " ++ show p
+    CurlLowSpeed  p     -> "CurlLowSpeed " ++ show p
+    CurlLowSpeedTime p  -> "CurlLowSpeedTime " ++ show p
+    CurlResumeFrom p    -> "CurlResumeFrom " ++ show p
+    CurlCookie p        -> "CurlCookie " ++ show p
+    CurlHttpHeaders p   -> "CurlHttpHeaders " ++ show p
+    CurlHttpPost p      -> "CurlHttpPost " ++ show p
+    CurlSSLCert p       -> "CurlSSLCert " ++ show p
+    CurlSSLPassword p   -> "CurlSSLPassword " ++ show p
+    CurlSSLKeyPassword p -> "CurlSSLKeyPassword " ++ show p
+    CurlCRLF p -> "CurlCRLF " ++ show p
+    CurlQuote p -> "CurlQuote " ++ show p
+    CurlWriteHeader p -> "CurlWriteHeader " ++ show p
+    CurlCookieFile p -> "CurlCookieFile " ++ show p
+    CurlSSLVersion p -> "CurlSSLVersion " ++ show p
+    CurlTimeCondition p -> "CurlTimeCondition " ++ show p
+    CurlTimeValue p -> "CurlTimeValue " ++ show p
+    CurlCustomRequest p -> "CurlCustomRequest " ++ show p
+    CurlPostQuote p -> "CurlPostQuote " ++ show p
+    CurlWriteInfo p -> "CurlWriteInfo " ++ show p
+    CurlVerbose p -> "CurlVerbose " ++ show p
+    CurlHeader p -> "CurlHeader " ++ show p
+    CurlNoProgress p -> "CurlNoProgress " ++ show p
+    CurlNoBody p -> "CurlNoBody " ++ show p
+    CurlFailOnError p -> "CurlFailOnError " ++ show p
+    CurlUpload p -> "CurlUpload " ++ show p
+    CurlPost p -> "CurlPost " ++ show p
+    CurlFtpListOnly p -> "CurlFtpListOnly " ++ show p
+    CurlFtpAppend p -> "CurlFtpAppend " ++ show p
+    CurlUseNetRc p -> "CurlUseNetRc " ++ show p
+    CurlFollowLocation p -> "CurlFollowLocation " ++ show p
+    CurlTransferTextASCII p -> "CurlTransferTextASCII " ++ show p
+    CurlPut p -> "CurlPut " ++ show p
+    CurlProgressFunction{} -> "CurlProgressFunction <fun>"
+    CurlProgressData p -> "CurlProgressData " ++ show p
+    CurlAutoReferer p -> "CurlAutoReferer " ++ show p
+    CurlProxyPort p -> "CurlProxyPort " ++ show p
+    CurlPostFieldSize p -> "CurlPostFieldSize " ++ show p
+    CurlHttpProxyTunnel p -> "CurlHttpProxyTunnel " ++ show p
+    CurlInterface p -> "CurlInterface " ++ show p
+    CurlKrb4Level p -> "CurlKrb4Level " ++ show p
+    CurlSSLVerifyPeer p -> "CurlSSLVerifyPeer " ++ show p
+    CurlCAInfo p -> "CurlCAInfo " ++ show p
+    CurlMaxRedirs p -> "CurlMaxRedirs " ++ show p
+    CurlFiletime p -> "CurlFiletime " ++ show p
+    CurlTelnetOptions p -> "CurlTelnetOptions " ++ show p
+    CurlMaxConnects p -> "CurlMaxConnects " ++ show p
+    CurlClosePolicy p -> "CurlClosePolicy " ++ show p
+    CurlFreshConnect p -> "CurlFreshConnect " ++ show p
+    CurlForbidReuse p -> "CurlForbidReuse " ++ show p
+    CurlRandomFile p -> "CurlRandomFile " ++ show p
+    CurlEgdSocket p -> "CurlEgdSocket " ++ show p
+    CurlConnectTimeout p -> "CurlConnectTimeout " ++ show p
+    CurlHeaderFunction{} -> "CurlHeaderFunction <fun>"
+    CurlHttpGet p -> "CurlHttpGet " ++ show p
+    CurlSSLVerifyHost p -> "CurlSSLVerifyHost " ++ show p
+    CurlCookieJar p -> "CurlCookieJar " ++ show p
+    CurlSSLCipherList p -> "CurlSSLCipherList " ++ show p
+    CurlHttpVersion p -> "CurlHttpVersion " ++ show p
+    CurlFtpUseEPSV p -> "CurlFtpUseEPSV " ++ show p
+    CurlSSLCertType p -> "CurlSSLCertType " ++ show p
+    CurlSSLKey p -> "CurlSSLKey " ++ show p
+    CurlSSLKeyType p -> "CurlSSLKeyType " ++ show p
+    CurlSSLEngine p -> "CurlSSLEngine " ++ show p
+    CurlSSLEngineDefault-> "CurlSSLEngineDefault"
+    CurlDNSUseGlobalCache p -> "CurlDNSUseGlobalCache " ++ show p
+    CurlDNSCacheTimeout p -> "CurlDNSCacheTimeout " ++ show p
+    CurlPreQuote p -> "CurlPreQuote " ++ show p
+    CurlDebugFunction{} -> "CurlDebugFunction <fun>"
+    CurlDebugData p -> "CurlDebugData " ++ show p
+    CurlCookieSession p -> "CurlCookieSession " ++ show p
+    CurlCAPath p -> "CurlCAPath " ++ show p
+    CurlBufferSize p -> "CurlBufferSize " ++ show p
+    CurlNoSignal p -> "CurlNoSignal " ++ show p
+    CurlShare p -> "CurlShare " ++ show p
+    CurlProxyType p -> "CurlProxyType " ++ show p
+    CurlEncoding p -> "CurlEncoding " ++ show p
+    CurlPrivate p -> "CurlPrivate " ++ show p
+    CurlHttp200Aliases p -> "CurlHttp200Aliases " ++ show p
+    CurlUnrestrictedAuth p -> "CurlUnrestrictedAuth " ++ show p
+    CurlFtppUseEPRT p -> "CurlFtppUseEPRT " ++ show p
+    CurlHttpAuth p -> "CurlHttpAuth " ++ show p
+    CurlSSLCtxFunction{} -> "CurlSSLCtxFunction <fun>"
+    CurlSSLCtxData p -> "CurlSSLCtxData " ++ show p
+    CurlFtpCreateMissingDirs p -> "CurlFtpCreateMissingDirs " ++ show p
+    CurlProxyAuth p -> "CurlProxyAuth " ++ show p
+    CurlFtpResponseTimeout p -> "CurlFtpResponseTimeout " ++ show p
+    CurlIPResolve p -> "CurlIPResolve " ++ show p
+    CurlMaxFileSize p -> "CurlMaxFileSize " ++ show p
+    CurlInFileSizeLarge p -> "CurlInFileSizeLarge " ++ show p
+    CurlResumeFromLarge p -> "CurlResumeFromLarge " ++ show p
+    CurlMaxFileSizeLarge p -> "CurlMaxFileSizeLarge " ++ show p
+    CurlNetrcFile p -> "CurlNetrcFile " ++ show p
+    CurlFtpSSL p -> "CurlFtpSSL " ++ show p
+    CurlPostFieldSizeLarge p -> "CurlPostFieldSizeLarge " ++ show p
+    CurlTCPNoDelay p -> "CurlTCPNoDelay " ++ show p
+    CurlFtpSSLAuth p -> "CurlFtpSSLAuth " ++ show p
+    CurlIOCTLFunction p -> "CurlIOCTLFunction " ++ show p
+    CurlIOCTLData p -> "CurlIOCTLData " ++ show p
+    CurlFtpAccount p -> "CurlFtpAccount " ++ show p
+    CurlCookieList p -> "CurlCookieList " ++ show p
+    CurlIgnoreContentLength p -> "CurlIgnoreContentLength " ++ show p
+    CurlFtpSkipPASVIP p -> "CurlFtpSkipPASVIP " ++ show p
+    CurlFtpFileMethod p -> "CurlFtpFileMethod " ++ show p
+    CurlLocalPort p -> "CurlLocalPort " ++ show p
+    CurlLocalPortRange p -> "CurlLocalPortRange " ++ show p
+    CurlConnectOnly p -> "CurlConnectOnly " ++ show p
+    CurlConvFromNetworkFunction p -> "CurlConvFromNetworkFunction " ++ show p
+    CurlConvToNetworkFunction p -> "CurlConvToNetworkFunction " ++ show p
+    CurlConvFromUtf8Function p -> "CurlConvFromUtf8Function " ++ show p
+    CurlMaxSendSpeedLarge p -> "CurlMaxSendSpeedLarge " ++ show p
+    CurlMaxRecvSpeedLarge p -> "CurlMaxRecvSpeedLarge " ++ show p
+    CurlFtpAlternativeToUser p -> "CurlFtpAlternativeToUser " ++ show p
+    CurlSockOptFunction p -> "CurlSockOptFunction " ++ show p
+    CurlSockOptData p -> "CurlSockOptData " ++ show p
+    CurlSSLSessionIdCache p -> "CurlSSLSessionIdCache " ++ show p
+    CurlSSHAuthTypes p -> "CurlSSHAuthTypes " ++ show p
+    CurlSSHPublicKeyFile p -> "CurlSSHPublicKeyFile " ++ show p
+    CurlSSHPrivateKeyFile p -> "CurlSSHPrivateKeyFile " ++ show p
+    CurlFtpSSLCCC p -> "CurlFtpSSLCCC " ++ show p
+    CurlTimeoutMS p -> "CurlTimeoutMS " ++ show p
+    CurlConnectTimeoutMS p -> "CurlConnectTimeoutMS " ++ show p
+    CurlHttpTransferDecoding p -> "CurlHttpTransferDecoding " ++ show p
+    CurlHttpContentDecoding p -> "CurlHttpContentDecoding " ++ show p
diff --git a/Network/Curl/Post.hs b/Network/Curl/Post.hs
--- a/Network/Curl/Post.hs
+++ b/Network/Curl/Post.hs
@@ -1,4 +1,5 @@
-{-# OPTIONS -fffi -fvia-C -#include "curl/curl.h" #-}
+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# OPTIONS -fvia-C -#include "curl/curl.h" #-}
 --------------------------------------------------------------------
 -- |
 -- Module    : Network.Curl.Post
@@ -35,12 +36,13 @@
      , extraHeaders :: [Header]
 -- not yet:     , extraEntries :: [HttpPost]
      , showName     :: Maybe String
-     }
+     } deriving ( Show )
 
 data Content
  = ContentFile   FilePath
  | ContentBuffer (Ptr CChar) Long -- byte arrays also?
  | ContentString String
+   deriving ( Show )
 
 multiformString :: String -> String -> HttpPost
 multiformString x y = 
diff --git a/Network/Curl/Types.hs b/Network/Curl/Types.hs
--- a/Network/Curl/Types.hs
+++ b/Network/Curl/Types.hs
@@ -1,4 +1,4 @@
-{-# OPTIONS -fffi -fglasgow-exts #-}
+{-# LANGUAGE ForeignFunctionInterface, EmptyDataDecls #-}
 --------------------------------------------------------------------
 -- |
 -- Module    : Network.Curl.Types
diff --git a/curl.cabal b/curl.cabal
--- a/curl.cabal
+++ b/curl.cabal
@@ -1,5 +1,5 @@
 name:               curl
-version:            1.3.2.1
+version:            1.3.2.2
 synopsis:           Haskell binding to libcurl
 description:
     libcurl is a client-side URL transfer library, supporting FTP, FTPS, HTTP,
@@ -13,7 +13,7 @@
 license:            BSD3
 license-file:       LICENSE
 author:             Sigbjorn Finne
-maintainer:         emertens@galois.com, diatchki@.galois.com
+maintainer:         Sigbjorn Finne <sigbjorn.finne@gmail.com>
 build-depends:      base
 build-type:         Configure
 cabal-version:      >= 1.2
@@ -33,12 +33,13 @@
                    Network.Curl.Easy
                    Network.Curl.Debug
 
+  c-sources: curlc.c
   Extra-libraries: curl
   Extensions:      CPP, ForeignFunctionInterface
   Ghc-options:     -Wall -fvia-C
 
   Build-Depends: base
   if flag(new-base)
-    Build-depends: base >= 3, containers
+    Build-depends: base >= 3 && < 4, containers
   else
     Build-depends: base < 3
diff --git a/curlc.c b/curlc.c
new file mode 100644
--- /dev/null
+++ b/curlc.c
@@ -0,0 +1,34 @@
+#include <curl/curl.h>
+
+int curl_easy_getinfo_long(void *curl, long tg, long *pl)
+{
+    return curl_easy_getinfo(curl, CURLINFO_LONG+tg, pl);
+}
+
+int curl_easy_getinfo_string(void *curl, long tg, char **s)
+{
+    return curl_easy_getinfo(curl, CURLINFO_STRING+tg, s);
+}
+
+int curl_easy_getinfo_double(void *curl, long tg, double *d)
+{
+    return curl_easy_getinfo(curl, CURLINFO_DOUBLE+tg, d);
+}
+
+int curl_easy_getinfo_slist(void *curl, long tg, char ***s)
+{
+    return curl_easy_getinfo(curl, CURLINFO_SLIST+tg, s);
+}
+
+
+int curl_easy_setopt_long(void *curl, int i, long x)
+{ return curl_easy_setopt(curl,i,x); }
+
+int curl_easy_setopt_longlong(void *curl, int i, long long x)
+{ return curl_easy_setopt(curl,i,x); }
+
+int curl_easy_setopt_string(void *curl, int i, char *x)
+{ return curl_easy_setopt(curl,i,x); }
+
+int curl_easy_setopt_ptr(void *curl, int i, void *x)
+{ return curl_easy_setopt(curl,i,x); }
