= JasPer = The !JasPer library can be used for JPEG2000 access in GDAL. * http://www.gdal.org/frmt_jpeg2000.html = Building with !JasPer = JPEG2000 support based on !JasPer toolkit which can be accessed from the [http://www.ece.uvic.ca/~mdadams/jasper/ JasPer Project Home Page]. JasPer itself is a bridge for working with several image file formats. Only JP2 and JPC parts of !JasPer used in GDAL. You need modified !JasPer library to build this driver with GeoJP2 support enabled. Modified version can be downloaded from ftp://ftp.remotesensing.org/gdal/jasper-1.900.1.uuid.tar.gz. On 64bit linux systems it may be necessary to force use of -fPIC when building JasPer or else it can't be used in the GDAL shared library. {{{ export CFLAGS="-O2 -fPIC" ./configure }}} == Troubleshooting == If may encounter following error during linking, especially when building GDAL on Mac OS X: {{{ ld: common symbols not allowed with MH_DYLIB output format with the -multi_module option /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_magctxnolut (size 16384) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_mqctxs (size 160) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_refnmsedec (size 512) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_refnmsedec0 (size 512) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_scctxnolut (size 1024) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_signmsedec (size 512) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_signmsedec0 (size 512) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_spblut (size 1024) /usr/local/lib/libjasper.a(jpc_t1cod.o) definition of common _jpc_zcctxnolut (size 4096) /usr/bin/libtool: internal link edit command failed make[1]: *** [/Users/mloskot/dev/gdal/_svn/trunk/gdal/libgdal.dylib] Error 1 make: *** [check-lib] Error 2 }}} In order to fix it, it's required to rebuild JasPer with additional compilation option: {{{ $ export CFLAGS="-fno-common" $ export CXXFLAGS=$CFLAGS $ ./configure make clean make make install }}} After new build of JasPer is installed, GDAL should compile and link with success. = Known issues = You might encounter crashes when using the Jasper JPEG2000 driver with some particular versions of libjasper packaged by Debian (or Debian-based distribution). See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=553429. Debian jasper 1.900.1-6 was known to be buggy, but 1.900.1-6-1 is fixed now. At the time of writing, Ubuntu 9.10 using jasper 1.900.1-6 is affected (see https://bugs.launchpad.net/ubuntu/+source/jasper/+bug/505173). Ubuntu 10.04 (dev) using 1.900.1-6-1 should be unaffected. = Open Tickets = [[TicketQuery(status=new|assigned|reopened&keywords~=jasper&order=priority)]]