[gdal-dev] Re: Link GDAL with MinGW
lucafasano at interfree.it
Thu Feb 26 09:03:01 EST 2009
Ari Jolma <ari.jolma <at> tkk.fi> writes:
> MinGW gcc generates .dll.a files, which are the link libraries, but it
> can also use the plain dll to link against.
> However, when you mention gdal16.dll, it sounds like you're trying to
> link against a GDAL dll that was generated with VC. The C++ API is very
> difficult to use from such dll when you're developing with MinGW if not
I'm not sure of this. In the same project I linked *correctly* hdf5 library,
which is a dll file and I think compiled with VC.
I've problem only with gdal.
Perhaps it needs some flags when compile.
> LF kirjoitti:
> > Hi to everyone,
> > I'm trying to make a plugin for GDAL. So I need to use some GDALDataset
> > (AddBand, GetDriver, setGCPs, ...).
> > When I compile my code with MinGW it's all OK, but when MinGW starts
> > doesn't found these methods and give me "undefined reference" to all them.
> > In makefile I added to LNK_FLAGS variable both gdal16.dll and its path.
More information about the gdal-dev