initialize :: FilePath -> FilePath -> FilePath -> IO MegaHal
initialize brainDir errorFile statusFile = do
    -- Setup the logfile and brain and register the CString to be dealloc
    err <- newCString errorFile
    st <- newCString statusFile
    dir <- newCString brainDir

    -- Actually init megahal
    cxt <- m_initialize err st dir

    return $ MegaHal cxt [err, st, dir]


-- TODO: uncertain if we need to free the returned string or what
initialize :: FilePath -> FilePath -> FilePath -> IO MegaHal
initialize brainDir errorFile statusFile = do
    -- Setup the logfile and brain and register the CString to be dealloc
    err <- newCString errorFile
    st <- newCString statusFile
    dir <- newCString brainDir

    -- Actually init megahal
    cxt <- m_initialize err st dir

    return $ MegaHal cxt [err, st, dir]


-- TODO: uncertain if we need to free the returned string or what
initialize brainDir errorFile statusFile = do
    -- Setup the logfile and brain and register the CString to be dealloc
    err <- newCString errorFile
    st <- newCString statusFile
    dir <- newCString brainDir

    -- Actually init megahal
    cxt <- m_initialize err st dir

    return $ MegaHal cxt [err, st, dir]


-- TODO: uncertain if we need to free the returned string or what