[gdal-dev] Supporting ECW as a plugin. (Windows)
William Kyngesburye
woklist at kyngchaos.com
Tue Dec 9 13:16:34 EST 2008
On Dec 9, 2008, at 11:37 AM, Daniele Romagnoli wrote:
> When running gdalinfo I get this error:
> ERROR 1: Can't find requested entry point: GDALRegister_ECW_JP2ECW
>
> Indeed, putting the generated DLL in the "depends/dependency walker"
> tool, I have only noticed the presence of the following two functions:
> - GDALRegister_ECW
> - GDALRegister_JP2ECW
>
> whilst the GDALDriverManager:autoLoadDrivers function does:
> 1) looks for a DLL in the specified GDAL_DRIVER_PATH --->
> gdal_ECW_JP2ECW.DLL
> 2) tries to call GDALRegister_ECW_JP2ECW function (missing).
>
> The weird thing is that "ecwdataset.cpp" contains that function but
> the generated DLL doesn't contain it.
> I have also noticed that the ECW plugin available here (http://download.osgeo.org/gdal/win32/1.5/
> ) doesn't contain that registration function.
>
> Does anyone already successfully used the ECW as a separated plugin
> on windows?
> Am I doing something wrong?
> Any tips/suggestion would be really appreciated.
>
Strange coincidence, or it points to some GDAL bug: I was messing
around with ECW on OSX as a plugin this weekend. When I compiled the
plugin for GDAL 1.6, it loaded. When I compiled the plugin for GDAL
1.5, I got the equivalent error:
ERROR 1: dlsym(0x10160bd50, _GDALRegister_ECW_JP2ECW): symbol not found
ERROR 1: dlsym(0x10160bd50, _GDALRegisterMe): symbol not found
Simply renaming the plugin either gdal_ECW or gdal_JP2ECW works to
load the driver for the named format.
Having one as gdal_ECW, then symlinking that to gdal_JP2ECW works to
load both. I don't know what the equivalent to symlink is on Windows,
but duplicating the binary should also work.
-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/
Theory of the Universe
There is a theory which states that if ever anyone discovers exactly
what the universe is for and why it is here, it will instantly
disappear and be replaced by something even more bizarrely
inexplicable. There is another theory which states that this has
already happened.
-Hitchhiker's Guide to the Galaxy 2nd season intro
More information about the gdal-dev
mailing list