Received: from [192.48.153.1] by phillip.thumbsplus.com (NTMail 3.03.0017/7.aaxh) with ESMTP id pcrews for <pcrews@cerious.com>; Fri, 24 Apr 1998 10:05:11 -0400
Received: from cthulhu.engr.sgi.com (cthulhu.engr.sgi.com [192.26.80.2]) by sgi.sgi.com (980309.SGI.8.8.8-aspam-6.2/980304.SGI-aspam) via ESMTP id GAA17881; Fri, 24 Apr 1998 06:50:35 -0700 (PDT)
	mail_from (owner-tiff@sgi.engr.sgi.com)
Received: (from majordomo-owner@localhost)
	by cthulhu.engr.sgi.com (980205.SGI.8.8.8/970903.SGI.AUTOCF)
	id FAA15999423
	for tiff-list;
	Fri, 24 Apr 1998 05:44:52 -0700 (PDT)
Received: from sgi.sgi.com (sgi.engr.sgi.com [192.26.80.37])
	by cthulhu.engr.sgi.com (980205.SGI.8.8.8/970903.SGI.AUTOCF)
	via ESMTP id FAA16021581
	for <tiff-relay@cthulhu.engr.sgi.com>;
	Fri, 24 Apr 1998 05:44:51 -0700 (PDT)
Received: from sierra.auriga.ru (sierra.auriga.ru [195.239.208.223]) by sgi.sgi.com (980309.SGI.8.8.8-aspam-6.2/980304.SGI-aspam) via ESMTP id FAA00446
	for <tiff@sgi.com>; Fri, 24 Apr 1998 05:41:58 -0700 (PDT)
	mail_from (tim@sierra.auriga.ru)
Received: from tim@localhost by sierra.auriga.ru id <290-18220>; Fri, 24 Apr 1998 15:01:40 +0400
From: tim@sierra.auriga.ru
To: sam@cthulhu.engr.sgi.com, tiff@sgi.com, tim@sierra.auriga.ru
Subject: Re: libtiff issues
Message-Id: <19980424110141Z290-18220+17@sierra.auriga.ru>
Date: 	Fri, 24 Apr 1998 15:01:40 +0400
Sender: owner-tiff@fddi-sgi.sgi.com
Precedence: bulk

>From:	"Sam Leffler" <sam@cthulhu.engr.sgi.com>
>Date:	Tue, 21 Apr 1998 10:42:46 -0700

>>- library fails to read a sample packed with method 32771
>>  Is it bug in the library or my fault?
>The codec works on all test images I've seen (obviously).
None of images in v3.4pisc.tar.gz use this compression method.
That's why I asked - if anybody read any sample compressed by method
32771 (printed as CCITT RLE/W by the library) ?

>  If you've got a
>problem you can either provide a sample image where there is a problem and
>wait for someone to look into why the image cannot be decoded or you can
>dive into the code yourself.  I'd suspect the image given the age and heavy
>testing the existing codecs have had.
I can easily modify the library to read my sample, but I'm not sure
if it break something other.  On the other hand one my sample is not
full substitute for specification.

By the way, could anybody give me a pointer to TIFF _4_ specs?

>>  library with ZIP support under MS Visual C/C++ 4.x
>>  (besides the fix I have some suggestion to improve the file)
>Post diffs or send them to me.  I'm far too busy to do anything right now
>but collect stuff but I _do_ look at everything I receive before I make new
>distributions (or at least I try to).
Straightforward fix is simple enough:

 *** tiffcomp.h	Tue Sep  2 21:54:20 1997
 --- /usr/iutl/ihub/libes/tiff/tiffcomp.h	Wed Apr 15 16:43:39 1998
 ***************
 *** 83,89 ****
   #include <stdlib.h>
   #define	BSDTYPES
   #define	HAVE_UNISTD_H	0
 ! #elif defined(_WINDOWS) || defined(__WIN32__) || defined(_Windows)
   #define	BSDTYPES
   #elif defined(OS2_16) || defined(OS2_32)
   #define	BSDTYPES
 --- 83,89 ----
   #include <stdlib.h>
   #define	BSDTYPES
   #define	HAVE_UNISTD_H	0
 ! #elif defined(_WINDOWS) || defined(__WIN32__) || defined(_Windows) || defined(_WIN32)
   #define	BSDTYPES
   #elif defined(OS2_16) || defined(OS2_32)
   #define	BSDTYPES

This solves problem for Windows but I'm afraid it's not enough since
#define HAVE_UNISTD_H 0
might conflict with "#ifdef HAVE_UNISTD_H" in zconf.h from zlib and
looks like the following fix will work better (I did not test it yet)

 *** tiffcomp.h	Tue Sep  2 21:54:20 1997
 --- tiffcomp.new	Fri Apr 24 14:37:13 1998
 ***************
 *** 82,89 ****
   #if defined(__MWERKS__) || defined(THINK_C) || defined(__PPCC__) || defined(__SC__) || defined(__MRC__)
   #include <stdlib.h>
   #define	BSDTYPES
 ! #define	HAVE_UNISTD_H	0
 ! #elif defined(_WINDOWS) || defined(__WIN32__) || defined(_Windows)
   #define	BSDTYPES
   #elif defined(OS2_16) || defined(OS2_32)
   #define	BSDTYPES
 --- 82,88 ----
   #if defined(__MWERKS__) || defined(THINK_C) || defined(__PPCC__) || defined(__SC__) || defined(__MRC__)
   #include <stdlib.h>
   #define	BSDTYPES
 ! #elif defined(_WINDOWS) || defined(__WIN32__) || defined(_Windows) || defined(_WIN32)
   #define	BSDTYPES
   #elif defined(OS2_16) || defined(OS2_32)
   #define	BSDTYPES
 ***************
 *** 90,99 ****
   #elif defined(__acornriscos)
   #include <stdlib.h>
   #define	BSDTYPES
 ! #define	HAVE_UNISTD_H	0
 ! #elif defined(VMS)
 ! #define	HAVE_UNISTD_H	0
 ! #else
   #define	HAVE_UNISTD_H	1
   #endif
   
 --- 89,95 ----
   #elif defined(__acornriscos)
   #include <stdlib.h>
   #define	BSDTYPES
 ! #elif !defined(VMS)
   #define	HAVE_UNISTD_H	1
   #endif
   
 ***************
 *** 103,110 ****
    * (except on system where they are in stdio.h and
    * there is no unistd.h).
    */
 ! #if !defined(SEEK_SET) && HAVE_UNISTD_H
 ! #include <unistd.h>
   #endif
   
   /*
 --- 99,112 ----
    * (except on system where they are in stdio.h and
    * there is no unistd.h).
    */
 ! #ifndef SEEK_SET
 ! # ifdef HAVE_UNISTD_H
 ! #  include <unistd.h>
 ! # else
 ! #  define SEEK_SET 0
 ! #  define SEEK_CUR 1
 ! #  define SEEK_END 2
 ! # endif
   #endif
  
>>- config script fails to find proper inline definition under
>>  DEC UNIX 4.0
>Please send/post a fix.
Unfortunately I'm not familiar enough with this tool to make a fix,
I can just point out that configure script from IJG JPEG library is
able to find proper definition.

Regards,
				Tim
