2005.09.05 16:04 "[Tiff] problem using 64-bit libtiff.so on Solaris 8 using GCC", by Dan Smith

2005.09.08 20:39 "Re: [Tiff] problem using 64-bit libtiff.so on Solaris 8 using GCC", by Dan Smith

I figured out what the problem is, but where blame lies I have no idea:

The #if defined(...) in tiff.h (v3.5.7) has checks for __LP64__, which, according to GCC v3.3 manual, is what they define for 64-bit.

A quick test program shows they do NOT define __LP64__, but rather __LP64. GCC v3.4.2 DOES define __LP64__ as the manual indicates.

After supplying the command line argument -D__LP64__, libtiff works fine.

I will let the creators argue whether libtiff should have had __LP64 listed or GCC should have defined what they advertised.

Thanks
Dan

I am using gcc v3.3.3, Solaris 8 & libtiff v3.5.7. I realize 3.7.3 is the latest, but upgrading to the latest libraries a few weeks before a release is not advisable unless absolutely necessary. Besides, I can't beleive I am the only one to try libtiff in 64-bit mode on GNU.

I use libtiff 3.7.3 compiled as 64-bits under Solaris 9 using GCC 4.0.1. There are some warnings during compilation, but the library seems to work correctly anyway.

I don't recommend that anyone use libtiff v3.5.7 if they have the option to use 3.7.3 since 3.7.3 is more portable, more modern, and fixes many bugs.