The main-main to link with when building a DLL containing a Haskell in-proc COM component. \begin{code} {-# OPTIONS -#include "ComDllMain_stub.h" #-} module ComDllMain where import ComMain( comComponents ) import ComDll ( createIComDll ) import Com ( putMessage ) import Foreign.Ptr import Debug.Trace newComDll :: Ptr () -> IO (Ptr (Ptr ())) newComDll handle = do (ip,_) <- createIComDll handle comComponents return ip foreign export ccall "newComDll" newComDll :: Ptr () -> IO (Ptr (Ptr ())) \end{code}