[mapserver-dev] linking with COM dll

ROBERT HOLLINGSWORTH reh2 at prodigy.net
Thu Mar 20 14:05:33 EDT 2008


hello all,
we're building a mapserver plugin dll for a custom vector source, so that client apps such as ArcMap and Geomedia can access this source thru WMS.  This as an alternative to using a proprietary ActiveX client plugin in IE.

anyway, my plugin dll is dependent on libmap.dll at runtime and therefore links with mapserver_i.lib.  so far so good.

But we also want to link with a COM dll that has been built in MSVC/C++6 and one of the functions we want to use has a return param that is a complex object/"collection"/"VARIANT" type that will be foreign to the conventional C in mapserver.

We couldn't link to the import library of this COM dll, so we had to create a parallel straight-C version without the VARIANT object, and were able to link with its import lib and run with the dll just fine.

But this is an unwanted parallel creation that we want to retire.

Question: does anyone know how I might make use of the COM dll in my mapserver plugin, which I'm building in Visual Studio .NET 2003 ("vc7" I guess).  A wider exploration has given me hints of such things as functions LoadLibrary( ) and GetProcAddress( ), plus there's the dlopen( ) that mapserver uses to grab my plugin, if that is of any help here.

thanks from an old UNIX programmer,
REH
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20080320/5fc5f452/attachment.html


More information about the mapserver-dev mailing list