~ubuntu-branches/ubuntu/dapper/tiff/dapper-updates

« back to all changes in this revision

Viewing changes to contrib/win32/README

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2005-11-09 18:21:15 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20051109182115-v0fd3zcbrq2sq6u4
Tags: 3.7.4-1ubuntu1
* Synchronize to Debian.
* Only change left: xlibmesa-gl-dev -> libgl1-mesa-dev build dependency
  change.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
This mail from Scott describes changes to the library that I have
2
 
not made because I couldn't figure out exactly where they went.
3
 
Anything not in this file has either been placed in the appropriate
4
 
directory (e.g. libtiff/tif_win32.c) or applied to the current
5
 
source code (e.g. libtiff/tiffiop.h).
6
 
 
7
 
Note that the Window NT/Window 95 support is untested; Scott's work
8
 
was done with an earlier version of the library.  Hopefully this'll
9
 
get cleaned up soon.
10
 
 
11
 
        Sam
12
 
 
13
 
Date: Fri, 14 Apr 95 17:01:42 EDT
14
 
From: wagner@itek.com (scott wagner)
15
 
Message-Id: <9504142101.AA00764@cyan.>
16
 
To: sam@cthulhu.engr.sgi.com
17
 
Subject: Re: Libtiff for Win32 (Windows NT / Windows 95)
18
 
 
19
 
Hi, Sam!
20
 
 
21
 
Enclosed are my libtiff for win32 pieces.  They are in the form of 3 files
22
 
(tif_w32.c, dllshell.c, and libtiff.def), and 2 diffs (for tiffiop.h and 
23
 
tiffio.h).
24
 
 
25
 
Hope this is not too difficult to separate!
26
 
 
27
 
Regards,
28
 
Scott Wagner (wagner@itek.com)
29
 
 
30
 
tif_w32.c  ---------------------------------------------------------------
31
 
 
32
 
tiffiop.h  ---------------------------------------------------------------
33
 
 
34
 
tiffio.h  ---------------------------------------------------------------
35
 
38a39
36
 
> #ifdef _TIFFIOP_
37
 
39a41,43
38
 
> #else
39
 
> typedef void TIFF;    /* Avoid ANSI undefined structure warning */
40
 
> #endif
41
 
66a71,75
42
 
> #ifdef WIN32                  /* WIN32 identifies Win32 compiles */
43
 
> #pragma warn -sig             /* Turn off Borland warn of long to short int convert */
44
 
> #pragma warn -par             /* Turn off Borland warn "Parameter x is never used" */
45
 
> DECLARE_HANDLE(thandle_t);            /* Win32 file handle */
46
 
> #else                                         /* if not WIN32_ */
47
 
67a77
48
 
> #endif                                        /* defined WIN32 */
49
 
 
50
 
(Message tiff:1396)
51
 
 -- using template mhl.format --
52
 
Date:    Mon, 17 Apr 1995 07:51:03 EDT
53
 
To:      sam@cthulhu.engr.sgi.com
54
 
 
55
 
From:    wagner@itek.com (scott wagner)
56
 
Subject: Libtiff for Win32
57
 
 
58
 
Return-Path: sam@flake.asd.sgi.com 
59
 
Delivery-Date: Mon, 17 Apr 1995 05:36:50 PDT
60
 
Return-Path: sam@flake.asd.sgi.com
61
 
 
62
 
Hello, Sam!
63
 
 
64
 
>   ... libtiff for win32 pieces.  They are in the form of 3 files
65
 
>   (tif_w32.c, dllshell.c, and libtiff.def), and 2 diffs (for tiffiop.h and 
66
 
>   tiffio.h).
67
 
>   
68
 
> I don't understand how these pieces fit together.  Can you please explain
69
 
> what dllshell.c and libtiff.def are for? 
70
 
 
71
 
Sorry I was short on documentation here ... I was rushing to get home to
72
 
dinner on Friday and the material for you was the last loose end I had to
73
 
deal with.  Excuses aside ...
74
 
 
75
 
The goal of the adaptation of libtiff to Win32 was to replace only one
76
 
environment-specific code module and to make minimal changes to header
77
 
files.  tif_win32.c required one addition to tiffio.h (the
78
 
DECLARE_HANDLE line, which is probably a better way to typedef thandle-t
79
 
under Windows 3.1 as well); it also required the addition of pv_map_handle
80
 
to the tiff structure and the conditional definition of the
81
 
TIFFUnmapFileContents macro in tiffiop.h (this because Win32 uses a handle
82
 
and a pointer in mapping memory, and I needed to save both).
83
 
 
84
 
Additionally, I made a general style change to tiffio.h.  If tiffio.h is
85
 
included by a client, which does not include tiffiop.h, then ANSI compilers
86
 
warn about the typedef of TIFF to a non-existent structure.  To avoid this,
87
 
I changed the typedef of TIFF in this case to void.
88
 
 
89
 
I also made a style change in the tiff structure.  All references to tif_fd
90
 
in the library treat it as int, yet the tif_fd member itself is short.  I
91
 
changed this member to int and added the reserved member to maintain
92
 
32-bit structure member alignment in a 32 bit environment.  [ At cost of
93
 
4 more bytes in an already bloated structure! :-) ]  As long as fd's are
94
 
less than 64k, the old member works; this is not the case in Win32, and is
95
 
not generally a safe assumption.
96
 
 
97
 
The module dllshell.c and the file libtiff.def are not specific to the 
98
 
functionality of libtiff; they are used to make a Win32 dynamic link
99
 
library, and would be best packaged with a Win32 makefile, which I have
100
 
not yet perfected.  I will, however, commit to a Borland and Microsoft C
101
 
makefile for libtiff; perhaps these two could be combined with the
102
 
makefile for the _next_ (!) release of libtiff when it is ready.
103
 
 
104
 
Once again, sorry for the confused message on Friday.  I hope that at
105
 
least tif_w32 and the tiffio.h and tiffiop.h diffs will be useful for
106
 
this release.
107
 
 
108
 
Regards,
109
 
Scott Wagner   (wagner@itek.com)
110
 
Itek Graphix
111
 
Rochester, NY