[gdal-dev] ERDAS/Intergraph/Hexagon ECW/JP2 v4.3 compile in 1.11

Wilson Waters gdal-dev-list-mail at alintech.com.au
Sun May 4 19:04:42 PDT 2014


Hi all,

I think there might be a build bug in GDAL 1.11.0 with the ERDAS ECW/JP2 
v4.3 driver in read/write mode.

My problem was identical to this post from a year ago 
http://lists.osgeo.org/pipermail/gdal-dev/2013-June/036565.html

I get the following error
jp2userbox.cpp(133) : error C2664: 'NCS::JP2::CBox::UnParse' : cannot 
convert parameter 1 from 'NCS::SDK::CFileBase' to 'NCS::JP2::CFile &'

After some amount of digging through the ecw driver and SDK include 
files the only way I could get it to compile was changing the definition 
UnParse() in jp2userbox.cpp and gdal_ecw.h
CNCSError JP2UserBox::UnParse( NCS::SDK::CFileBase &JP2File,
                                NCS::CIOStream &Stream )
to
CNCSError JP2UserBox::UnParse( NCS::JP2::CFile &JP2File,
                                NCS::CIOStream &Stream )

It doesn't look like NCS::JP2::CFile isn't in the same inheritance tree 
as NCS::SDK::CFileBase? Although I must be missing something because I 
later found that undefining HAVE_COMPRESS in nmake.opt builds fine...

I'm not sure what other problems this will cause, but it seems to be 
working for us. I'm going to guess this change breaks build with ECW SDK 
v5 though so maybe it needs a few more #defines?

Cheers,
Wilson.


More information about the gdal-dev mailing list