views:

220

answers:

0

SQLite from PHX Software has combined a managed assembly (System.Data.SQLite) with an unmanaged dll (the SQLite 32- or 64-bit dll) into one file, and managed to link them together.

How do I do this? Do I need to embed the managed assembly into the unmanaged dll, or vice versa?

ie. my questions are:

  1. In which order do I need to do this?
  2. What tools or knowledge do I need in order to do this?
  3. How (if different) do I link to the exported functions from the unmanaged dll in my managed code?

The reason I ask this is that I want to build a managed zLib wrapper. I know there is managed classes in .NET but from experience they're a bit limited (and a bit boneheaded in that they don't do proper buffering), so I'd like to create my own copy, also because I want to learn how to do this.

So does anyone know what I need to do and how?

I've found the following:

I'm going to try this, but any additional information available would be nice as well.