version: 3.3
source: libecwj2-3.3-2006-09-06.zip or http://ermapper.com
The patches below are for the v3.3-2006-09-06 source (local download available above). There may also be copies in various linux distros. Later "updates" only changed the "open source" license to be more and more restrictive, the source is essentially the same. The latest source is still available at ER Mapper, though it's now owned by Leica.
| Feature | ppc | i386 | ppc64 | x86_64 |
|---|---|---|---|---|
| ECW Read | √ | √ | ? | √ |
| ECW Write | x | x | x | x |
| JP2 Read | √ | √ | ? | √ |
| JP2 Write | √ | √ | ? | √ |
Note: I don't have access to a PPC Leopard Mac to be able to test PPC 64bit, but I assume that if Intel 64bit works, then PPC 64bit does.
Download this patch and place it in the libecwj2 source folder.
In the ECW source folder folder:
patch -p1 -i libecwj2-3.3.patch
In a different version of the source there may be errors. You'll just have to look at the patch and try to figure out how to apply it manually.
These patches take care of some OSX issues that ER Mapper didn't or couldn't fix, and other random issues that may or may not be important:
ECW makes use of Carbon for the password dialog. Since Carbon is not available for OSX 64bit, I disabled it completely, there is no way to access password protected ECW resources (or something like that).
In the ECW source top level (not "Source"):
export MACOSX_DEPLOYMENT_TARGET=10.5 ./configure --disable-dependency-tracking \ CFLAGS="-Os -arch ppc -arch i386 -arch ppc64 -arch x86_64" \ CXXFLAGS="-Os -arch ppc -arch i386 -arch ppc64 -arch x86_64" \ CPPFLAGS=-I/Library/Frameworks/UnixImageIO.framework/unix/include \ LDFLAGS=-L/Library/Frameworks/UnixImageIO.framework/unix/lib make sudo make install
In the ECW source top level (not "Source"):
export MACOSX_DEPLOYMENT_TARGET=10.4 ./configure --disable-dependency-tracking \ CFLAGS="-Os -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk" \ CXXFLAGS="-Os -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk" \ CPPFLAGS=-I/Library/Frameworks/UnixImageIO.framework/unix/include \ LDFLAGS=-L/Library/Frameworks/UnixImageIO.framework/unix/lib make sudo make install
In the ECW source top level (not "Source"):
./configure --disable-dependency-tracking CFLAGS=-Os CXXFLAGS=-Os \ CPPFLAGS=-I/Library/Frameworks/UnixImageIO.framework/unix/include \ LDFLAGS=-L/Library/Frameworks/UnixImageIO.framework/unix/lib make sudo make install