[Haskell-cafe] Unknown symbol `__dso_handle' with Template Haskell and wxHaskell

Erik Hesselink hesselink at gmail.com
Mon Dec 27 21:33:59 CET 2010


We had this problem with a binding to a C++ library (through a C
wrapper). GHCi and cabal didn't work, but ghc --make did. How are you
compiling exactly when you get this error? This is somehow related to
TH, without it, at least cabal also works. I'm not sure about GHCi.
There's also a relevant bug in the GHC trac, but I can't seem to find
it now.

Erik

On Sat, Dec 25, 2010 at 18:41, Alexander Bau <abau at imn.htwk-leipzig.de> wrote:
> Hi,
>
> I am using Template Haskell and wxHaskell [1]. When Graphics.UI.WX is
> loaded during THs code generation, I get the following error:
>
>> ...
>> Loading package wxdirect-0.12.1.3 ... linking ... done.
>> ghc: /usr/local/lib/wxcore-0.12.1.6/ghc-6.12.3/HSwxcore-0.12.1.6.o:
>> unknown symbol `__dso_handle'
>> Loading package wxcore-0.12.1.6 ...
>> linking ... ghc: unable to load package `wxcore-0.12.1.6'
>
> System stats:
> ghc-6.12.3
> template-haskell-2.4.0.1
> wx-0.12.1.6
>
> Regards,
>
> Alex
>
> [1] Example:
>
> -- Test.hs ----------------------
>
> {-# LANGUAGE TemplateHaskell #-}
> module Test2 where
>
> import Language.Haskell.TH
> import qualified Graphics.UI.WX as WX
>
> foo :: Q [Dec]
> foo = do
>  info <- reify ''WX.Color
>  runIO $ print info
>  return []
>
> -- Main.hs ----------------------
>
> {-# LANGUAGE TemplateHaskell #-}
> module Main where
>
> import Test
>
> $(foo)
>
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>



More information about the Haskell-Cafe mailing list