From e02edb7044253c49f0a866ff469ae7f3097dc129 Mon Sep 17 00:00:00 2001 From: Mike Welles Date: Wed, 3 Feb 1999 19:53:27 +0000 Subject: v3.4beta037iptc release --- .#README-ITPC | 1 + Makefile | 505 ++++ README-IPTC | 41 + config.log | 7164 +++++++++++++++++++++++++++++++++++++++++++++++++ libtiff/Makefile | 342 +++ libtiff/mkversion.c | 0 libtiff/port.h | 32 + libtiff/tif_acorn.c | 0 libtiff/tif_dir.c | 37 + libtiff/tif_dir.h | 14 +- libtiff/tif_dirinfo.c | 15 + libtiff/tif_print.c | 10 + libtiff/tiff.h | 4 + libtiff/tiffconf.h | 4 + man/Makefile | 398 +++ port/install.sh | 246 ++ tiff.h | 421 +++ tools/Makefile | 251 ++ 18 files changed, 9483 insertions(+), 2 deletions(-) create mode 120000 .#README-ITPC create mode 100644 Makefile create mode 100644 README-IPTC create mode 100644 config.log create mode 100644 libtiff/Makefile mode change 100755 => 100644 libtiff/mkversion.c create mode 100644 libtiff/port.h mode change 100755 => 100644 libtiff/tif_acorn.c create mode 100644 man/Makefile create mode 100644 port/install.sh create mode 100644 tiff.h create mode 100644 tools/Makefile diff --git a/.#README-ITPC b/.#README-ITPC new file mode 120000 index 00000000..9440129f --- /dev/null +++ b/.#README-ITPC @@ -0,0 +1 @@ +mike@kurtz.fake.716:931250841 \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..891a2358 --- /dev/null +++ b/Makefile @@ -0,0 +1,505 @@ +#! smake +# $Header: /d1/sam/tiff/RCS/Makefile.in,v 1.62 1997/08/29 23:24:06 sam Exp $ +# +# Warning, this file was automatically created by the TIFF configure script +# +# Tag Image File Format Library +# +# Copyright (c) 1988-1997 Sam Leffler +# Copyright (c) 1991-1997 Silicon Graphics, Inc. +# +# Permission to use, copy, modify, distribute, and sell this software and +# its documentation for any purpose is hereby granted without fee, provided +# that (i) the above copyright notices and this permission notice appear in +# all copies of the software and related documentation, and (ii) the names of +# Sam Leffler and Silicon Graphics may not be used in any advertising or +# publicity relating to the software without the specific, prior written +# permission of Sam Leffler and Silicon Graphics. +# +# THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, +# EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY +# WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. +# +# IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR +# ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, +# OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +# WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF +# LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE +# OF THIS SOFTWARE. +# + +SRCDIR = . + +# +# VERSION: v3.4beta037 +# DATE: Wed Feb 3 19:53:27 EST 1999 +# TARGET: i586-unknown-linux +# CCOMPILER: /usr/bin/gcc +# + +SHELL = /bin/sh +NULL = +ECHO = echo +GENDIST = ${TOOLROOT}/usr/sbin/gendist +INSTALL = ${SHELL} ../port/install.sh + +all default: + @if [ "no" = yes ]; then \ + ${ECHO} "= "port; cd port; ${MAKE}; \ + else \ + true; \ + fi + @${ECHO} "= "libtiff; cd libtiff; ${MAKE} + @${ECHO} "= "tools; cd tools; ${MAKE} + @${ECHO} "= "man; cd man; ${MAKE} + +install: + @${ECHO} "= "libtiff; cd libtiff; ${MAKE} install + @${ECHO} "= "tools; cd tools; ${MAKE} install + @${ECHO} "= "man; cd man; ${MAKE} install + @if [ "no" = yes ]; then \ + ${ECHO} "= "html; cd html; ${MAKE} install; \ + else \ + true; \ + fi + +clean: + @if [ "no" = yes ]; then \ + ${ECHO} "= "port; cd port; ${MAKE} clean; \ + else \ + true; \ + fi + @${ECHO} "= "libtiff; cd libtiff; ${MAKE} clean + @${ECHO} "= "tools; cd tools; ${MAKE} clean + @${ECHO} "= "man; cd man; ${MAKE} clean +# -cd contrib/dbs; ${MAKE} clean +# -cd contrib/dbs/xtiff; ${MAKE} clean + +clobber distclean: clean + rm -f Makefile libtiff/port.h config.log + rm -f libtiff/Makefile + rm -f tools/Makefile + rm -f man/Makefile + rm -f port/Makefile port/install.sh + rm -f html/Makefile + +# +# The folllowing rule creates a binary distribution for IRIX. +# +installLink:: + if [ /usr/local/lib != /usr/lib ]; then \ + ${INSTALL} -idb tiff.sw.tools -F /usr/lib \ + -lns /usr/local/lib/libtiff.a -O libtiff.a; \ + else \ + true; \ + fi +product:: + test -d dist || mkdir dist + rm -f dist/rawidb + SRC=`pwd` RAWIDB=`pwd`/dist/rawidb ${MAKE} install installLink + rm -f dist/idb + sort -u +4 dist/rawidb > dist/idb + ${GENDIST} -v -dist dist -idb dist/idb \ + -sbase `pwd` -spec ${SRCDIR}/dist/tiff.spec + +# +# These rules are used to create the source distribution images +# + +HOST = sgi +COMPRESS= gzip +ZIPSUF = gz + +TIFFFILES=\ + configure \ + config.guess \ + config.sub \ + config.site \ + Makefile.in \ + README \ + VERSION \ + COPYRIGHT \ + TODO \ + dist/tiff.spec \ + dist/newalpha \ + dist/newversion \ + libtiff/Makefile.in \ + libtiff/Makefile.lcc \ + libtiff/t4.h \ + libtiff/tiff.h \ + libtiff/tiffcomp.h \ + libtiff/tiffconf.h \ + libtiff/tiffio.h \ + libtiff/tiffiop.h \ + libtiff/uvcode.h \ + libtiff/mkg3states.c \ + libtiff/mkspans.c \ + libtiff/mkversion.c \ + libtiff/tif_acorn.c \ + libtiff/tif_apple.c \ + libtiff/tif_atari.c \ + libtiff/tif_aux.c \ + libtiff/tif_close.c \ + libtiff/tif_codec.c \ + libtiff/tif_compress.c \ + libtiff/tif_dir.h \ + libtiff/tif_dir.c \ + libtiff/tif_dirinfo.c \ + libtiff/tif_dirread.c \ + libtiff/tif_dirwrite.c \ + libtiff/tif_dumpmode.c \ + libtiff/tif_error.c \ + libtiff/tif_fax3.c \ + libtiff/tif_fax3.h \ + libtiff/tif_flush.c \ + libtiff/tif_getimage.c \ + libtiff/tif_jpeg.c \ + libtiff/tif_luv.c \ + libtiff/tif_lzw.c \ + libtiff/tif_msdos.c \ + libtiff/tif_next.c \ + libtiff/tif_open.c \ + libtiff/tif_packbits.c \ + libtiff/tif_pixarlog.c \ + libtiff/tif_predict.h \ + libtiff/tif_predict.c \ + libtiff/tif_print.c \ + libtiff/tif_read.c \ + libtiff/tif_strip.c \ + libtiff/tif_swab.c \ + libtiff/tif_thunder.c \ + libtiff/tif_tile.c \ + libtiff/tif_unix.c \ + libtiff/tif_version.c \ + libtiff/tif_vms.c \ + libtiff/tif_warning.c \ + libtiff/tif_win3.c \ + libtiff/tif_win32.c \ + libtiff/tif_write.c \ + libtiff/tif_zip.c \ + port/Makefile.in \ + port/getopt.c \ + port/install.sh.in \ + port/irix/so_locations \ + port/strcasecmp.c \ + port/strtoul.c \ + tools/Makefile.in \ + tools/Makefile.lcc \ + tools/fax2tiff.c \ + tools/fax2ps.c \ + tools/gif2tiff.c \ + tools/pal2rgb.c \ + tools/ppm2tiff.c \ + tools/ras2tiff.c \ + tools/rasterfile.h \ + tools/rgb2ycbcr.c \ + tools/sgi2tiff.c \ + tools/sgigt.c \ + tools/sgisv.c \ + tools/thumbnail.c \ + tools/tiff2bw.c \ + tools/tiff2ps.c \ + tools/tiffcmp.c \ + tools/tiffcp.c \ + tools/tiffdither.c \ + tools/tiffdump.c \ + tools/tiffinfo.c \ + tools/tiffmedian.c \ + tools/tiffsplit.c \ + tools/ycbcr.c \ + man/Makefile.in \ + man/fax2tiff.1 \ + man/fax2ps.1 \ + man/gif2tiff.1 \ + man/pal2rgb.1 \ + man/ppm2tiff.1 \ + man/ras2tiff.1 \ + man/rgb2ycbcr.1 \ + man/sgi2tiff.1 \ + man/thumbnail.1 \ + man/tiff2bw.1 \ + man/tiff2ps.1 \ + man/tiffcmp.1 \ + man/tiffcp.1 \ + man/tiffdither.1 \ + man/tiffdump.1 \ + man/tiffgt.1 \ + man/tiffinfo.1 \ + man/tiffmedian.1 \ + man/tiffsplit.1 \ + man/tiffsv.1 \ + man/TIFFClose.3t \ + man/TIFFError.3t \ + man/TIFFFlush.3t \ + man/TIFFGetField.3t \ + man/TIFFOpen.3t \ + man/TIFFPrintDirectory.3t \ + man/TIFFReadDirectory.3t \ + man/TIFFReadEncodedStrip.3t \ + man/TIFFReadEncodedTile.3t \ + man/TIFFReadRGBAImage.3t \ + man/TIFFReadRawStrip.3t \ + man/TIFFReadRawTile.3t \ + man/TIFFReadScanline.3t \ + man/TIFFReadTile.3t \ + man/TIFFRGBAImage.3t \ + man/TIFFSetDirectory.3t \ + man/TIFFSetField.3t \ + man/TIFFWarning.3t \ + man/TIFFWriteDirectory.3t \ + man/TIFFWriteEncodedStrip.3t \ + man/TIFFWriteEncodedTile.3t \ + man/TIFFWriteRawStrip.3t \ + man/TIFFWriteRawTile.3t \ + man/TIFFWriteScanline.3t \ + man/libtiff.3t \ + man/TIFFbuffer.3t \ + man/TIFFcodec.3t \ + man/TIFFmemory.3t \ + man/TIFFquery.3t \ + man/TIFFsize.3t \ + man/TIFFstrip.3t \ + man/TIFFswab.3t \ + man/TIFFtile.3t \ + html/Makefile.in \ + html/bugs.html \ + html/build.html \ + html/contrib.html \ + html/document.html \ + html/images.html \ + html/index.html \ + html/internals.html \ + html/intro.html \ + html/libtiff.html \ + html/misc.html \ + html/support.html \ + html/tools.html \ + html/v3.4beta036.html \ + html/v3.4beta035.html \ + html/v3.4beta034.html \ + html/v3.4beta033.html \ + html/v3.4beta032.html \ + html/v3.4beta031.html \ + html/v3.4beta029.html \ + html/v3.4beta028.html \ + html/v3.4beta024.html \ + html/v3.4beta018.html \ + html/v3.4beta016.html \ + html/v3.4beta007.html \ + ${NULL} +OTHERFILES=\ + html/images/back.gif \ + html/images/bali.jpg \ + html/images/cat.gif \ + html/images/cover.jpg \ + html/images/cramps.gif \ + html/images/dave.gif \ + html/images/info.gif \ + html/images/jello.jpg \ + html/images/jim.gif \ + html/images/note.gif \ + html/images/oxford.gif \ + html/images/quad.jpg \ + html/images/ring.gif \ + html/images/smallliz.jpg \ + html/images/strike.gif \ + html/images/warning.gif \ + ${NULL} +CONTRIBFILES=\ + contrib/dbs/README \ + contrib/dbs/Imakefile \ + contrib/dbs/tiff-bi.c \ + contrib/dbs/tiff-grayscale.c \ + contrib/dbs/tiff-palette.c \ + contrib/dbs/tiff-rgb.c \ + contrib/dbs/xtiff/README \ + contrib/dbs/xtiff/Imakefile \ + contrib/dbs/xtiff/patchlevel.h \ + contrib/dbs/xtiff/xtiff.c \ + contrib/dbs/xtiff/xtifficon.h \ + contrib/ras/README \ + contrib/ras/ras2tif.c \ + contrib/ras/tif2ras.c \ + contrib/vms/libtiff/makevms.com \ + contrib/vms/libtiff/tiff.opt \ + contrib/vms/libtiff/tiffshraxp.opt \ + contrib/vms/libtiff/tiffshrvax.opt \ + contrib/vms/libtiff/tiffvec.mar \ + contrib/vms/tools/makevms.com \ + contrib/tags/README \ + contrib/tags/Makefile.gcc \ + contrib/tags/Makefile.mpw \ + contrib/tags/listtif.c \ + contrib/tags/maketif.c \ + contrib/tags/xtif_dir.c \ + contrib/tags/xtiffio.h \ + contrib/tags/xtiffiop.h \ + contrib/mac-mpw/README \ + contrib/mac-mpw/BUILD.mpw \ + contrib/mac-mpw/libtiff.make \ + contrib/mac-mpw/mactrans.c \ + contrib/mac-mpw/port.make \ + contrib/mac-mpw/tools.make \ + contrib/mac-mpw/top.make \ + contrib/acorn/ReadMe \ + contrib/acorn/Makefile \ + contrib/acorn/SetVars \ + contrib/acorn/cleanlib \ + contrib/acorn/convert \ + contrib/acorn/install \ + contrib/win32/README \ + contrib/win32/dllshell.c \ + contrib/win32/libtiff.def \ + contrib/win95/README \ + contrib/win95/Makefile.w95 \ + contrib/win95/tiff2dib.c \ + contrib/winnt/README \ + contrib/winnt/README.console \ + contrib/winnt/fax3sm.c \ + contrib/winnt/libtiff.def \ + contrib/winnt/libtiff.mak \ + contrib/winnt/libtiff.vcp \ + contrib/winnt/version.h \ + contrib/mac-cw/README \ + contrib/mac-cw/Makefile.script \ + contrib/mac-cw/mac_main.c \ + contrib/mac-cw/mac_main.h \ + contrib/mac-cw/metrowerks.note \ + contrib/mac-cw/mkg3_main.c \ + contrib/mac-cw/version.h \ + contrib/dosdjgpp/README \ + contrib/dosdjgpp/Makefile.lib \ + contrib/dosdjgpp/Makefile.tools \ + contrib/dosdjgpp/Makefile.top \ + contrib/dosdjgpp/conf.bat \ + contrib/dosdjgpp/port.h \ + contrib/mfs/README \ + contrib/mfs/mfs_file.c \ + contrib/pds/README \ + contrib/pds/tif_imageiter.c \ + contrib/pds/tif_imageiter.h \ + contrib/pds/tif_pdsdirread.c \ + contrib/pds/tif_pdsdirwrite.c \ + ${NULL} +DISTFILES=\ + ${TIFFFILES} \ + dist/tiff.alpha \ + dist/tiff.version \ + ${OTHERFILES} \ + ${CONTRIBFILES} \ + ${NULL} + +CONFIG=\ + -with-CC=cc \ + -with-GCOPTS=" " \ + -with-JPEG=yes \ + -with-DIR_JPEG=../src/jpeg-5a \ + -with-ZIP=yes \ + -with-DIR_LIBGZ=../src/zlib \ + ${NULL} + +rcsclean: + rcsclean ${TIFFFILES} && co ${TIFFFILES} + +alpha: + (cd ${SRCDIR}/dist; sh newversion) + -${MAKE} clean + ${MAKE} alpha.stamp + ${SRCDIR}/configure ${CONFIG} + ${MAKE} product + ${MAKE} alpha.tar + +# stamp relevant files according to current alpha +alpha.stamp: + VERSION="Alpha037"; \ + NOW=`date`; \ + for i in ${TIFFFILES}; do \ + REV=`rlog -h -d"$$NOW" ${SRCDIR}/$$i|fgrep 'head:'|awk '{print $$2}'`;\ + rcs "-N$$VERSION:$$REV" "-sExp:$$REV" ${SRCDIR}/$$i && co -sExp ${SRCDIR}/$$i; \ + done + +purge-old-alphas: + VERSIONS=`awk 'BEGIN { \ + for (i=1; i<=037; i++) printf " -nAlpha%03d",i;\ + exit \ + }'`; \ + for i in ${TIFFFILES}; do \ + echo rcs $$VERSIONS ${SRCDIR}/$$i; \ + rcs $$VERSIONS ${SRCDIR}/$$i && co ${SRCDIR}/$$i; \ + done + +alphadiff: + -@for i in ${TIFFFILES}; do \ + rcsdiff -r${ALPHA} ${SRCDIR}/$$i; \ + done + +# create alpha distribution archive +alpha.tar: + VERSION="v3.4beta037"; \ + rm -f tiff-$$VERSION $$VERSION $$VERSION-tar; \ + ln -s ${SRCDIR} tiff-$$VERSION; \ + (for i in ${DISTFILES}; do \ + echo $$i; \ + done) | sed "s;.*;tiff-$$VERSION/&;" >$$VERSION; \ + tar cvf $$VERSION-tar `cat $$VERSION`; \ + rm -f tiff-$$VERSION-tar.${ZIPSUF}; \ + cat $$VERSION-tar | ${COMPRESS} >tiff-$$VERSION-tar.${ZIPSUF}; \ + rm -f tiff-$$VERSION $$VERSION $$VERSION-tar; + +release: + (cd ${SRCDIR}/dist; sh newversion) + -${MAKE} clean + ${MAKE} release.stamp + ${SRCDIR}/configure ${CONFIG} + ${MAKE} product + ${MAKE} release.tar + +release.stamp: + NOW=`date`; \ + for i in ${TIFFFILES}; do \ + REV=`rlog -h -d"$$NOW" ${SRCDIR}/$$i|fgrep 'head:'|awk '{print $$2}'`;\ + rcs "-NRelease3_4_beta:$$REV" "-sRel:$$REV" ${SRCDIR}/$$i && co -sRel ${SRCDIR}/$$i; \ + done + +# create release distribution archive +release.tar: + VERSION="v3.4beta037"; \ + rm -f tiff-$$VERSION $$VERSION $$VERSION-tar; \ + ln -s ${SRCDIR} tiff-$$VERSION; \ + (for i in ${DISTFILES}; do \ + echo $$i; \ + done) | sed "s;.*;tiff-$$VERSION/&;" >$$VERSION; \ + tar cvf $$VERSION-tar `cat $$VERSION`; \ + rm -f tiff-$$VERSION-tar.${ZIPSUF}; \ + cat $$VERSION-tar | ${COMPRESS} >tiff-$$VERSION-tar.${ZIPSUF}; \ + rm -f tiff-$$VERSION $$VERSION $$VERSION-tar; + +# +# Create a package of the test images. +# + +PICS=\ + pics/README \ + pics/cramps.tif \ + pics/cramps-tile.tif \ + pics/fax2d.tif \ + pics/g3test.tif \ + pics/jello.tif \ + pics/jim___cg.tif \ + pics/jim___dg.tif \ + pics/jim___gg.tif \ + pics/jim___ah.tif \ + pics/strike.tif \ + pics/oxford.tif \ + pics/quad-lzw.tif \ + pics/quad-tile.tif \ + pics/text.tif \ + pics/ycbcr-cat.tif \ + pics/smallliz.tif \ + pics/zackthecat.tif \ + pics/fax2d.g3 \ + pics/g3test.g3 \ + ${NULL} + +pics.tar: + tar cvf - ${PICS} | ${COMPRESS} > tiffpics.tar.${ZIPSUF} diff --git a/README-IPTC b/README-IPTC new file mode 100644 index 00000000..c70f5ff5 --- /dev/null +++ b/README-IPTC @@ -0,0 +1,41 @@ +To: sam@engr.sgi.com +cc: adam@onshore.com +cc: billr@corbis.com +cc: magick@wizards.dupont.com +Subject: libtiff fork +X-Mailer: VM 6.63 under Emacs 20.3.2 +--text follows this line-- + +I've finished merging a forked libtiff that was being shipped with +ImageMagick (that added IPTC newsphoto support) with the last libtiff +release (tiff-v3.4beta037). I'm going to make this available at +ftp://ftp.onshore.com/pub/libtiff (as tiff-v3.4beta037-IPTC). + +I'm very reluctant to fork code, and I woud refrain, but for the following: + + 1. Repeated mail to you about the patches has gone unanswered. + + 2. I keep getting mail from people strugging to get IPTC newphoto support + to work properly with ImageMagick. + + 3. The NT source distibution was already shipping with a forked version. + +In order for the situation to be less confusing, I'm going to make an +archive of the forked version available. + +I very much would like for there not to be a fork. Are you still +maintaining libtiff? If not, is there a current maintainer? + +I'm willing to adopt it if there isn't. I'd hate to see such an +important library fragment. It's extremely likely that onShore +(http://onshore.com/), will donate web space, bandwidth, and listserv +services if so. + + + +------------------------------------------------------ +M. L. Welles mike@onShore.com + http://fifth.net/ +------------------------------------------------------- + + diff --git a/config.log b/config.log new file mode 100644 index 00000000..c77a759d --- /dev/null +++ b/config.log @@ -0,0 +1,7164 @@ +Wed Feb 3 19:53:27 EST 1999 +Running configure with arguments: + +This file contains information that is captured from running the configure +script. Lines that begin with a "+" are command lines echoed by the +shell. Other lines are the output of commands; usually the contents of +test case files or the output from compilers. If configure does the +wrong thing, you can use the information captured here to aid in debugging. + +++ . ./config.site +++ cat dummy.c +main(int argc, char* argv) { exit(0); } +++ cat xgnu.c +#ifdef __GNUC__ +yes; +#endif +++ gcc -E xgnu.c +++ egrep yes +yes; +++ gcc -o dummy dummy.c +++ /usr/bin/gcc -g -c dummy.c +++ make -f confMakefile t +/usr/bin/gcc -E t.c +# 1 "t.c" +# 1 "/usr/include/sys/types.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 117 "/usr/include/features.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/sys/cdefs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + +# 222 "/usr/include/features.h" 3 + +# 22 "/usr/include/sys/cdefs.h" 2 3 + + + + + + + + + + +# 54 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + +# 86 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + + + + + + + +# 205 "/usr/include/features.h" 2 3 + + + + + + + + + + + + + + +# 1 "/usr/include/gnu/stubs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 219 "/usr/include/features.h" 2 3 + + + + +# 26 "/usr/include/sys/types.h" 2 3 + + + + +# 1 "/usr/include/gnu/types.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned char __u_char; +typedef unsigned short __u_short; +typedef unsigned int __u_int; +typedef unsigned long __u_long; + +typedef unsigned long long int __u_quad_t; +typedef long long int __quad_t; +# 41 "/usr/include/gnu/types.h" 3 + +typedef __quad_t *__qaddr_t; + +typedef __u_quad_t __dev_t; +typedef __u_int __uid_t; +typedef __u_int __gid_t; +typedef __u_long __ino_t; +typedef __u_int __mode_t; +typedef __u_int __nlink_t; +typedef long int __off_t; +typedef __quad_t __loff_t; +typedef int __pid_t; +typedef int __ssize_t; + +typedef struct + { + int __val[2]; + } __fsid_t; + + +typedef int __daddr_t; +typedef char *__caddr_t; +typedef long int __time_t; +typedef long int __swblk_t; + +typedef long int __clock_t; + + +typedef unsigned long int __fd_mask; + + + + + + + + + + +typedef struct + { + + __fd_mask fds_bits[1024 / (8 * sizeof (__fd_mask)) ]; + } __fd_set; + + +typedef int __key_t; + +typedef unsigned short int __ipc_pid_t; + + +# 30 "/usr/include/sys/types.h" 2 3 + + + +typedef __u_char u_char; +typedef __u_short u_short; +typedef __u_int u_int; +typedef __u_long u_long; +typedef __quad_t quad_t; +typedef __u_quad_t u_quad_t; +typedef __fsid_t fsid_t; + + +typedef __dev_t dev_t; +typedef __gid_t gid_t; +typedef __ino_t ino_t; +typedef __mode_t mode_t; +typedef __nlink_t nlink_t; +typedef __off_t off_t; +typedef __loff_t loff_t; +typedef __pid_t pid_t; +typedef __uid_t uid_t; + + +typedef __ssize_t ssize_t; + + + + +typedef __daddr_t daddr_t; +typedef __caddr_t caddr_t; + + + +typedef __key_t key_t; + + + +# 1 "/usr/include/time.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 56 "/usr/include/time.h" 3 + + + +# 68 "/usr/include/time.h" 3 + + + + + + + + + + +typedef __time_t time_t; + + + + + +# 97 "/usr/include/time.h" 3 + + + + + +# 125 "/usr/include/time.h" 3 + + + +# 281 "/usr/include/time.h" 3 + + + +# 67 "/usr/include/sys/types.h" 2 3 + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 129 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned int size_t; + + + + + + + + + + + + + + + + + + + + + + + + + +# 256 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 70 "/usr/include/sys/types.h" 2 3 + + + + +typedef unsigned long int ulong; +typedef unsigned short int ushort; +typedef unsigned int uint; + + + + +# 95 "/usr/include/sys/types.h" 3 + + + + + + + + +typedef int int8_t __attribute__ ((__mode__ ( __QI__ ))) ; +typedef unsigned int u_int8_t __attribute__ ((__mode__ ( __QI__ ))) ; +typedef int int16_t __attribute__ ((__mode__ ( __HI__ ))) ; +typedef unsigned int u_int16_t __attribute__ ((__mode__ ( __HI__ ))) ; +typedef int int32_t __attribute__ ((__mode__ ( __SI__ ))) ; +typedef unsigned int u_int32_t __attribute__ ((__mode__ ( __SI__ ))) ; +typedef int int64_t __attribute__ ((__mode__ ( __DI__ ))) ; +typedef unsigned int u_int64_t __attribute__ ((__mode__ ( __DI__ ))) ; + +typedef int register_t __attribute__ ((__mode__ (__word__))); + + + + + + + + + + +# 1 "/usr/include/endian.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/bytesex.h" 1 3 + + + +# 34 "/usr/include/endian.h" 2 3 + + + + + + + + + + +# 123 "/usr/include/sys/types.h" 2 3 + + + +# 1 "/usr/include/sys/select.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/selectbits.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 50 "/usr/include/selectbits.h" 3 + +# 65 "/usr/include/selectbits.h" 3 + + + +# 31 "/usr/include/sys/select.h" 2 3 + + + + +# 1 "/usr/include/time.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 56 "/usr/include/time.h" 3 + + + +# 68 "/usr/include/time.h" 3 + + + +# 80 "/usr/include/time.h" 3 + + + + + + + + + + + +struct timespec + { + long int tv_sec; + long int tv_nsec; + }; + + + + + + +# 125 "/usr/include/time.h" 3 + + + +# 281 "/usr/include/time.h" 3 + + + +# 35 "/usr/include/sys/select.h" 2 3 + + + + + + + + +struct timeval; + +typedef __fd_mask fd_mask; + + +typedef __fd_set fd_set; + + + + + + + + + + + + + + + + + + + + + + +extern int __select (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timeval *__timeout) ; +extern int select (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timeval *__timeout) ; + + + + +extern int __pselect (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timespec *__timeout) ; +extern int pselect (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timespec *__timeout) ; + + + + + +# 126 "/usr/include/sys/types.h" 2 3 + + + + + + + +# 1 "t.c" 2 + +++ cat t.c +#include "sys/types.h" +#include "stdlib.h" +++ make -f confMakefile t +typedef long int __off_t; +typedef __quad_t __loff_t; +typedef __off_t off_t; +typedef __loff_t loff_t; +++ cat t.c +#include "sys/types.h" +#include "stdlib.h" +++ make -f confMakefile t +typedef int __ssize_t; +typedef __ssize_t ssize_t; +typedef unsigned int size_t; + size_t __statelen) ; + size_t __statelen) ; + size_t __statelen, struct random_data *__buf) ; + size_t __statelen, struct random_data *__buf) ; +extern void * malloc (size_t __size) ; +extern void * realloc (void * __ptr, size_t __size) ; +extern void * calloc (size_t __nmemb, size_t __size) ; +extern void * __alloca (size_t __size) ; +extern void * alloca (size_t __size) ; +extern void * valloc (size_t __size) ; + size_t __nmemb, size_t __size, +extern void qsort (void * __base, size_t __nmemb, size_t __size, + int *__sign, char *__buf, size_t __len) ; + int *__sign, char *__buf, size_t __len) ; + int *__sign, char *__buf, size_t __len) ; + int *__sign, char *__buf, size_t __len) ; +extern int mblen (__const char *__s, size_t __n) ; +extern int mbtowc (wchar_t *__pwc, __const char *__s, size_t __n) ; +extern size_t mbstowcs (wchar_t *__pwcs, __const char *__s, size_t __n) ; +extern size_t wcstombs (char *__s, __const wchar_t *__pwcs, size_t __n) ; +++ cat t.c +#include "sys/types.h" +++ make -f confMakefile t +typedef unsigned char __u_char; +typedef __u_char u_char; +++ cat t.c +#include "sys/types.h" +++ make -f confMakefile t +typedef unsigned short __u_short; +typedef __u_short u_short; +++ cat t.c +#include "sys/types.h" +++ make -f confMakefile t +typedef unsigned int __u_int; +typedef __u_int __uid_t; +typedef __u_int __gid_t; +typedef __u_int __mode_t; +typedef __u_int __nlink_t; +typedef __u_int u_int; +typedef unsigned int u_int8_t __attribute__ ((__mode__ ( __QI__ ))) ; +typedef unsigned int u_int16_t __attribute__ ((__mode__ ( __HI__ ))) ; +typedef unsigned int u_int32_t __attribute__ ((__mode__ ( __SI__ ))) ; +typedef unsigned int u_int64_t __attribute__ ((__mode__ ( __DI__ ))) ; +++ cat t.c +#include "sys/types.h" +++ make -f confMakefile t +typedef unsigned long __u_long; +typedef __u_long __ino_t; +typedef __u_long u_long; +++ cat t.c +main() { int one = 1; char* cp = (char*)&one; exit(*cp!=0); } +++ make -f confMakefile t +/usr/bin/gcc t.c +++ make -f confMakefile t +/usr/bin/gcc t.c -lm +++ cat t.c +/* this was lifted from GNU autoconf */ +/* Thanks to Mike Haertel and Jim Avera for this test. */ +#include +#include +#include +#if defined(__osf__) || defined(_AIX) +# define valloc malloc +#endif +char *valloc(), *malloc(); + +int +main() +{ + char *buf1, *buf2, *buf3; + int i = getpagesize(), j; + int i2 = getpagesize()*2; + int fd; + + buf1 = (char *)valloc(i2); + buf2 = (char *)valloc(i); + buf3 = (char *)malloc(i2); + for (j = 0; j < i2; ++j) + *(buf1 + j) = rand(); + fd = open("conftestmmap", O_CREAT | O_RDWR, 0666); + write(fd, buf1, i2); + mmap(buf2, i, PROT_READ | PROT_WRITE, MAP_FIXED | MAP_PRIVATE, fd, 0); + for (j = 0; j < i; ++j) + if (*(buf1 + j) != *(buf2 + j)) + exit(1); + lseek(fd, (long)i, 0); + read(fd, buf2, i); /* read into mapped memory -- file should not change */ + /* (it does in i386 SVR4.0 - Jim Avera, jima@netcom.com) */ + lseek(fd, (long)0, 0); + read(fd, buf3, i2); + for (j = 0; j < i2; ++j) + if (*(buf1 + j) != *(buf3 + j)) + exit(1); + exit(0); +} +++ make -f confMakefile t +/usr/bin/gcc t.c -lm +++ cat t.c +#include "sys/mman.h" +++ make -f confMakefile t +extern __caddr_t __mmap (__caddr_t __addr, size_t __len, int __prot, int __flags, int __fd, __off_t __offset) ; +extern __caddr_t mmap (__caddr_t __addr, size_t __len, int __prot, int __flags, int __fd, __off_t __offset) ; +++ make -f confMakefile t +/usr/bin/gcc -E t.c +# 1 "t.c" +# 1 "/usr/include/stdio.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/libio.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 117 "/usr/include/features.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/sys/cdefs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + +# 222 "/usr/include/features.h" 3 + +# 22 "/usr/include/sys/cdefs.h" 2 3 + + + + + + + + + + +# 54 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + +# 86 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + + + + + + + +# 205 "/usr/include/features.h" 2 3 + + + + + + + + + + + + + + +# 1 "/usr/include/gnu/stubs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 219 "/usr/include/features.h" 2 3 + + + + +# 29 "/usr/include/libio.h" 2 3 + + +# 1 "/usr/include/_G_config.h" 1 3 + + + + + + + + +# 1 "/usr/include/gnu/types.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned char __u_char; +typedef unsigned short __u_short; +typedef unsigned int __u_int; +typedef unsigned long __u_long; + +typedef unsigned long long int __u_quad_t; +typedef long long int __quad_t; +# 41 "/usr/include/gnu/types.h" 3 + +typedef __quad_t *__qaddr_t; + +typedef __u_quad_t __dev_t; +typedef __u_int __uid_t; +typedef __u_int __gid_t; +typedef __u_long __ino_t; +typedef __u_int __mode_t; +typedef __u_int __nlink_t; +typedef long int __off_t; +typedef __quad_t __loff_t; +typedef int __pid_t; +typedef int __ssize_t; + +typedef struct + { + int __val[2]; + } __fsid_t; + + +typedef int __daddr_t; +typedef char *__caddr_t; +typedef long int __time_t; +typedef long int __swblk_t; + +typedef long int __clock_t; + + +typedef unsigned long int __fd_mask; + + + + + + + + + + +typedef struct + { + + __fd_mask fds_bits[1024 / (8 * sizeof (__fd_mask)) ]; + } __fd_set; + + +typedef int __key_t; + +typedef unsigned short int __ipc_pid_t; + + +# 9 "/usr/include/_G_config.h" 2 3 + + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 129 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned int size_t; + + + + + + + + + + + + + + + + + + + + + + + + + +# 256 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 13 "/usr/include/_G_config.h" 2 3 + + + + + + + +typedef unsigned int wint_t; + + + + + + + + + +typedef int _G_int16_t __attribute__ ((__mode__ (__HI__))); +typedef int _G_int32_t __attribute__ ((__mode__ (__SI__))); +typedef unsigned int _G_uint16_t __attribute__ ((__mode__ (__HI__))); +typedef unsigned int _G_uint32_t __attribute__ ((__mode__ (__SI__))); + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 31 "/usr/include/libio.h" 2 3 + + + + + + + + + + + + + + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stdarg.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef void *__gnuc_va_list; + + + + + +# 94 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stdarg.h" 3 + + + + + + + + + + + + + +# 171 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stdarg.h" 3 + + + + +# 47 "/usr/include/libio.h" 2 3 + + + + + + + +# 64 "/usr/include/libio.h" 3 + + + + + + + + + + + + + + + + + + + + + + + +# 98 "/usr/include/libio.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +struct _IO_jump_t; struct _IO_FILE; + + + + + +typedef void _IO_lock_t; + + + + + +struct _IO_marker { + struct _IO_marker *_next; + struct _IO_FILE *_sbuf; + + + + int _pos; +# 182 "/usr/include/libio.h" 3 + +}; + +struct _IO_FILE { + int _flags; + + + + + char* _IO_read_ptr; + char* _IO_read_end; + char* _IO_read_base; + char* _IO_write_base; + char* _IO_write_ptr; + char* _IO_write_end; + char* _IO_buf_base; + char* _IO_buf_end; + + char *_IO_save_base; + char *_IO_backup_base; + char *_IO_save_end; + + struct _IO_marker *_markers; + + struct _IO_FILE *_chain; + + int _fileno; + int _blksize; + __off_t _offset; + + + + unsigned short _cur_column; + char _unused; + char _shortbuf[1]; + + + + _IO_lock_t *_lock; +}; + + +typedef struct _IO_FILE _IO_FILE; + + +struct _IO_FILE_plus; +extern struct _IO_FILE_plus _IO_stdin_, _IO_stdout_, _IO_stderr_; + + + + + + +typedef struct +{ + __ssize_t (*read) (struct _IO_FILE *, void *, __ssize_t ) ; + __ssize_t (*write) (struct _IO_FILE *, const void *, __ssize_t ) ; + __off_t (*seek) (struct _IO_FILE *, __off_t , int) ; + int (*close) (struct _IO_FILE *) ; +} _IO_cookie_io_functions_t; + + +struct _IO_cookie_file { + struct _IO_FILE file; + const void *vtable; + void *cookie; + _IO_cookie_io_functions_t io_functions; +}; + + + + + + +extern int __underflow (_IO_FILE*) ; +extern int __uflow (_IO_FILE*) ; +extern int __overflow (_IO_FILE*, int) ; + + + + + + + + + + + + + + + + + +extern int _IO_getc (_IO_FILE *__fp) ; +extern int _IO_putc (int __c, _IO_FILE *__fp) ; +extern int _IO_feof (_IO_FILE *__fp) ; +extern int _IO_ferror (_IO_FILE *__fp) ; + +extern int _IO_peekc_locked (_IO_FILE *__fp) ; + + + + + +extern void _IO_flockfile (_IO_FILE *) ; +extern void _IO_funlockfile (_IO_FILE *) ; +extern int _IO_ftrylockfile (_IO_FILE *) ; + + + + + + + + + + + + + + + + + + + + + + + + + + +extern int _IO_vfscanf (_IO_FILE*, const char*, __gnuc_va_list , int*) ; +extern int _IO_vfprintf (_IO_FILE*, const char*, __gnuc_va_list ) ; +extern __ssize_t _IO_padn (_IO_FILE *, int, __ssize_t ) ; +extern size_t _IO_sgetn (_IO_FILE *, void*, size_t ) ; + +extern __off_t _IO_seekoff (_IO_FILE*, __off_t , int, int) ; +extern __off_t _IO_seekpos (_IO_FILE*, __off_t , int) ; + +extern void _IO_free_backup_area (_IO_FILE*) ; + + + + + + +# 29 "/usr/include/stdio.h" 2 3 + + + + + + + + + + + + + + + + + + + + + + + + + + +# 69 "/usr/include/stdio.h" 3 + + +typedef struct _IO_FILE FILE; +typedef __off_t fpos_t; + +# 1 "/usr/include/stdio_lim.h" 1 3 + + + + + + + + + + + + + + + + + +# 74 "/usr/include/stdio.h" 2 3 + + + + + + + + +extern FILE *stdin, *stdout, *stderr; + + + + + + + + + + + + + + + + + +extern void clearerr (FILE*) ; +extern int fclose (FILE*) ; +extern int feof (FILE*) ; +extern int ferror (FILE*) ; +extern int fflush (FILE*) ; +extern int fgetc (FILE *) ; +extern int fgetpos (FILE* fp, fpos_t *__pos) ; +extern char* fgets (char*, int, FILE*) ; +extern FILE* fopen (__const char*, __const char*) ; +extern FILE* fopencookie (void *__cookie, __const char *__mode, + _IO_cookie_io_functions_t __io_functions) ; +extern int fprintf (FILE*, __const char* __format, ...) ; +extern int fputc (int, FILE*) ; +extern int fputs (__const char *__str, FILE *__fp) ; +extern size_t fread (void*, size_t, size_t, FILE*) ; +extern FILE* freopen (__const char*, __const char*, FILE*) ; +extern int fscanf (FILE *__fp, __const char* __format, ...) ; +extern int fseek (FILE* __fp, long int __offset, int __whence) ; +extern int fsetpos (FILE* __fp, __const fpos_t *__pos) ; +extern long int ftell (FILE* __fp) ; +extern size_t fwrite (__const void*, size_t, size_t, FILE*) ; +extern int getc (FILE *) ; +extern int getchar (void) ; +extern char* gets (char*) ; +extern void perror (__const char *) ; +extern int printf (__const char* __format, ...) ; +extern int putc (int, FILE *) ; +extern int putchar (int) ; +extern int puts (__const char *__str) ; +extern int remove (__const char*) ; +extern int rename (__const char* __old, __const char* __new) ; +extern void rewind (FILE*) ; +extern int scanf (__const char* format, ...) ; +extern void setbuf (FILE*, char*) ; +extern void setlinebuf (FILE*) ; +extern void setbuffer (FILE*, char*, int) ; +extern int setvbuf (FILE*, char*, int __mode, size_t __size) ; +extern int sprintf (char*, __const char* __format, ...) ; +extern int sscanf (__const char* string, __const char* __format, ...) ; +extern FILE* tmpfile (void) ; +extern char* tmpnam (char*) ; + +extern char* tmpnam_r (char*) ; + + +extern char *tempnam (__const char *__dir, __const char *__pfx) ; + +extern char *__stdio_gen_tempname (char *__buf, size_t bufsize, + __const char *dir, __const char *pfx, + int dir_search, size_t *lenptr, + FILE **streamptr) ; +extern int ungetc (int c, FILE* fp) ; +extern int vfprintf (FILE *fp, char __const *fmt0, __gnuc_va_list ) ; +extern int vprintf (char __const *fmt, __gnuc_va_list ) ; +extern int vsprintf (char* string, __const char* format, __gnuc_va_list ) ; +extern void __libc_fatal (__const char *__message) + __attribute__ ((__noreturn__)); + + +extern int dprintf (int, __const char *, ...) ; +extern int vdprintf (int, __const char *, __gnuc_va_list ) ; +extern int vfscanf (FILE*, __const char *, __gnuc_va_list ) ; +extern int __vfscanf (FILE*, __const char *, __gnuc_va_list ) ; +extern int vscanf (__const char *, __gnuc_va_list ) ; +extern int vsscanf (__const char *, __const char *, __gnuc_va_list ) ; +extern int __vsscanf (__const char *, __const char *, __gnuc_va_list ) ; + + +# 177 "/usr/include/stdio.h" 3 + + + +extern FILE *fdopen (int, __const char *) ; +extern int fileno (FILE*) ; +extern FILE* popen (__const char*, __const char*) ; +extern int pclose (FILE*) ; + + + + + +extern char *ctermid (char *__buf) ; + + +extern char *cuserid (char * __buf) ; + + + +extern int snprintf (char *, size_t, __const char *, ...) ; +extern int __snprintf (char *, size_t, __const char *, ...) ; +extern int vsnprintf (char *, size_t, __const char *, __gnuc_va_list ) ; +extern int __vsnprintf (char *, size_t, __const char *, __gnuc_va_list ) ; + + +# 214 "/usr/include/stdio.h" 3 + + +extern int __underflow (struct _IO_FILE*) ; +extern int __overflow (struct _IO_FILE*, int) ; + + +extern int sys_nerr; +extern const char *const sys_errlist[]; + + + + + + + + +extern void clearerr_locked (FILE *) ; +extern void clearerr_unlocked (FILE *) ; +extern int feof_locked (FILE *) ; +extern int feof_unlocked (FILE *) ; +extern int ferror_locked (FILE*) ; +extern int ferror_unlocked (FILE*) ; +extern int fileno_locked (FILE *) ; +extern int fileno_unlocked (FILE *) ; +extern int fclose_unlocked (FILE *) ; +extern int fflush_locked (FILE *) ; +extern int fflush_unlocked (FILE *) ; +extern size_t fread_unlocked (void *, size_t, size_t, FILE *) ; +extern size_t fwrite_unlocked (const void *, size_t, size_t, FILE *) ; + +extern int fputc_locked (int, FILE*) ; +extern int fputc_unlocked (int, FILE*) ; +extern int getc_locked (FILE *) ; +extern int getchar_locked (void) ; +extern int putc_locked (int, FILE *) ; +extern int putchar_locked (int) ; + + + + + + + + + + +extern void flockfile (FILE *) ; +extern void funlockfile (FILE *) ; +extern int ftrylockfile (FILE *) ; + +extern int getc_unlocked (FILE *) ; +extern int getchar_unlocked (void) ; +extern int putc_unlocked (int, FILE *) ; +extern int putchar_unlocked (int) ; + + + + + + + + + + + + + + + + + + + + + + +# 1 "t.c" 2 + +++ make -f confMakefile t +/usr/bin/gcc -E t.c +# 1 "t.c" +# 1 "/usr/include/unistd.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 117 "/usr/include/features.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/sys/cdefs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + +# 222 "/usr/include/features.h" 3 + +# 22 "/usr/include/sys/cdefs.h" 2 3 + + + + + + + + + + +# 54 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + +# 86 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + + + + + + + +# 205 "/usr/include/features.h" 2 3 + + + + + + + + + + + + + + +# 1 "/usr/include/gnu/stubs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 219 "/usr/include/features.h" 2 3 + + + + +# 26 "/usr/include/unistd.h" 2 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/posix_opt.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 137 "/usr/include/unistd.h" 2 3 + + + + + + + + + + + +# 1 "/usr/include/gnu/types.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned char __u_char; +typedef unsigned short __u_short; +typedef unsigned int __u_int; +typedef unsigned long __u_long; + +typedef unsigned long long int __u_quad_t; +typedef long long int __quad_t; +# 41 "/usr/include/gnu/types.h" 3 + +typedef __quad_t *__qaddr_t; + +typedef __u_quad_t __dev_t; +typedef __u_int __uid_t; +typedef __u_int __gid_t; +typedef __u_long __ino_t; +typedef __u_int __mode_t; +typedef __u_int __nlink_t; +typedef long int __off_t; +typedef __quad_t __loff_t; +typedef int __pid_t; +typedef int __ssize_t; + +typedef struct + { + int __val[2]; + } __fsid_t; + + +typedef int __daddr_t; +typedef char *__caddr_t; +typedef long int __time_t; +typedef long int __swblk_t; + +typedef long int __clock_t; + + +typedef unsigned long int __fd_mask; + + + + + + + + + + +typedef struct + { + + __fd_mask fds_bits[1024 / (8 * sizeof (__fd_mask)) ]; + } __fd_set; + + +typedef int __key_t; + +typedef unsigned short int __ipc_pid_t; + + +# 148 "/usr/include/unistd.h" 2 3 + + + +typedef __ssize_t ssize_t; + + + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 129 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned int size_t; + + + + + + + + + + + + + + + + + + + + + + + + + +# 256 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 157 "/usr/include/unistd.h" 2 3 + + + + + + + + + + + +extern int __access (__const char *__name, int __type) ; +extern int access (__const char *__name, int __type) ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +extern __off_t __lseek (int __fd, __off_t __offset, int __whence) ; +extern __off_t lseek (int __fd, __off_t __offset, int __whence) ; + + +extern int __close (int __fd) ; +extern int close (int __fd) ; + + + +extern ssize_t __read (int __fd, void * __buf, size_t __nbytes) ; +extern ssize_t read (int __fd, void * __buf, size_t __nbytes) ; + + +extern ssize_t __write (int __fd, __const void * __buf, size_t __n) ; +extern ssize_t write (int __fd, __const void * __buf, size_t __n) ; + + + + + + +extern int __pipe (int __pipedes[2]) ; +extern int pipe (int __pipedes[2]) ; + + + + + + + + +extern unsigned int alarm (unsigned int __seconds) ; + + + + + + + + +extern unsigned int sleep (unsigned int __seconds) ; + + + + + + +extern unsigned int ualarm (unsigned int __value, + unsigned int __interval) ; + + + +extern void usleep (unsigned int __useconds) ; + + + + + +extern int pause (void) ; + + + +extern int __chown (__const char *__file, + __uid_t __owner, __gid_t __group) ; +extern int chown (__const char *__file, + __uid_t __owner, __gid_t __group) ; + + + +extern int __fchown (int __fd, + __uid_t __owner, __gid_t __group) ; +extern int fchown (int __fd, + __uid_t __owner, __gid_t __group) ; + + + + +extern int __lchown (__const char *__file, __uid_t __owner, + __gid_t __group) ; +extern int lchown (__const char *__file, __uid_t __owner, + __gid_t __group) ; + + + + +extern int __chdir (__const char *__path) ; +extern int chdir (__const char *__path) ; + + + +extern int fchdir (int __fd) ; + + + + + + + + + +extern char *__getcwd (char *__buf, size_t __size) ; +extern char *getcwd (char *__buf, size_t __size) ; + +# 317 "/usr/include/unistd.h" 3 + + + + + + +extern char *getwd (char *__buf) ; + + + + +extern int __dup (int __fd) ; +extern int dup (int __fd) ; + + +extern int __dup2 (int __fd, int __fd2) ; +extern int dup2 (int __fd, int __fd2) ; + + +extern char **__environ; + + + + + + + +extern int __execve (__const char *__path, char *__const __argv[], + char *__const __envp[]) ; +extern int execve (__const char *__path, char *__const __argv[], + char *__const __envp[]) ; + + + + + + + + + + + +extern int execv (__const char *__path, char *__const __argv[]) ; + + + +extern int execle (__const char *__path, __const char *__arg, ...) ; + + + +extern int execl (__const char *__path, __const char *__arg, ...) ; + + + +extern int execvp (__const char *__file, char *__const __argv[]) ; + + + + +extern int execlp (__const char *__file, __const char *__arg, ...) ; + + + + +extern int nice (int __inc) ; + + + + +extern void _exit (int __status) __attribute__ ((__noreturn__)); + + + + + +# 1 "/usr/include/confname.h" 1 3 + + + + + + + + + + + + + + + + + + + + +enum + { + _PC_LINK_MAX, + + _PC_MAX_CANON, + + _PC_MAX_INPUT, + + _PC_NAME_MAX, + + _PC_PATH_MAX, + + _PC_PIPE_BUF, + + _PC_CHOWN_RESTRICTED, + + _PC_NO_TRUNC, + + _PC_VDISABLE, + + _PC_SYNC_IO, + + _PC_ASYNC_IO, + + _PC_PRIO_IO, + + _PC_SOCK_MAXBUF + + }; + + +enum + { + _SC_ARG_MAX, + + _SC_CHILD_MAX, + + _SC_CLK_TCK, + + _SC_NGROUPS_MAX, + + _SC_OPEN_MAX, + + _SC_STREAM_MAX, + + _SC_TZNAME_MAX, + + _SC_JOB_CONTROL, + + _SC_SAVED_IDS, + + _SC_REALTIME_SIGNALS, + + _SC_PRIORITY_SCHEDULING, + + _SC_TIMERS, + + _SC_ASYNCHRONOUS_IO, + + _SC_PRIORITIZED_IO, + + _SC_SYNCHRONIZED_IO, + + _SC_FSYNC, + + _SC_MAPPED_FILES, + + _SC_MEMLOCK, + + _SC_MEMLOCK_RANGE, + + _SC_MEMORY_PROTECTION, + + _SC_MESSAGE_PASSING, + + _SC_SEMAPHORES, + + _SC_SHARED_MEMORY_OBJECTS, + + _SC_AIO_LISTIO_MAX, + + _SC_AIO_MAX, + + _SC_AIO_PRIO_DELTA_MAX, + + _SC_DELAYTIMER_MAX, + + _SC_MQ_OPEN_MAX, + + _SC_MQ_PRIO_MAX, + + _SC_VERSION, + + _SC_PAGESIZE, + + + _SC_RTSIG_MAX, + + _SC_SEM_NSEMS_MAX, + + _SC_SEM_VALUE_MAX, + + _SC_SIGQUEUE_MAX, + + _SC_TIMER_MAX, + + + + + _SC_BC_BASE_MAX, + + _SC_BC_DIM_MAX, + + _SC_BC_SCALE_MAX, + + _SC_BC_STRING_MAX, + + _SC_COLL_WEIGHTS_MAX, + + _SC_EQUIV_CLASS_MAX, + + _SC_EXPR_NEST_MAX, + + _SC_LINE_MAX, + + _SC_RE_DUP_MAX, + + _SC_CHARCLASS_NAME_MAX, + + + _SC_2_VERSION, + + _SC_2_C_BIND, + + _SC_2_C_DEV, + + _SC_2_FORT_DEV, + + _SC_2_FORT_RUN, + + _SC_2_SW_DEV, + + _SC_2_LOCALEDEF, + + + _SC_PII, + + _SC_PII_XTI, + + _SC_PII_SOCKET, + + _SC_PII_INTERNET, + + _SC_PII_OSI, + + _SC_POLL, + + _SC_SELECT, + + _SC_UIO_MAXIOV, + + _SC_PII_INTERNET_STREAM, + + _SC_PII_INTERNET_DGRAM, + + _SC_PII_OSI_COTS, + + _SC_PII_OSI_CLTS, + + _SC_PII_OSI_M, + + _SC_T_IOV_MAX, + + + + _SC_THREADS, + + _SC_THREAD_SAFE_FUNCTIONS, + + _SC_GETGR_R_SIZE_MAX, + + _SC_GETPW_R_SIZE_MAX, + + _SC_LOGIN_NAME_MAX, + + _SC_TTY_NAME_MAX, + + _SC_THREAD_DESTRUCTOR_ITERATIONS, + + _SC_THREAD_KEYS_MAX, + + _SC_THREAD_STACK_MIN, + + _SC_THREAD_THREADS_MAX, + + _SC_THREAD_ATTR_STACKADDR, + + _SC_THREAD_ATTR_STACKSIZE, + + _SC_THREAD_PRIORITY_SCHEDULING, + + _SC_THREAD_PRIO_INHERIT, + + _SC_THREAD_PRIO_PROTECT, + + _SC_THREAD_PROCESS_SHARED, + + + _SC_NPROCESSORS_CONF, + + _SC_NPROCESSORS_ONLN, + + _SC_PHYS_PAGES, + + _SC_AVPHYS_PAGES, + + _SC_ATEXIT_MAX, + + _SC_PASS_MAX, + + + _SC_XOPEN_VERSION, + + _SC_XOPEN_XCU_VERSION, + + _SC_XOPEN_UNIX, + + _SC_XOPEN_CRYPT, + + _SC_XOPEN_ENH_I18N, + + _SC_XOPEN_SHM, + + + _SC_2_CHAR_TERM, + + _SC_2_C_VERSION, + + _SC_2_UPE, + + + _SC_XOPEN_XPG2, + + _SC_XOPEN_XPG3, + + _SC_XOPEN_XPG4, + + + _SC_CHAR_BIT, + + _SC_CHAR_MAX, + + _SC_CHAR_MIN, + + _SC_INT_MAX, + + _SC_INT_MIN, + + _SC_LONG_BIT, + + _SC_WORD_BIT, + + _SC_MB_LEN_MAX, + + _SC_NZERO, + + _SC_SSIZE_MAX, + + _SC_SCHAR_MAX, + + _SC_SCHAR_MIN, + + _SC_SHRT_MAX, + + _SC_SHRT_MIN, + + _SC_UCHAR_MAX, + + _SC_UINT_MAX, + + _SC_ULONG_MAX, + + _SC_USHRT_MAX, + + + _SC_NL_ARGMAX, + + _SC_NL_LANGMAX, + + _SC_NL_MSGMAX, + + _SC_NL_NMAX, + + _SC_NL_SETMAX, + + _SC_NL_TEXTMAX + + }; + + + +enum + { + _CS_PATH + + }; + +# 392 "/usr/include/unistd.h" 2 3 + + + +extern long int __pathconf (__const char *__path, int __name) ; +extern long int pathconf (__const char *__path, int __name) ; + + +extern long int __fpathconf (int __fd, int __name) ; +extern long int fpathconf (int __fd, int __name) ; + + +extern long int __sysconf (int __name) ; +extern long int sysconf (int __name) ; + + + +extern size_t confstr (int __name, char *__buf, size_t __len) ; + + + + +extern __pid_t __getpid (void) ; +extern __pid_t getpid (void) ; + + +extern __pid_t __getppid (void) ; +extern __pid_t getppid (void) ; + + +extern __pid_t getpgrp (void) ; + + + + +extern int setpgid (__pid_t __pid, __pid_t __pgid) ; + + +extern __pid_t __getpgid (__pid_t __pid) ; + + + + + + + + + + + + + + + + + + + +extern int setpgrp (void) ; + + + + + + + + + + + + +extern __pid_t __setsid (void) ; +extern __pid_t setsid (void) ; + + + + + + + +extern __uid_t __getuid (void) ; +extern __uid_t getuid (void) ; + + +extern __uid_t __geteuid (void) ; +extern __uid_t geteuid (void) ; + + +extern __gid_t __getgid (void) ; +extern __gid_t getgid (void) ; + + +extern __gid_t __getegid (void) ; +extern __gid_t getegid (void) ; + + + + +extern int __getgroups (int __size, __gid_t __list[]) ; +extern int getgroups (int __size, __gid_t __list[]) ; + + + + + + + + + + + +extern int __setuid (__uid_t __uid) ; +extern int setuid (__uid_t __uid) ; + + + + +extern int __setreuid (__uid_t __ruid, __uid_t __euid) ; +extern int setreuid (__uid_t __ruid, __uid_t __euid) ; + + + + +extern int seteuid (__uid_t __uid) ; + + + + + + +extern int __setgid (__gid_t __gid) ; +extern int setgid (__gid_t __gid) ; + + + + +extern int __setregid (__gid_t __rgid, __gid_t __egid) ; +extern int setregid (__gid_t __rgid, __gid_t __egid) ; + + + + +extern int setegid (__gid_t __gid) ; + + + + + + +extern __pid_t __fork (void) ; +extern __pid_t fork (void) ; + + + + + + +extern __pid_t __vfork (void) ; +extern __pid_t vfork (void) ; + + + + + +extern char *ttyname (int __fd) ; + + + +extern int __ttyname_r (int __fd, char *__buf, size_t __buflen) ; +extern int ttyname_r (int __fd, char *__buf, size_t __buflen) ; + + + +extern int __isatty (int __fd) ; +extern int isatty (int __fd) ; + + + + +extern int ttyslot (void) ; + + + + +extern int __link (__const char *__from, __const char *__to) ; +extern int link (__const char *__from, __const char *__to) ; + + + +extern int __symlink (__const char *__from, __const char *__to) ; +extern int symlink (__const char *__from, __const char *__to) ; + + + + +extern int __readlink (__const char *__path, char *__buf, size_t __len) ; +extern int readlink (__const char *__path, char *__buf, size_t __len) ; + + + +extern int __unlink (__const char *__name) ; +extern int unlink (__const char *__name) ; + + +extern int __rmdir (__const char *__path) ; +extern int rmdir (__const char *__path) ; + + + +extern __pid_t tcgetpgrp (int __fd) ; + + +extern int tcsetpgrp (int __fd, __pid_t __pgrp_id) ; + + + +extern char *getlogin (void) ; + + + + + + + + + +extern int setlogin (__const char *__name) ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +extern int getopt (int __argc, char *__const * __argv, + __const char *__opts) ; +extern int opterr; +extern int optind; +extern int optopt; +extern char *optarg; + + + + + + + + +extern int __gethostname (char *__name, size_t __len) ; +extern int gethostname (char *__name, size_t __len) ; + + + +extern int sethostname (__const char *__name, size_t __len) ; + + + +extern int sethostid (long int __id) ; + + + + + +extern int getdomainname (char *__name, size_t __len) ; +extern int setdomainname (__const char *__name, size_t __len) ; + + + +extern int fsync (int __fd) ; + + + + + +extern int vhangup (void) ; + + +extern int revoke (__const char *__file) ; + + + + + + + +extern int profil (unsigned short int *__sample_buffer, size_t __size, + size_t __offset, unsigned int __scale) ; + + + + + +extern int acct (__const char *__name) ; + + + +extern int chroot (__const char *__path) ; + + + +extern char *getusershell (void) ; +extern void endusershell (void) ; +extern void setusershell (void) ; + + + + +extern char *getpass (__const char *__prompt) ; + + + + +extern int daemon (int __nochdir, int __noclose) ; + + + + + + + +extern long int gethostid (void) ; + + +extern int sync (void) ; + + + + +extern int __getpagesize (void) ; +extern int getpagesize (void) ; + + + +extern int truncate (__const char *__file, __off_t __length) ; + + +extern int ftruncate (int __fd, __off_t __length) ; + + + + +extern int __getdtablesize (void) ; +extern int getdtablesize (void) ; + + + + + + + + +extern int __brk (void * __addr) ; +extern int brk (void * __addr) ; + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef int ptrdiff_t; + + + + + + + + + + + + + + + + + + +# 182 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + +# 256 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 768 "/usr/include/unistd.h" 2 3 + + + + + + +extern void * __sbrk (ptrdiff_t __delta) ; +extern void * sbrk (ptrdiff_t __delta) ; + + + + + + + + + + + + + + +extern long int syscall (long int __sysno, ...) ; + + + + + + + + + + + + + + + + + + + +extern int lockf (int __fd, int __cmd, __off_t __len) ; + + + +# 833 "/usr/include/unistd.h" 3 + + + + + +extern int fdatasync (int __fildes) ; + + + + + +# 861 "/usr/include/unistd.h" 3 + + + + + +# 1 "t.c" 2 + +++ make -f confMakefile t +/usr/bin/gcc -E t.c +# 1 "t.c" +# 1 "/usr/include/string.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 117 "/usr/include/features.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/sys/cdefs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + +# 222 "/usr/include/features.h" 3 + +# 22 "/usr/include/sys/cdefs.h" 2 3 + + + + + + + + + + +# 54 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + +# 86 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + + + + + + + +# 205 "/usr/include/features.h" 2 3 + + + + + + + + + + + + + + +# 1 "/usr/include/gnu/stubs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 219 "/usr/include/features.h" 2 3 + + + + +# 26 "/usr/include/string.h" 2 3 + + + + + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 129 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned int size_t; + + + + + + + + + + + + + + + + + + + + + + + + + +# 256 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 33 "/usr/include/string.h" 2 3 + + + + +extern void * memcpy (void * __dest, __const void * __src, + size_t __n) ; + + +extern void * memmove (void * __dest, __const void * __src, + size_t __n) ; + + + + +extern void * __memccpy (void * __dest, __const void * __src, + int __c, size_t __n) ; + +extern void * memccpy (void * __dest, __const void * __src, + int __c, size_t __n) ; + + + + +extern void * memset (void * __s, int __c, size_t __n) ; + + +extern int memcmp (__const void * __s1, __const void * __s2, + size_t __n) ; + + +extern void * memchr (__const void * __s, int __c, size_t __n) ; + + + +extern char *strcpy (char *__dest, __const char *__src) ; + +extern char *strncpy (char *__dest, __const char *__src, size_t __n) ; + + +extern char *strcat (char *__dest, __const char *__src) ; + +extern char *strncat (char *__dest, __const char *__src, size_t __n) ; + + +extern int strcmp (__const char *__s1, __const char *__s2) ; + +extern int strncmp (__const char *__s1, __const char *__s2, size_t __n) ; + + +extern int strcoll (__const char *__s1, __const char *__s2) ; + +extern size_t strxfrm (char *__dest, __const char *__src, size_t __n) ; + + + +extern char *__strdup (__const char *__s) ; +extern char *strdup (__const char *__s) ; + + + + + +extern char *__strndup (__const char *__string, size_t __n) ; + + + + +# 121 "/usr/include/string.h" 3 + + + +extern char *strchr (__const char *__s, int __c) ; + +extern char *strrchr (__const char *__s, int __c) ; + + + +extern size_t strcspn (__const char *__s, __const char *__reject) ; + + +extern size_t strspn (__const char *__s, __const char *__accept) ; + +extern char *strpbrk (__const char *__s, __const char *__accept) ; + +extern char *strstr (__const char *__haystack, __const char *__needle) ; + +extern char *strtok (char *__s, __const char *__delim) ; + + + + +extern char *strtok_r (char *__s, __const char *__delim, + char **__save_ptr) ; + + + + + + + + + + + + +extern size_t strlen (__const char *__s) ; + +# 173 "/usr/include/string.h" 3 + + + + +extern char *strerror (int __errnum) ; + + + +extern char *__strerror_r (int __errnum, char *__buf, size_t __buflen) ; +extern char *strerror_r (int __errnum, char *__buf, size_t __buflen) ; + + + + +extern void bcopy (__const void * __src, void * __dest, size_t __n) ; + + +extern void bzero (void * __s, size_t __n) ; + + +extern int bcmp (__const void * __s1, __const void * __s2, size_t __n) ; + + +extern char *index (__const char *__s, int __c) ; + + +extern char *rindex (__const char *__s, int __c) ; + + + +extern int ffs (int __i) ; + + +extern int __strcasecmp (__const char *__s1, __const char *__s2) ; +extern int strcasecmp (__const char *__s1, __const char *__s2) ; + + +extern int __strncasecmp (__const char *__s1, __const char *__s2, + size_t __n) ; +extern int strncasecmp (__const char *__s1, __const char *__s2, + size_t __n) ; + + + + + +extern char *__strsep (char **__stringp, __const char *__delim) ; +extern char *strsep (char **__stringp, __const char *__delim) ; + + +# 241 "/usr/include/string.h" 3 + + + + +extern char *basename (__const char *__filename) ; + + + + + +# 1 "t.c" 2 + +++ make -f confMakefile t +/usr/bin/gcc -E t.c +# 1 "t.c" +# 1 "/usr/include/stdlib.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 117 "/usr/include/features.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/sys/cdefs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/features.h" 1 3 + + + + + + + + + + + + + + + + + + +# 222 "/usr/include/features.h" 3 + +# 22 "/usr/include/sys/cdefs.h" 2 3 + + + + + + + + + + +# 54 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + +# 86 "/usr/include/sys/cdefs.h" 3 + + + + + + + + + + + + + + + + + + + + +# 205 "/usr/include/features.h" 2 3 + + + + + + + + + + + + + + +# 1 "/usr/include/gnu/stubs.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 219 "/usr/include/features.h" 2 3 + + + + +# 26 "/usr/include/stdlib.h" 2 3 + + + + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 129 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned int size_t; + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef long int wchar_t; + + + + + + + + + + + + + + + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 32 "/usr/include/stdlib.h" 2 3 + + + + + +typedef struct + { + int quot; + int rem; + } div_t; + + +typedef struct + { + long int quot; + long int rem; + } ldiv_t; + + + + + + + + + + + + + + + + + + + + + + + +extern int __ctype_get_mb_cur_max (void) ; + + + +extern double atof (__const char *__nptr) ; + +extern int atoi (__const char *__nptr) ; + +extern long int atol (__const char *__nptr) ; + + + +extern long long int atoll (__const char *__nptr) ; + + + +extern double strtod (__const char *__nptr, char **__endptr) ; + + + + + + + + +extern long int strtol (__const char *__nptr, char **__endptr, + int __base) ; + +extern unsigned long int strtoul (__const char *__nptr, + char **__endptr, int __base) ; + + + +extern long long int strtoq (__const char *__nptr, char **__endptr, + int __base) ; + +extern unsigned long long int strtouq (__const char *__nptr, + char **__endptr, int __base) ; + + + + + + +extern long long int strtoll (__const char *__nptr, char **__endptr, + int __base) ; + +extern unsigned long long int strtoull (__const char *__nptr, + char **__endptr, int __base) ; + + + + + + + +extern double __strtod_internal (__const char *__nptr, + char **__endptr, int __group) ; +extern float __strtof_internal (__const char *__nptr, char **__endptr, + int __group) ; +extern long double __strtold_internal (__const char *__nptr, + char **__endptr, int __group) ; +extern long int __strtol_internal (__const char *__nptr, char **__endptr, + int __base, int __group) ; +extern unsigned long int __strtoul_internal (__const char *__nptr, + char **__endptr, int __base, + int __group) ; + +extern long long int __strtoq_internal (__const char *__nptr, + char **__endptr, int __base, + int __group) ; +extern unsigned long long int __strtouq_internal (__const char *__nptr, + char **__endptr, + int __base, + int __group) ; + + +# 197 "/usr/include/stdlib.h" 3 + + + + + + + +extern char *l64a (long int __n) ; + + +extern long int a64l (__const char *__s) ; + + +# 1 "/usr/include/sys/types.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/gnu/types.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + +typedef unsigned char __u_char; +typedef unsigned short __u_short; +typedef unsigned int __u_int; +typedef unsigned long __u_long; + +typedef unsigned long long int __u_quad_t; +typedef long long int __quad_t; +# 41 "/usr/include/gnu/types.h" 3 + +typedef __quad_t *__qaddr_t; + +typedef __u_quad_t __dev_t; +typedef __u_int __uid_t; +typedef __u_int __gid_t; +typedef __u_long __ino_t; +typedef __u_int __mode_t; +typedef __u_int __nlink_t; +typedef long int __off_t; +typedef __quad_t __loff_t; +typedef int __pid_t; +typedef int __ssize_t; + +typedef struct + { + int __val[2]; + } __fsid_t; + + +typedef int __daddr_t; +typedef char *__caddr_t; +typedef long int __time_t; +typedef long int __swblk_t; + +typedef long int __clock_t; + + +typedef unsigned long int __fd_mask; + + + + + + + + + + +typedef struct + { + + __fd_mask fds_bits[1024 / (8 * sizeof (__fd_mask)) ]; + } __fd_set; + + +typedef int __key_t; + +typedef unsigned short int __ipc_pid_t; + + +# 30 "/usr/include/sys/types.h" 2 3 + + + +typedef __u_char u_char; +typedef __u_short u_short; +typedef __u_int u_int; +typedef __u_long u_long; +typedef __quad_t quad_t; +typedef __u_quad_t u_quad_t; +typedef __fsid_t fsid_t; + + +typedef __dev_t dev_t; +typedef __gid_t gid_t; +typedef __ino_t ino_t; +typedef __mode_t mode_t; +typedef __nlink_t nlink_t; +typedef __off_t off_t; +typedef __loff_t loff_t; +typedef __pid_t pid_t; +typedef __uid_t uid_t; + + +typedef __ssize_t ssize_t; + + + + +typedef __daddr_t daddr_t; +typedef __caddr_t caddr_t; + + + +typedef __key_t key_t; + + + +# 1 "/usr/include/time.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 56 "/usr/include/time.h" 3 + + + +# 68 "/usr/include/time.h" 3 + + + + + + + + + + +typedef __time_t time_t; + + + + + +# 97 "/usr/include/time.h" 3 + + + + + +# 125 "/usr/include/time.h" 3 + + + +# 281 "/usr/include/time.h" 3 + + + +# 67 "/usr/include/sys/types.h" 2 3 + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 129 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + +# 180 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + +# 256 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 70 "/usr/include/sys/types.h" 2 3 + + + + +typedef unsigned long int ulong; +typedef unsigned short int ushort; +typedef unsigned int uint; + + + + +# 95 "/usr/include/sys/types.h" 3 + + + + + + + + +typedef int int8_t __attribute__ ((__mode__ ( __QI__ ))) ; +typedef unsigned int u_int8_t __attribute__ ((__mode__ ( __QI__ ))) ; +typedef int int16_t __attribute__ ((__mode__ ( __HI__ ))) ; +typedef unsigned int u_int16_t __attribute__ ((__mode__ ( __HI__ ))) ; +typedef int int32_t __attribute__ ((__mode__ ( __SI__ ))) ; +typedef unsigned int u_int32_t __attribute__ ((__mode__ ( __SI__ ))) ; +typedef int int64_t __attribute__ ((__mode__ ( __DI__ ))) ; +typedef unsigned int u_int64_t __attribute__ ((__mode__ ( __DI__ ))) ; + +typedef int register_t __attribute__ ((__mode__ (__word__))); + + + + + + + + + + +# 1 "/usr/include/endian.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/bytesex.h" 1 3 + + + +# 34 "/usr/include/endian.h" 2 3 + + + + + + + + + + +# 123 "/usr/include/sys/types.h" 2 3 + + + +# 1 "/usr/include/sys/select.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/include/selectbits.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 50 "/usr/include/selectbits.h" 3 + +# 65 "/usr/include/selectbits.h" 3 + + + +# 31 "/usr/include/sys/select.h" 2 3 + + + + +# 1 "/usr/include/time.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 56 "/usr/include/time.h" 3 + + + +# 68 "/usr/include/time.h" 3 + + + +# 80 "/usr/include/time.h" 3 + + + + + + + + + + + +struct timespec + { + long int tv_sec; + long int tv_nsec; + }; + + + + + + +# 125 "/usr/include/time.h" 3 + + + +# 281 "/usr/include/time.h" 3 + + + +# 35 "/usr/include/sys/select.h" 2 3 + + + + + + + + +struct timeval; + +typedef __fd_mask fd_mask; + + +typedef __fd_set fd_set; + + + + + + + + + + + + + + + + + + + + + + +extern int __select (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timeval *__timeout) ; +extern int select (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timeval *__timeout) ; + + + + +extern int __pselect (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timespec *__timeout) ; +extern int pselect (int __nfds, __fd_set *__readfds, + __fd_set *__writefds, __fd_set *__exceptfds, + struct timespec *__timeout) ; + + + + + +# 126 "/usr/include/sys/types.h" 2 3 + + + + + + + +# 210 "/usr/include/stdlib.h" 2 3 + + + + + + + +extern int32_t __random (void) ; +extern int32_t random (void) ; + + +extern void __srandom (unsigned int __seed) ; +extern void srandom (unsigned int __seed) ; + + + + + +extern void * __initstate (unsigned int __seed, void * __statebuf, + size_t __statelen) ; +extern void * initstate (unsigned int __seed, void * __statebuf, + size_t __statelen) ; + + + +extern void * __setstate (void * __statebuf) ; +extern void * setstate (void * __statebuf) ; + + + + + + + +struct random_data + { + int32_t *fptr; + int32_t *rptr; + int32_t *state; + int rand_type; + int rand_deg; + int rand_sep; + int32_t *end_ptr; + }; + +extern int __random_r (struct random_data *__buf, int32_t *__result) ; +extern int random_r (struct random_data *__buf, int32_t *__result) ; + +extern int __srandom_r (unsigned int __seed, struct random_data *__buf) ; +extern int srandom_r (unsigned int __seed, struct random_data *__buf) ; + +extern int __initstate_r (unsigned int __seed, void * __statebuf, + size_t __statelen, struct random_data *__buf) ; +extern int initstate_r (unsigned int __seed, void * __statebuf, + size_t __statelen, struct random_data *__buf) ; + +extern int __setstate_r (void * __statebuf, struct random_data *__buf) ; +extern int setstate_r (void * __statebuf, struct random_data *__buf) ; + + + + + +extern int rand (void) ; + +extern void srand (unsigned int __seed) ; + + + +extern int __rand_r (unsigned int *__seed) ; +extern int rand_r (unsigned int *__seed) ; + + + + + + + +extern double drand48 (void) ; +extern double erand48 (unsigned short int __xsubi[3]) ; + + +extern long lrand48 (void) ; +extern long nrand48 (unsigned short int __xsubi[3]) ; + + +extern long mrand48 (void) ; +extern long jrand48 (unsigned short int __xsubi[3]) ; + + +extern void srand48 (long __seedval) ; +extern unsigned short int *seed48 (unsigned short int __seed16v[3]) ; +extern void lcong48 (unsigned short int __param[7]) ; + + +struct drand48_data + { + unsigned short int x[3]; + unsigned short int a[3]; + unsigned short int c; + unsigned short int old_x[3]; + int init; + }; + + + +extern int drand48_r (struct drand48_data *__buffer, double *__result) ; +extern int erand48_r (unsigned short int __xsubi[3], + struct drand48_data *__buffer, double *__result) ; + + +extern int lrand48_r (struct drand48_data *__buffer, long *__result) ; +extern int nrand48_r (unsigned short int __xsubi[3], + struct drand48_data *__buffer, long *__result) ; + + +extern int mrand48_r (struct drand48_data *__buffer, long *__result) ; +extern int jrand48_r (unsigned short int __xsubi[3], + struct drand48_data *__buffer, long *__result) ; + + +extern int srand48_r (long __seedval, struct drand48_data *__buffer) ; +extern int seed48_r (unsigned short int __seed16v[3], + struct drand48_data *__buffer) ; +extern int lcong48_r (unsigned short int __param[7], + struct drand48_data *__buffer) ; + + + +extern int __drand48_iterate (unsigned short int __xsubi[3], + struct drand48_data *__buffer) ; + + + + +extern void * malloc (size_t __size) ; + + +extern void * realloc (void * __ptr, size_t __size) ; + +extern void * calloc (size_t __nmemb, size_t __size) ; + +extern void free (void * __ptr) ; + + + +extern void cfree (void * __ptr) ; + + + +# 1 "/usr/include/alloca.h" 1 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 1 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 1 3 + + + + + + + + +# 17 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + +# 59 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# 129 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + +# 180 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + +# 256 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + +# 288 "/usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/include/stddef.h" 3 + + + + + + + + + + + + + + + + + + + + + + + + +# 25 "/usr/include/alloca.h" 2 3 + + + + + + + + + +extern void * __alloca (size_t __size) ; +extern void * alloca (size_t __size) ; + + + + + + + + + +# 360 "/usr/include/stdlib.h" 2 3 + + + + + +extern void * valloc (size_t __size) ; + + + + +extern void abort (void) __attribute__ ((__noreturn__)); + + + +extern int atexit (void (*__func) (void)) ; + + + + +extern int __on_exit (void (*__func) (int __status, void * __arg), + void * __arg) ; +extern int on_exit (void (*__func) (int __status, void * __arg), + void * __arg) ; + + + + + +extern void exit (int __status) __attribute__ ((__noreturn__)); + + + +extern char *getenv (__const char *__name) ; + + + +extern char *__secure_getenv (__const char *__name) ; + + + + + +extern int putenv (__const char *__string) ; + + + + + +extern int setenv (__const char *__name, __const char *__value, + int __replace) ; + + +extern void unsetenv (__const char *__name) ; + + + + + + +extern int __clearenv (void) ; +extern int clearenv (void) ; + + + + + + + + +extern char *mktemp (char *__template) ; + + + + + + +extern int mkstemp (char *__template) ; + + + + +extern int system (__const char *__command) ; + + + + + + + + + + + + + + + + +extern char *realpath (__const char *__name, char *__resolved) ; + + + + + + +typedef int (*__compar_fn_t) (__const void * , __const void * ) ; + + + + + + + + +extern void * bsearch (__const void * __key, __const void * __base, + size_t __nmemb, size_t __size, + __compar_fn_t __compar) ; + + + +extern void qsort (void * __base, size_t __nmemb, size_t __size, + __compar_fn_t __compar) ; + + + +extern int abs (int __x) __attribute__ ((__const__)); +extern long int labs (long int __x) __attribute__ ((__const__)); + + + + + + + + +extern div_t div (int __numer, int __denom) __attribute__ ((__const__)); +extern ldiv_t ldiv (long int __numer, long int __denom) __attribute__ ((__const__)); + + + + + + + + + + + + +extern char *ecvt (double __value, int __ndigit, int *__decpt, + int *__sign) ; + + + + +extern char *fcvt (double __value, int __ndigit, int *__decpt, + int *__sign) ; + + + + +extern char *gcvt (double __value, int __ndigit, char *__buf) ; + + +extern char *qecvt (long double __value, int __ndigit, int *__decpt, + int *__sign) ; +extern char *qfcvt (long double __value, int __ndigit, int *__decpt, + int *__sign) ; +extern char *qgcvt (long double __value, int __ndigit, char *__buf) ; + + + + + +extern int ecvt_r (double __value, int __ndigit, int *__decpt, + int *__sign, char *__buf, size_t __len) ; +extern int fcvt_r (double __value, int __ndigit, int *__decpt, + int *__sign, char *__buf, size_t __len) ; + +extern int qecvt_r (long double __value, int __ndigit, int *__decpt, + int *__sign, char *__buf, size_t __len) ; +extern int qfcvt_r (long double __value, int __ndigit, int *__decpt, + int *__sign, char *__buf, size_t __len) ; + + + + + + +extern int mblen (__const char *__s, size_t __n) ; + + +extern int mbtowc (wchar_t *__pwc, __const char *__s, size_t __n) ; + + +extern int wctomb (char *__s, wchar_t __wchar) ; + + + +extern size_t mbstowcs (wchar_t *__pwcs, __const char *__s, size_t __n) ; + +extern size_t wcstombs (char *__s, __const wchar_t *__pwcs, size_t __n) ; + + + + + + + +extern int rpmatch (__const char *__response) ; + + + +# 582 "/usr/include/stdlib.h" 3 + + + + + + + + + + + + + +# 1 "t.c" 2 + +++ cat t.c +#include "fcntl.h" +#ifdef O_RDONLY +FOUND(); +#endif +++ make -f confMakefile t +FOUND(); +++ cat t.c +#include "string.h" +++ make -f confMakefile t +extern void * memset (void * __s, int __c, size_t __n) ; +++ cat t.c +#include "math.h" +++ make -f confMakefile t +extern double floor (double __x) ; extern double __floor (double __x) ; +++ cat t.c +#include "math.h" +++ make -f confMakefile t +extern double ceil (double __x) ; extern double __ceil (double __x) ; +++ cat t.c +#include "math.h" +++ make -f confMakefile t +extern double exp (double __x) ; extern double __exp (double __x) ; +extern double frexp (double __x, int *__exponent) ; extern double __frexp (double __x, int *__exponent) ; +extern double ldexp (double __x, int __exponent) ; extern double __ldexp (double __x, int __exponent) ; +++ cat t.c +#include "math.h" +++ make -f confMakefile t +extern double pow (double __x, double __y) ; extern double __pow (double __x, double __y) ; +++ cat t.c +#include "unistd.h" +++ make -f confMakefile t +extern ssize_t __read (int __fd, void * __buf, size_t __nbytes) ; +extern ssize_t read (int __fd, void * __buf, size_t __nbytes) ; +++ cat t.c +#include "stdlib.h" +++ make -f confMakefile t +extern void * malloc (size_t __size) ; +++ cat t.c +#include "stdlib.h" +++ make -f confMakefile t +extern void * realloc (void * __ptr, size_t __size) ; +++ cat t.c +#include "stdlib.h" +++ make -f confMakefile t +extern void free (void * __ptr) ; +extern void cfree (void * __ptr) ; +++ make -f confMakefile t +/usr/bin/gcc t.c -lm +++ make -f confMakefile t +/usr/bin/gcc t.c -lm +++ make -f confMakefile t +/usr/bin/gcc t.c -lm +++ make -f confMakefile t +/usr/bin/gcc t.c -limage +ld: cannot open -limage: No such file or directory +make: *** [t] Error 1 +++ make -f confMakefile t +/usr/bin/gcc t.c -lgl +ld: cannot open -lgl: No such file or directory +make: *** [t] Error 1 diff --git a/libtiff/Makefile b/libtiff/Makefile new file mode 100644 index 00000000..1c62c06e --- /dev/null +++ b/libtiff/Makefile @@ -0,0 +1,342 @@ +# $Header: /d1/sam/tiff/libtiff/RCS/Makefile.in,v 1.43 1997/08/29 22:47:50 sam Exp $ +# +# Tag Image File Format Library +# +# Copyright (c) 1988-1997 Sam Leffler +# Copyright (c) 1991-1997 Silicon Graphics, Inc. +# +# Permission to use, copy, modify, distribute, and sell this software and +# its documentation for any purpose is hereby granted without fee, provided +# that (i) the above copyright notices and this permission notice appear in +# all copies of the software and related documentation, and (ii) the names of +# Sam Leffler and Silicon Graphics may not be used in any advertising or +# publicity relating to the software without the specific, prior written +# permission of Sam Leffler and Silicon Graphics. +# +# THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, +# EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY +# WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. +# +# IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR +# ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, +# OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +# WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF +# LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE +# OF THIS SOFTWARE. +# + +SRCDIR = ../libtiff + +# +# VERSION: v3.4beta037 +# DATE: Wed Feb 3 19:53:27 EST 1999 +# TARGET: i586-unknown-linux +# CCOMPILER: /usr/bin/gcc +# +SHELL = /bin/sh +NULL = +CC = /usr/bin/gcc +AR = /usr/bin/ar +AROPTS = rc +RANLIB = /usr/bin/ranlib +INSTALL = ${SHELL} ../port/install.sh + +# +# If JPEG support is to be included and the Independent JPEG +# Software distribution is not installed then DIR_JPEG must +# refer to the directory where the include files reside. +# +# Similarly, if the libgz distribution is not installed, then +# DIR_LIBGZ must refer to the directory where the include files +# are located. Note that recent versions +# +IPATH = -I. -I${SRCDIR} +# +# To enable JPEG support include -DJPEG_SUPPORT here. +# To enable Deflate support add a -DZIP_SUPPORT here. +# Note that where the configure script is used these defines +# are automatically setup when JPEG/ZIP is set to "yes". +# +# Otherwise, consult tiffconf.h for information on controlling +# the configuration of optional library support. +# +CONF_LIBRARY= +COPTS = -g +OPTIMIZER=-O +CFLAGS = ${COPTS} ${OPTIMIZER} ${IPATH} ${CONF_LIBRARY} +# +SRCS = \ + tif_aux.c \ + tif_close.c \ + tif_codec.c \ + tif_compress.c \ + tif_dir.c \ + tif_dirinfo.c \ + tif_dirread.c \ + tif_dirwrite.c \ + tif_dumpmode.c \ + tif_error.c \ + tif_fax3.c \ + tif_fax3sm.c \ + tif_getimage.c \ + tif_jpeg.c \ + tif_flush.c \ + tif_luv.c \ + tif_lzw.c \ + tif_next.c \ + tif_open.c \ + tif_packbits.c \ + tif_pixarlog.c \ + tif_predict.c \ + tif_print.c \ + tif_read.c \ + tif_swab.c \ + tif_strip.c \ + tif_thunder.c \ + tif_tile.c \ + tif_unix.c \ + tif_version.c \ + tif_warning.c \ + tif_write.c \ + tif_zip.c \ + ${NULL} +OBJS = \ + tif_aux.o \ + tif_close.o \ + tif_codec.o \ + tif_compress.o \ + tif_dir.o \ + tif_dirinfo.o \ + tif_dirread.o \ + tif_dirwrite.o \ + tif_dumpmode.o \ + tif_error.o \ + tif_fax3.o \ + tif_fax3sm.o \ + tif_getimage.o \ + tif_jpeg.o \ + tif_flush.o \ + tif_luv.o \ + tif_lzw.o \ + tif_next.o \ + tif_open.o \ + tif_packbits.o \ + tif_pixarlog.o \ + tif_predict.o \ + tif_print.o \ + tif_read.o \ + tif_swab.o \ + tif_strip.o \ + tif_thunder.o \ + tif_tile.o \ + tif_unix.o \ + tif_version.o \ + tif_warning.o \ + tif_write.o \ + tif_zip.o \ + ${NULL} +TARGETS = libtiff.a + +all: ${TARGETS} + if [ nodso != nodso ]; then \ + ${MAKE} nodso; \ + else \ + true; \ + fi + +libtiff.a: ${OBJS} + ${AR} ${AROPTS} libtiff.a $? + ${RANLIB} libtiff.a + +# +# NB: The configure script verifies that the configured +# tools are capable of producing a DSO before enabling +# their creation/use. The following rules are effectively +# duplicated in the configure script to do this verification. +# This means that if you want to add support for building a +# DSO on another system you'll need to modify this file *and* +# configure if you want the right thing to happen automatically +# (should probably be fixed up). +# + +# default IRIX DSO building rule +IRIXdso: ${OBJS} + ${CC} -o libtiff.a -shared -rdata_shared \ + -check_registry ${SRCDIR}/../port/irix/so_locations \ + -quickstart_info \ + ${OBJS} + touch $@ +# special rule for IRIX 5.2 +IRIX52dso: ${OBJS} + ${LD} -elf -o libtiff.a -shared -no_unresolved -all ${OBJS} \ + -lc -lm + touch $@ +# Solaris 2.x +SOLARISdso: ${OBJS} + ${LD} -L/usr/local/lib -G -h libtiff.a -o libtiff.a ${OBJS} + touch $@ +# HP-UX A.09.03 +HPUXdso: ${OBJS} + ${LD} +b/usr/local/lib -b -o libtiff.a ${OBJS} + touch $@ +# AIX 2.3.5 and 4.1.1 +AIXdso: ${OBJS} + rm -f libtiff.syms shr.o + echo "#!" > libtiff.syms + /bin/dump -g libtiff.a | sed -n -e \ + 's/^[ ]*[0-9][0-9]*[ ]*\([^ .][^ ]*\)$$/\1/p' \ + >> libtiff.syms + ${LD} -o shr.o libtiff.a -H512 -T512 -bM\:SRE \ + -bE\:libtiff.syms -lc -lm -L/usr/local/lib + rm -f libtiff.syms libtiff.a + ${AR} ${AROPTS} libtiff.a shr.o + rm -f shr.o + touch $@ +# NetBSD 1.1 or FreeBSD +NETBSDdso FREEBSDdso: ${OBJS} + @rm -f libtiff_pic.a + @${AR} cq libtiff_pic.a `lorder ${OBJS} | tsort -q` + ${RANLIB} libtiff_pic.a + ${LD} -x -Bshareable -Bforcearchive -o libtiff.a libtiff_pic.a + rm -f libtiff_pic.a + touch $@ +# linux ELF shared lib rule +LINUXdso: ${OBJS} + ${CC} -shared -Wl,-soname,libtiff.a \ + -o libtiff.a ${OBJS} + /bin/ln -s libtiff.a libtiff.a + touch $@ +# OSF/1 3.2 shared lib rule +OSFdso: ${OBJS} + ${LD} -o libtiff.a -shared -error_unresolved ${OBJS} -lc -lm + + +${OBJS}: ${SRCDIR}/tiffio.h ${SRCDIR}/tiff.h ${SRCDIR}/tif_dir.h +${OBJS}: ${SRCDIR}/tiffcomp.h ${SRCDIR}/tiffiop.h ${SRCDIR}/tiffconf.h + +ALPHA = .././dist/tiff.alpha +VERSION = .././VERSION + +version.h: ${VERSION} ${ALPHA} ${SRCDIR}/mkversion.c + ${CC} -o mkversion ${CFLAGS} ${SRCDIR}/mkversion.c + rm -f version.h; ./mkversion -v ${VERSION} -a ${ALPHA} version.h +tif_version.o: version.h + +# +# The finite state machine tables used by the G3/G4 decoders +# are generated by the mkg3states program. On systems without +# make these rules have to be manually carried out. +# +tif_fax3sm.c: ${SRCDIR}/mkg3states.c ${SRCDIR}/tif_fax3.h + ${CC} -o mkg3states ${CFLAGS} ${SRCDIR}/mkg3states.c + rm -f tif_fax3sm.c; ./mkg3states -c const tif_fax3sm.c + +tif_aux.o: ${SRCDIR}/tif_aux.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_aux.c +tif_close.o: ${SRCDIR}/tif_close.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_close.c +tif_codec.o: ${SRCDIR}/tif_codec.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_codec.c +tif_compress.o: ${SRCDIR}/tif_compress.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_compress.c +tif_dir.o: ${SRCDIR}/tif_dir.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_dir.c +tif_dirinfo.o: ${SRCDIR}/tif_dirinfo.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_dirinfo.c +tif_dirread.o: ${SRCDIR}/tif_dirread.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_dirread.c +tif_dirwrite.o: ${SRCDIR}/tif_dirwrite.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_dirwrite.c +tif_dumpmode.o: ${SRCDIR}/tif_dumpmode.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_dumpmode.c +tif_error.o: ${SRCDIR}/tif_error.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_error.c +tif_fax3.o: ${SRCDIR}/tif_fax3.c ${SRCDIR}/t4.h ${SRCDIR}/tif_fax3.h + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_fax3.c +tif_getimage.o: ${SRCDIR}/tif_getimage.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_getimage.c +tif_jpeg.o: ${SRCDIR}/tif_jpeg.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_jpeg.c +tif_flush.o: ${SRCDIR}/tif_flush.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_flush.c +tif_luv.o: ${SRCDIR}/tif_luv.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_luv.c +tif_lzw.o: ${SRCDIR}/tif_lzw.c ${SRCDIR}/tif_predict.h + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_lzw.c +tif_next.o: ${SRCDIR}/tif_next.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_next.c +tif_open.o: ${SRCDIR}/tif_open.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_open.c +tif_packbits.o: ${SRCDIR}/tif_packbits.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_packbits.c +tif_pixarlog.o: ${SRCDIR}/tif_pixarlog.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_pixarlog.c +tif_predict.o: ${SRCDIR}/tif_predict.c ${SRCDIR}/tif_predict.h + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_predict.c +tif_print.o: ${SRCDIR}/tif_print.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_print.c +tif_read.o: ${SRCDIR}/tif_read.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_read.c +tif_swab.o: ${SRCDIR}/tif_swab.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_swab.c +tif_strip.o: ${SRCDIR}/tif_strip.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_strip.c +tif_thunder.o: ${SRCDIR}/tif_thunder.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_thunder.c +tif_tile.o: ${SRCDIR}/tif_tile.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_tile.c +tif_unix.o: ${SRCDIR}/tif_unix.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_unix.c +tif_version.o: ${SRCDIR}/tif_version.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_version.c +tif_warning.o: ${SRCDIR}/tif_warning.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_warning.c +tif_write.o: ${SRCDIR}/tif_write.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_write.c +tif_zip.o: ${SRCDIR}/tif_zip.c ${SRCDIR}/tif_predict.h + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_zip.c + +tif_apple.o: ${SRCDIR}/tif_apple.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_apple.c +tif_atari.o: ${SRCDIR}/tif_atari.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_atari.c +tif_msdos.o: ${SRCDIR}/tif_msdos.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_msdos.c +tif_vms.o: ${SRCDIR}/tif_vms.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_vms.c +tif_win3.o: ${SRCDIR}/tif_win3.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tif_win3.c + +INCS = ${SRCDIR}/tiff.h ${SRCDIR}/tiffio.h + +installHdrs: ${INCS} + ${INSTALL} -idb tiff.sw.dev -m 755 -dir /usr/local/include + for i in ${INCS}; do \ + f=`basename $$i`; \ + ${INSTALL} -idb tiff.sw.dev -m 444 -F /usr/local/include \ + -src $$i -O $$f; \ + done +installDSO: nodso + if [ a != a ]; then \ + ${INSTALL} -idb tiff.sw.tools -m 555 -F /usr/local/lib \ + -O libtiff.a; \ + ${INSTALL} -idb tiff.sw.tools -F /usr/local/lib \ + -ln libtiff.a -O libtiff.a; \ + else \ + ${INSTALL} -idb tiff.sw.tools -m 555 -F /usr/local/lib \ + -O libtiff.a; \ + fi +install: all installHdrs + ${INSTALL} -idb tiff.sw.dev -m 755 -dir /usr/local/lib + ${INSTALL} -idb tiff.sw.dev -m 444 -F /usr/local/lib -O libtiff.a + if [ nodso != nodso ]; then \ + ${MAKE} installDSO; \ + else \ + true; \ + fi + +clean: + rm -f ${TARGETS} ${OBJS} core a.out \ + mkg3states tif_fax3sm.c \ + mkversion version.h \ + libtiff.a libtiff.a libtiff.a *dso diff --git a/libtiff/mkversion.c b/libtiff/mkversion.c old mode 100755 new mode 100644 diff --git a/libtiff/port.h b/libtiff/port.h new file mode 100644 index 00000000..f1b841e3 --- /dev/null +++ b/libtiff/port.h @@ -0,0 +1,32 @@ +/* + * Warning, this file was automatically created by the TIFF configure script + * VERSION: v3.4beta037 + * DATE: Wed Feb 3 19:53:27 EST 1999 + * TARGET: i586-unknown-linux + * CCOMPILER: /usr/bin/gcc-2.7.2.3 + */ +#ifndef _PORT_ +#define _PORT_ 1 +#ifdef __cplusplus +extern "C" { +#endif +#include +#define HOST_FILLORDER FILLORDER_LSB2MSB +#define HOST_BIGENDIAN 0 +#define HAVE_MMAP 1 +#include +#include +#include +#include +#include +typedef double dblparam_t; +#ifdef __STRICT_ANSI__ +#define INLINE __inline__ +#else +#define INLINE inline +#endif +#define GLOBALDATA(TYPE,NAME) extern TYPE NAME +#ifdef __cplusplus +} +#endif +#endif diff --git a/libtiff/tif_acorn.c b/libtiff/tif_acorn.c old mode 100755 new mode 100644 diff --git a/libtiff/tif_dir.c b/libtiff/tif_dir.c index 63dea966..f8cc591a 100644 --- a/libtiff/tif_dir.c +++ b/libtiff/tif_dir.c @@ -423,6 +423,25 @@ _TIFFVSetField(TIFF* tif, ttag_t tag, va_list ap) _TIFFsetByteArray(&td->td_profileData, va_arg(ap, void*), td->td_profileLength); break; +#endif +#ifdef PHOTOSHOP_SUPPORT + case TIFFTAG_PHOTOSHOP: + td->td_photoshopLength = (uint32) va_arg(ap, uint32); + _TIFFsetByteArray (&td->td_photoshopData, va_arg(ap, void*), + td->td_photoshopLength); + break; +#endif +#ifdef IPTC_SUPPORT + case TIFFTAG_RICHTIFFIPTC: + td->td_richtiffiptcLength = (uint32) va_arg(ap, uint32); +#ifdef PHOTOSHOP_SUPPORT + _TIFFsetLongArray ((uint32**)&td->td_richtiffiptcData, va_arg(ap, uint32*), + td->td_richtiffiptcLength); +#else + _TIFFsetByteArray (&td->td_photoshopData, va_arg(ap, void*), + td->td_photoshopLength); +#endif + break; #endif default: /* @@ -751,6 +770,18 @@ _TIFFVGetField(TIFF* tif, ttag_t tag, va_list ap) *va_arg(ap, uint32*) = td->td_profileLength; *va_arg(ap, void**) = td->td_profileData; break; +#endif +#ifdef PHOTOSHOP_SUPPORT + case TIFFTAG_PHOTOSHOP: + *va_arg(ap, uint32*) = td->td_photoshopLength; + *va_arg(ap, void**) = td->td_photoshopData; + break; +#endif +#ifdef IPTC_SUPPORT + case TIFFTAG_RICHTIFFIPTC: + *va_arg(ap, uint32*) = td->td_richtiffiptcLength; + *va_arg(ap, void**) = td->td_richtiffiptcData; + break; #endif default: /* @@ -848,6 +879,12 @@ TIFFFreeDirectory(TIFF* tif) #endif #ifdef ICC_SUPPORT CleanupField(td_profileData); +#endif +#ifdef PHOTOSHOP_SUPPORT + CleanupField(td_photoshopData); +#endif +#ifdef IPTC_SUPPORT + CleanupField(td_richtiffiptcData); #endif CleanupField(td_stripoffset); CleanupField(td_stripbytecount); diff --git a/libtiff/tif_dir.h b/libtiff/tif_dir.h index 2a576249..3682a2f3 100644 --- a/libtiff/tif_dir.h +++ b/libtiff/tif_dir.h @@ -102,6 +102,14 @@ typedef struct { uint32 td_profileLength; void *td_profileData; #endif +#ifdef PHOTOSHOP_SUPPORT + uint32 td_photoshopLength; + void *td_photoshopData; +#endif +#ifdef IPTC_SUPPORT + uint32 td_richtiffiptcLength; + void *td_richtiffiptcData; +#endif } TIFFDirectory; /* @@ -174,9 +182,11 @@ typedef struct { #define FIELD_SUBIFD 49 #define FIELD_NUMBEROFINKS 50 #define FIELD_ICCPROFILE 51 -#define FIELD_STONITS 52 +#define FIELD_PHOTOSHOP 52 +#define FIELD_RICHTIFFIPTC 53 +#define FIELD_STONITS 54 /* end of support for well-known tags; codec-private tags follow */ -#define FIELD_CODEC 53 /* base of codec-private tags */ +#define FIELD_CODEC 55 /* base of codec-private tags */ /* * Pseudo-tags don't normally need field bits since they * are not written to an output file (by definition). diff --git a/libtiff/tif_dirinfo.c b/libtiff/tif_dirinfo.c index 9b716c2a..d7fed27c 100644 --- a/libtiff/tif_dirinfo.c +++ b/libtiff/tif_dirinfo.c @@ -216,6 +216,21 @@ static const TIFFFieldInfo tiffFieldInfo[] = { { TIFFTAG_TILEDEPTH, 1, 1, TIFF_SHORT, FIELD_TILEDEPTH, FALSE, FALSE, "TileDepth" }, /* end SGI tags */ +#ifdef IPTC_SUPPORT +#ifdef PHOTOSHOP_SUPPORT + { TIFFTAG_RICHTIFFIPTC, -1,-1, TIFF_LONG, FIELD_RICHTIFFIPTC, + FALSE, TRUE, "RichTIFFIPTC" }, +#else + { TIFFTAG_RICHTIFFIPTC, -1,-3, TIFF_UNDEFINED, FIELD_RICHTIFFIPTC, + FALSE, TRUE, "RichTIFFIPTC" }, +#endif +#endif +#ifdef PHOTOSHOP_SUPPORT + { TIFFTAG_PHOTOSHOP, -1,-3, TIFF_UNDEFINED, FIELD_PHOTOSHOP, + FALSE, TRUE, "Photoshop" }, + { TIFFTAG_PHOTOSHOP, -1,-1, TIFF_BYTE, FIELD_PHOTOSHOP, + FALSE, TRUE, "Photoshop" }, +#endif #ifdef ICC_SUPPORT { TIFFTAG_ICCPROFILE, -1,-3, TIFF_UNDEFINED, FIELD_ICCPROFILE, FALSE, TRUE, "ICC Profile" }, diff --git a/libtiff/tif_print.c b/libtiff/tif_print.c index 753ba6dc..b73706e5 100644 --- a/libtiff/tif_print.c +++ b/libtiff/tif_print.c @@ -419,6 +419,16 @@ TIFFPrintDirectory(TIFF* tif, FILE* fd, long flags) fprintf(fd, " ICC Profile: , %lu bytes\n", (u_long) td->td_profileLength); #endif +#ifdef PHOTOSHOP_SUPPORT + if (TIFFFieldSet(tif,FIELD_PHOTOSHOP)) + fprintf(fd, " Photoshop Data: , %lu bytes\n", + (u_long) td->td_photoshopLength); +#endif +#ifdef IPTC_SUPPORT + if (TIFFFieldSet(tif,FIELD_RICHTIFFIPTC)) + fprintf(fd, " RichTIFFIPTC Data: , %lu bytes\n", + (u_long) td->td_richtiffiptcLength); +#endif #if SUBIFD_SUPPORT if (TIFFFieldSet(tif, FIELD_SUBIFD)) { fprintf(fd, " SubIFD Offsets:"); diff --git a/libtiff/tiff.h b/libtiff/tiff.h index 49f05a98..5f540722 100644 --- a/libtiff/tiff.h +++ b/libtiff/tiff.h @@ -321,6 +321,8 @@ typedef enum { #define TIFFTAG_WRITERSERIALNUMBER 33405 /* device serial number */ /* tag 33432 is listed in the 6.0 spec w/ unknown ownership */ #define TIFFTAG_COPYRIGHT 33432 /* copyright string */ +/* IPTC TAG from RichTIFF specifications */ +#define TIFFTAG_RICHTIFFIPTC 33723 /* 34016-34029 are reserved for ANSI IT8 TIFF/IT $@ +# +# The following macros are used during the install step to generate +# the filenames of the target manual pages. They appear inside a +# shell for loop in a command of the form: +# +# f=${MAN*NAME} +# +# where the variable ``i'' contains the filename of the formatted +# manual page (formatted according to the MANCVT macro). +# +# MANAPPNAME generate installed app man page filename +# MANLIBNAME generate installed library man page filename +# +# +MANAPPNAME = $$i +MANLIBNAME = $$i + +# +# Set this up if your manual system requires a +# pathname prefix in the .so commands when setting +# up alternate files for multi-function manual pages. +# +#MANDIR = man3/ + +MANTOOLS=\ + apps/fax2tiff.1 \ + apps/fax2ps.1 \ + apps/gif2tiff.1 \ + apps/pal2rgb.1 \ + apps/ppm2tiff.1 \ + apps/ras2tiff.1 \ + apps/rgb2ycbcr.1 \ + apps/sgi2tiff.1 \ + apps/thumbnail.1 \ + apps/tiff2bw.1 \ + apps/tiff2ps.1 \ + apps/tiffcmp.1 \ + apps/tiffcp.1 \ + apps/tiffdither.1 \ + apps/tiffdump.1 \ + apps/tiffgt.1 \ + apps/tiffinfo.1 \ + apps/tiffmedian.1 \ + apps/tiffsplit.1 \ + apps/tiffsv.1 \ + ${NULL} +MANDEV=\ + lib/libtiff.3t \ + \ + lib/TIFFClose.3t \ + lib/TIFFError.3t \ + lib/TIFFFlush.3t \ + lib/TIFFGetField.3t \ + lib/TIFFOpen.3t \ + lib/TIFFPrintDirectory.3t \ + lib/TIFFReadDirectory.3t \ + lib/TIFFReadEncodedStrip.3t \ + lib/TIFFReadEncodedTile.3t \ + lib/TIFFReadRGBAImage.3t \ + lib/TIFFReadRawStrip.3t \ + lib/TIFFReadRawTile.3t \ + lib/TIFFReadScanline.3t \ + lib/TIFFReadTile.3t \ + lib/TIFFRGBAImage.3t \ + lib/TIFFSetDirectory.3t \ + lib/TIFFSetField.3t \ + lib/TIFFWarning.3t \ + lib/TIFFWriteDirectory.3t \ + lib/TIFFWriteEncodedStrip.3t \ + lib/TIFFWriteEncodedTile.3t \ + lib/TIFFWriteRawStrip.3t \ + lib/TIFFWriteRawTile.3t \ + lib/TIFFWriteScanline.3t \ + \ + lib/TIFFbuffer.3t \ + lib/TIFFcodec.3t \ + lib/TIFFmemory.3t \ + lib/TIFFquery.3t \ + lib/TIFFsize.3t \ + lib/TIFFstrip.3t \ + lib/TIFFswab.3t \ + lib/TIFFtile.3t \ + ${NULL} +MANDEVLINKS=\ + lib/TIFFmalloc.3t \ + lib/TIFFrealloc.3t \ + lib/TIFFfree.3t \ + lib/TIFFmemset.3t \ + lib/TIFFmemcpy.3t \ + lib/TIFFmemcmp.3t \ + lib/TIFFComputeTile.3t \ + lib/TIFFCheckTile.3t \ + lib/TIFFNumberOfTiles.3t \ + lib/TIFFComputeStrip.3t \ + lib/TIFFNumberOfStrips.3t \ + lib/TIFFCurrentDirectory.3t \ + lib/TIFFCurrentRow.3t \ + lib/TIFFCurrentStrip.3t \ + lib/TIFFCurrentTile.3t \ + lib/TIFFFdOpen.3t \ + lib/TIFFFileName.3t \ + lib/TIFFFileno.3t \ + lib/TIFFFindCODEC.3t \ + lib/TIFFFlushData.3t \ + lib/TIFFGetMode.3t \ + lib/TIFFIsTiled.3t \ + lib/TIFFIsByteSwapped.3t \ + lib/TIFFIsUpSampled.3t \ + lib/TIFFIsMSB2LSB.3t \ + lib/TIFFLastDirectory.3t \ + lib/TIFFRegisterCODEC.3t \ + lib/TIFFReverseBits.3t \ + lib/TIFFRGBAImageOK.3t \ + lib/TIFFRGBAImageBegin.3t \ + lib/TIFFRGBAImageGet.3t \ + lib/TIFFRGBAImageEnd.3t \ + lib/TIFFSetErrorHandler.3t \ + lib/TIFFSetSubDirectory.3t \ + lib/TIFFSetWarningHandler.3t \ + lib/TIFFSwabArrayOfLong.3t \ + lib/TIFFSwabArrayOfShort.3t \ + lib/TIFFSwabLong.3t \ + lib/TIFFSwabShort.3t \ + lib/TIFFScanlineSize.3t \ + lib/TIFFDefaultStripSize.3t \ + lib/TIFFVStripSize.3t \ + lib/TIFFStripSize.3t \ + lib/TIFFDefaultTileSize.3t \ + lib/TIFFVTileSize.3t \ + lib/TIFFTileSize.3t \ + lib/TIFFTileRowSize.3t \ + lib/TIFFUnRegisterCODEC.3t \ + lib/TIFFVGetField.3t \ + lib/TIFFVSetField.3t \ + lib/TIFFReadBufferSetup.3t \ + lib/TIFFWriteBufferSetup.3t \ + ${NULL} +TARGETS=apps/Makefile lib/Makefile + +# +# System-specific manual page formatting commands should +# apply this sed command to the manual page source before +# handing it to the formatter. This sets any pathnames +# in the man pages to reflect local conventions. +# +MANSED=${SED}\ + -e 's;\$${DIR_BIN};/usr/local/bin;g' \ + -e 's;\$${DIR_LIB};/usr/local/lib;g' \ + -e 's;\$${DIR_INC};/usr/local/include;g' \ + ${MANSEDLOCAL} + +all: ${TARGETS} + +apps/fax2tiff.1:: ${SRCDIR}/fax2tiff.1; ${MANCVT} +apps/fax2ps.1:: ${SRCDIR}/fax2ps.1; ${MANCVT} +apps/gif2tiff.1:: ${SRCDIR}/gif2tiff.1; ${MANCVT} +apps/pal2rgb.1:: ${SRCDIR}/pal2rgb.1; ${MANCVT} +apps/ppm2tiff.1:: ${SRCDIR}/ppm2tiff.1; ${MANCVT} +apps/ras2tiff.1:: ${SRCDIR}/ras2tiff.1; ${MANCVT} +apps/rgb2ycbcr.1:: ${SRCDIR}/rgb2ycbcr.1; ${MANCVT} +apps/sgi2tiff.1:: ${SRCDIR}/sgi2tiff.1; ${MANCVT} +apps/thumbnail.1:: ${SRCDIR}/thumbnail.1; ${MANCVT} +apps/tiff2bw.1:: ${SRCDIR}/tiff2bw.1; ${MANCVT} +apps/tiff2ps.1:: ${SRCDIR}/tiff2ps.1; ${MANCVT} +apps/tiffcmp.1:: ${SRCDIR}/tiffcmp.1; ${MANCVT} +apps/tiffcp.1:: ${SRCDIR}/tiffcp.1; ${MANCVT} +apps/tiffdither.1:: ${SRCDIR}/tiffdither.1; ${MANCVT} +apps/tiffdump.1:: ${SRCDIR}/tiffdump.1; ${MANCVT} +apps/tiffgt.1:: ${SRCDIR}/tiffgt.1; ${MANCVT} +apps/tiffinfo.1:: ${SRCDIR}/tiffinfo.1; ${MANCVT} +apps/tiffmedian.1:: ${SRCDIR}/tiffmedian.1; ${MANCVT} +apps/tiffsplit.1:: ${SRCDIR}/tiffsplit.1; ${MANCVT} +apps/tiffsv.1:: ${SRCDIR}/tiffsv.1; ${MANCVT} + +lib/libtiff.3t:: ${SRCDIR}/libtiff.3t; ${MANCVT} +lib/TIFFClose.3t:: ${SRCDIR}/TIFFClose.3t; ${MANCVT} +lib/TIFFError.3t:: ${SRCDIR}/TIFFError.3t; ${MANCVT} +lib/TIFFFlush.3t:: ${SRCDIR}/TIFFFlush.3t; ${MANCVT} +lib/TIFFGetField.3t:: ${SRCDIR}/TIFFGetField.3t; ${MANCVT} +lib/TIFFOpen.3t:: ${SRCDIR}/TIFFOpen.3t; ${MANCVT} +lib/TIFFPrintDirectory.3t:: ${SRCDIR}/TIFFPrintDirectory.3t; ${MANCVT} +lib/TIFFReadDirectory.3t:: ${SRCDIR}/TIFFReadDirectory.3t; ${MANCVT} +lib/TIFFReadEncodedStrip.3t:: ${SRCDIR}/TIFFReadEncodedStrip.3t;${MANCVT} +lib/TIFFReadEncodedTile.3t:: ${SRCDIR}/TIFFReadEncodedTile.3t; ${MANCVT} +lib/TIFFReadRGBAImage.3t:: ${SRCDIR}/TIFFReadRGBAImage.3t; ${MANCVT} +lib/TIFFReadRawStrip.3t:: ${SRCDIR}/TIFFReadRawStrip.3t; ${MANCVT} +lib/TIFFReadRawTile.3t:: ${SRCDIR}/TIFFReadRawTile.3t; ${MANCVT} +lib/TIFFReadScanline.3t:: ${SRCDIR}/TIFFReadScanline.3t; ${MANCVT} +lib/TIFFReadTile.3t:: ${SRCDIR}/TIFFReadTile.3t; ${MANCVT} +lib/TIFFRGBAImage.3t:: ${SRCDIR}/TIFFRGBAImage.3t; ${MANCVT} +lib/TIFFSetDirectory.3t:: ${SRCDIR}/TIFFSetDirectory.3t; ${MANCVT} +lib/TIFFSetField.3t:: ${SRCDIR}/TIFFSetField.3t; ${MANCVT} +lib/TIFFWarning.3t:: ${SRCDIR}/TIFFWarning.3t; ${MANCVT} +lib/TIFFWriteDirectory.3t:: ${SRCDIR}/TIFFWriteDirectory.3t; ${MANCVT} +lib/TIFFWriteEncodedStrip.3t:: ${SRCDIR}/TIFFWriteEncodedStrip.3t; ${MANCVT} +lib/TIFFWriteEncodedTile.3t:: ${SRCDIR}/TIFFWriteEncodedTile.3t; ${MANCVT} +lib/TIFFWriteRawStrip.3t:: ${SRCDIR}/TIFFWriteRawStrip.3t; ${MANCVT} +lib/TIFFWriteRawTile.3t:: ${SRCDIR}/TIFFWriteRawTile.3t; ${MANCVT} +lib/TIFFWriteScanline.3t:: ${SRCDIR}/TIFFWriteScanline.3t; ${MANCVT} +lib/TIFFbuffer.3t:: ${SRCDIR}/TIFFbuffer.3t; ${MANCVT} +lib/TIFFcodec.3t:: ${SRCDIR}/TIFFcodec.3t; ${MANCVT} +lib/TIFFmemory.3t:: ${SRCDIR}/TIFFmemory.3t; ${MANCVT} +lib/TIFFquery.3t:: ${SRCDIR}/TIFFquery.3t; ${MANCVT} +lib/TIFFsize.3t:: ${SRCDIR}/TIFFsize.3t; ${MANCVT} +lib/TIFFstrip.3t:: ${SRCDIR}/TIFFstrip.3t; ${MANCVT} +lib/TIFFswab.3t:: ${SRCDIR}/TIFFswab.3t; ${MANCVT} +lib/TIFFtile.3t:: ${SRCDIR}/TIFFtile.3t; ${MANCVT} + +lib/TIFFComputeTile.3t:; ${ECHO} ".so ${MANDIR}TIFFtile.3t" > $@ +lib/TIFFCheckTile.3t:; ${ECHO} ".so ${MANDIR}TIFFtile.3t" > $@ +lib/TIFFNumberOfTiles.3t:; ${ECHO} ".so ${MANDIR}TIFFtile.3t" > $@ +lib/TIFFComputeStrip.3t:; ${ECHO} ".so ${MANDIR}TIFFstrip.3t" > $@ +lib/TIFFNumberOfStrips.3t:; ${ECHO} ".so ${MANDIR}TIFFstrip.3t" > $@ +lib/TIFFCurrentDirectory.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFCurrentRow.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFCurrentStrip.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFCurrentTile.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFFdOpen.3t:; ${ECHO} ".so ${MANDIR}TIFFOpen.3t" > $@ +lib/TIFFFileName.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFFileno.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFFlushData.3t:; ${ECHO} ".so ${MANDIR}TIFFFlush.3t" > $@ +lib/TIFFGetMode.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFIsTiled.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFIsByteSwapped.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFIsUpSampled.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFIsMSB2LSB.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFLastDirectory.3t:; ${ECHO} ".so ${MANDIR}TIFFquery.3t" > $@ +lib/TIFFReverseBits.3t:; ${ECHO} ".so ${MANDIR}TIFFswab.3t" > $@ +lib/TIFFRGBAImageOK.3t:; ${ECHO} ".so ${MANDIR}TIFFRGBAImage.3t" > $@ +lib/TIFFRGBAImageBegin.3t:; ${ECHO} ".so ${MANDIR}TIFFRGBAImage.3t" > $@ +lib/TIFFRGBAImageGet.3t:; ${ECHO} ".so ${MANDIR}TIFFRGBAImage.3t" > $@ +lib/TIFFRGBAImageEnd.3t:; ${ECHO} ".so ${MANDIR}TIFFRGBAImage.3t" > $@ +lib/TIFFSetErrorHandler.3t:; ${ECHO} ".so ${MANDIR}TIFFError.3t" > $@ +lib/TIFFSetSubDirectory.3t:; ${ECHO} ".so ${MANDIR}TIFFSetDirectory.3t" > $@ +lib/TIFFSetWarningHandler.3t:; ${ECHO} ".so ${MANDIR}TIFFWarning.3t" > $@ +lib/TIFFSwabArrayOfLong.3t:; ${ECHO} ".so ${MANDIR}TIFFswab.3t" > $@ +lib/TIFFSwabArrayOfShort.3t:; ${ECHO} ".so ${MANDIR}TIFFswab.3t" > $@ +lib/TIFFSwabLong.3t:; ${ECHO} ".so ${MANDIR}TIFFswab.3t" > $@ +lib/TIFFSwabShort.3t:; ${ECHO} ".so ${MANDIR}TIFFswab.3t" > $@ +lib/TIFFScanlineSize.3t:; ${ECHO} ".so ${MANDIR}TIFFsize.3t" > $@ +lib/TIFFRasterScanlineSize.3t:; ${ECHO} ".so ${MANDIR}TIFFsize.3t" > $@ +lib/TIFFDefaultStripSize.3t:; ${ECHO} ".so ${MANDIR}TIFFstrip.3t" > $@ +lib/TIFFStripSize.3t:; ${ECHO} ".so ${MANDIR}TIFFstrip.3t" > $@ +lib/TIFFVStripSize.3t:; ${ECHO} ".so ${MANDIR}TIFFstrip.3t" > $@ +lib/TIFFTileSize.3t:; ${ECHO} ".so ${MANDIR}TIFFtile.3t" > $@ +lib/TIFFVTileSize.3t:; ${ECHO} ".so ${MANDIR}TIFFtile.3t" > $@ +lib/TIFFDefaultTileSize.3t:; ${ECHO} ".so ${MANDIR}TIFFtile.3t" > $@ +lib/TIFFTileRowSize.3t:; ${ECHO} ".so ${MANDIR}TIFFtile.3t" > $@ +lib/TIFFVGetField.3t:; ${ECHO} ".so ${MANDIR}TIFFGetField.3t" > $@ +lib/TIFFVSetField.3t:; ${ECHO} ".so ${MANDIR}TIFFSetField.3t" > $@ +lib/TIFFFindCODEC.3t:; ${ECHO} ".so ${MANDIR}TIFFcodec.3t" > $@ +lib/TIFFRegisterCODEC.3t:; ${ECHO} ".so ${MANDIR}TIFFcodec.3t" > $@ +lib/TIFFUnRegisterCODEC.3t:; ${ECHO} ".so ${MANDIR}TIFFcodec.3t" > $@ +lib/TIFFmalloc.3t:; ${ECHO} ".so ${MANDIR}TIFFmemory.3t" > $@ +lib/TIFFrealloc.3t:; ${ECHO} ".so ${MANDIR}TIFFmemory.3t" > $@ +lib/TIFFfree.3t:; ${ECHO} ".so ${MANDIR}TIFFmemory.3t" > $@ +lib/TIFFmemset.3t:; ${ECHO} ".so ${MANDIR}TIFFmemory.3t" > $@ +lib/TIFFmemcpy.3t:; ${ECHO} ".so ${MANDIR}TIFFmemory.3t" > $@ +lib/TIFFmemcmp.3t:; ${ECHO} ".so ${MANDIR}TIFFmemory.3t" > $@ +lib/TIFFReadBufferSetup.3t:; ${ECHO} ".so ${MANDIR}TIFFbuffer.3t" > $@ +lib/TIFFWriteBufferSetup.3t:; ${ECHO} ".so ${MANDIR}TIFFbuffer.3t" > $@ + +apps/Makefile: + test -d apps || mkdir apps + ${MAKE} ${MANTOOLS} + ${RM} apps/Makefile + (cd apps; \ + ${ECHO} 'install:'; \ + for i in *.1; do \ + f=${MANAPPNAME}; \ + ${ECHO} ' cd ..; ${INSTALL} -m 444 -F ${MAN}/${MANAPPS} \ + -idb tiff.man.tools -src' apps/"$$i" '-O' "$$f"; \ + done \ + )>apps/Makefile +lib/Makefile: + test -d lib || mkdir lib + ${MAKE} ${MANDEV} ${MANDEVLINKS} + ${RM} lib/Makefile + (cd lib; \ + ${ECHO} 'install:'; \ + for i in *.3t; do \ + f=${MANLIBNAME}; \ + ${ECHO} ' cd ..; ${INSTALL} -m 444 -F ${MAN}/${MANLIB} \ + -idb tiff.man.dev -src' lib/"$$i" '-O' "$$f"; \ + done \ + )>lib/Makefile + +install: all + ${INSTALL} -m 755 -dir -idb tiff.man.tools ${MAN} + ${INSTALL} -m 755 -dir -idb tiff.man.tools ${MAN}/${MANAPPS} + cd apps; ${MAKE} install + ${INSTALL} -m 755 -dir -idb tiff.man.dev ${MAN}/${MANLIB} + cd lib; ${MAKE} install + +clean: + rm -rf apps lib + +# +# Miscellaneous junk left over... +# + +links: ${MANDEVLINKS} + +short: + ${MV} TIFFClose.3t close.3t + ${MV} TIFFError.3t error.3t + ${MV} TIFFFlush.3t flush.3t + ${MV} TIFFGetField.3t getfield.3t + ${MV} TIFFOpen.3t open.3t + ${MV} TIFFPrintDirectory.3t print.3t + ${MV} TIFFReadEncodedStrip.3t rdestrip.3t + ${MV} TIFFReadencodedTile.3t rdetile.3t + ${MV} TIFFReadRawStrip.3t rdrstrip.3t + ${MV} TIFFReadRawTile.3t rdrtile.3t + ${MV} TIFFReadDirectory.3t readdir.3t + ${MV} TIFFReadRGBAImage.3t rdimage.3t + ${MV} TIFFReadScanline.3t readline.3t + ${MV} TIFFReadTile.3t readtile.3t + ${MV} TIFFRGBAImage.3t rgbaimage.3t + ${MV} TIFFSetDirectory.3t setdir.3t + ${MV} TIFFSetField.3t setfield.3t + ${MV} TIFFWarning.3t warning.3t + ${MV} TIFFWriteEncodedStrip.3t wrestrip.3t + ${MV} TIFFWriteEncodedTile.3t wretile.3t + ${MV} TIFFWriteDirectory.3t writedir.3t + ${MV} TIFFWriteRawStrip.3t wrrstrip.3t + ${MV} TIFFWriteRawTile.3t wrrtile.3t + ${MV} TIFFWriteScanline.3t writeline.3t + ${MV} TIFFtile.3t tile.3t + ${MV} TIFFstrip.3t strip.3t + ${MV} TIFFquery.3t query.3t + ${MV} TIFFswab.3t swab.3t + ${MV} TIFFsize.3t size.3t + ${MV} TIFFcodec.3t codec.3t + ${MV} TIFFmemory.3t memory.3t + ${MV} TIFFbuffer.3t buffer.3t diff --git a/port/install.sh b/port/install.sh new file mode 100644 index 00000000..fc423669 --- /dev/null +++ b/port/install.sh @@ -0,0 +1,246 @@ +#! /bin/sh +# $Header: /d1/sam/tiff/port/RCS/install.sh.in,v 1.20 1997/08/29 21:48:53 sam Exp $ +# +# Warning, this file was automatically created by the TIFF configure script +# +# HylaFAX Facsimile Software +# +# Copyright (c) 1990-1997 Sam Leffler +# Copyright (c) 1991-1997 Silicon Graphics, Inc. +# HylaFAX is a trademark of Silicon Graphics +# +# Permission to use, copy, modify, distribute, and sell this software and +# its documentation for any purpose is hereby granted without fee, provided +# that (i) the above copyright notices and this permission notice appear in +# all copies of the software and related documentation, and (ii) the names of +# Sam Leffler and Silicon Graphics may not be used in any advertising or +# publicity relating to the software without the specific, prior written +# permission of Sam Leffler and Silicon Graphics. +# +# THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, +# EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY +# WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. +# +# IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR +# ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, +# OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +# WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF +# LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE +# OF THIS SOFTWARE. +# + +# +# Warning, this file was automatically created by the HylaFAX configure script +# +# VERSION: v3.4beta037 +# DATE: Wed Feb 3 19:53:27 EST 1999 +# TARGET: i586-unknown-linux +# + +# +# Shell script to emulate Silicon Graphics install program. +# We emulate the non-standard interface used by install so +# that we can build SGI inst packages on SGI systems. Note +# that we cannot emulate everything because we don't maintain +# a history of installed software; thus we cannot tell when +# configuration files have been modified and save old copies. +# +# NB: we don't do chown/chmod/chgrp by default; it must be +# explicitly set on the command line. +# + +# +# install [options] files ... +# +# Options are: +# +# -o save existing target foo as OLDfoo +# -O remove existing target foo, if it fails save as OLDfoo +# -m mode set mode of installed target +# -u uid set uid of installed target +# -g gid set gid of installed target +# -root path set ROOT directory for target pathnames +# -dir create directories +# -fifo create FIFO special files +# -ln path create hard link +# -lns path create symbolic link +# -src path source pathname different from target +# -f dir install files in the target directory ROOT/dir +# -F dir like -f, but create directories that do not exist +# -v echo actions +# -idb stuff specify package and, optionally, do special work +# +preopts= +postopts= +SaveFirst=no +HasSource=yes +RemoveFirst=no +NoUpdate=no +Suggested=no +Updated=no + +CMD=cp +SRC= +FILES= +DESTDIR= +CHMOD=":" +CHOWN=":" +CHGRP=":" +RM="rm -f" +MV="mv -f" +ECHO=echo +VERBOSE=":" +STRIP="/usr/bin/strip" +CMP=cmp + +TARGETS= +while [ x"$1" != x ] +do + arg=$1 + case $arg in + -m) shift; CHMOD="/bin/chmod $1";; + -u) shift; CHOWN="@CHOWN@ $1";; + -g) shift; CHGRP="@CHGRP@ $1";; + -o) SaveFirst=yes;; + -O) RemoveFirst=yes; SaveFirst=yes;; + -root) shift; ROOT=$1;; + -dir) CMD=mkdir; HasSource=no; + RM=":"; STRIP=":" + ;; + -fifo) CMD=@MKFIFO@; HasSource=no; + x=`echo $CMD | /bin/sed 's;.*/;;'`; + test $x = mknod && postopts="p"; + STRIP=":" + ;; + -ln) shift; CMD=/bin/ln; SRC="$1" + STRIP=":" + ;; + -lns) shift; CMD=/bin/ln; preopts="-s"; SRC="$1" + STRIP=":" + ;; + -src) shift; SRC="$1";; + -[fF]) shift; DESTDIR="$1";; + -idb) shift; opt="$1" + case "$opt" in + *config\(update\)*) Updated=yes;; + *config\(suggest\)*) Suggested=yes;; + *config\(noupdate\)*) NoUpdate=yes;; + *nostrip*) STRIP=":";; + esac + ;; + # these are skipped/not handled + -new|-rawidb|-blk|-chr) shift;; + -v) VERBOSE=$ECHO;; + -*) ;; + *) TARGETS="$TARGETS $arg";; + esac + shift +done + +# +# Install the specified target. +# +install() +{ + src=$1 target=$2 + if [ $RemoveFirst = yes -a -f $target ]; then + $VERBOSE "$RM $target" + $RM $target + fi + if [ $SaveFirst = yes -a -f $target ]; then + bf=`echo $src | /bin/sed 's;.*/;;'` + $VERBOSE "$MV $target $ROOT/$DESTDIR/OLD$bf" + $MV $target $ROOT/$DESTDIR/OLD$bf + fi + if [ -z "$SRC" -a $HasSource = yes ]; then + $VERBOSE "$CMD $preopts $src $target $postopts" + $CMD $preopts $f $target $postopts + else + $VERBOSE "$CMD $preopts $SRC $target $postopts" + $CMD $preopts $SRC $target $postopts + fi + if [ $? -eq 0 ]; then + $VERBOSE "$CHOWN $target" + $CHOWN $target + $VERBOSE "$CHGRP $target" + $CHGRP $target + $VERBOSE "$CHMOD $target" + $CHMOD $target + if [ $STRIP != ":" -a -x $ROOT/$DESTDIR/$f ]; then + $STRIP $target >/dev/null 2>&1 || true + $VERBOSE "$STRIP $target" + fi + fi +} + +if [ $Suggested = yes ]; then + # + # A suggested file. If an existing target does + # not exist, then install it. Otherwise, install + # it as target.N if it's different from the current + # installed target. + # + # NB: cannot be used with a special file 'cuz we + # use test -f to see if the file exists. + # + for f in $TARGETS; do + t=$ROOT/$DESTDIR/$f + if [ -f $t ]; then + if [ -z "$SRC" -a $HasSource = yes ]; then + $CMP -s $f $t || { + $ECHO "*** Warning, target has local changes, installing $f as $t.N" + install $f $t.N; + } + else + $CMP -s $SRC $t || { + $ECHO "*** Warning, target has local changes, installing $f as $t.N" + install $f $t.N + } + fi + else + install $f $t + fi + done +elif [ $Updated = yes ]; then + # + # A file to be updated. If an existing target does + # not exist, then install it. Otherwise, install + # it as target and save the old version as target.O + # if the old version is different from the current + # installed target. + # + # NB: cannot be used with a special file 'cuz we + # use test -f to see if the file exists. + # + for f in $TARGETS; do + t=$ROOT/$DESTDIR/$f + if [ -f $t ]; then + if [ -z "$SRC" -a $HasSource = yes ]; then + $CMP -s $f $t || $MV $t $t.O + else + $CMP -s $SRC $t || $MV $t $t.O + fi + fi + install $f $t + done +elif [ $NoUpdate = yes ]; then + # + # A file that is never to be updated; the target + # is created only if it does not exist. + # + # NB: cannot be used with a special file 'cuz we + # use test -f to see if the file exists. + # + for f in $TARGETS; do + t=$ROOT/$DESTDIR/$f + test -f $t || install $f $t + done +else + # + # Normal case, a target that should be installed + # with the existing copy, optionally, saved first. + # + for f in $TARGETS; do + install $f $ROOT/$DESTDIR/$f + done +fi diff --git a/tiff.h b/tiff.h new file mode 100644 index 00000000..394cd50d --- /dev/null +++ b/tiff.h @@ -0,0 +1,421 @@ +/* $Header: /d1/sam/tiff/libtiff/RCS/tiff.h,v 1.78 1997/08/29 21:45:38 sam Exp $ */ + +/* + * Copyright (c) 1988-1997 Sam Leffler + * Copyright (c) 1991-1997 Silicon Graphics, Inc. + * + * Permission to use, copy, modify, distribute, and sell this software and + * its documentation for any purpose is hereby granted without fee, provided + * that (i) the above copyright notices and this permission notice appear in + * all copies of the software and related documentation, and (ii) the names of + * Sam Leffler and Silicon Graphics may not be used in any advertising or + * publicity relating to the software without the specific, prior written + * permission of Sam Leffler and Silicon Graphics. + * + * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, + * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY + * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. + * + * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR + * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, + * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF + * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THIS SOFTWARE. + */ + +#ifndef _TIFF_ +#define _TIFF_ +/* + * Tag Image File Format (TIFF) + * + * Based on Rev 6.0 from: + * Developer's Desk + * Aldus Corporation + * 411 First Ave. South + * Suite 200 + * Seattle, WA 98104 + * 206-622-5500 + */ +#define TIFF_VERSION 42 + +#define TIFF_BIGENDIAN 0x4d4d +#define TIFF_LITTLEENDIAN 0x4949 + +#ifndef _TIFF_DATA_TYPEDEFS_ +#define _TIFF_DATA_TYPEDEFS_ +/* + * Intrinsic data types required by the file format: + * + * 8-bit quantities int8/uint8 + * 16-bit quantities int16/uint16 + * 32-bit quantities int32/uint32 + * strings unsigned char* + */ +#ifdef __STDC__ +typedef signed char int8; /* NB: non-ANSI compilers may not grok */ +#else +typedef char int8; +#endif +typedef unsigned char uint8; +typedef short int16; +typedef unsigned short uint16; /* sizeof (uint16) must == 2 */ +#if defined(__alpha) || (defined(_MIPS_SZLONG) && _MIPS_SZLONG == 64) +typedef int int32; +typedef unsigned int uint32; /* sizeof (uint32) must == 4 */ +#else +typedef long int32; +typedef unsigned long uint32; /* sizeof (uint32) must == 4 */ +#endif +#endif /* _TIFF_DATA_TYPEDEFS_ */ + +typedef struct { + uint16 tiff_magic; /* magic number (defines byte order) */ + uint16 tiff_version; /* TIFF version number */ + uint32 tiff_diroff; /* byte offset to first directory */ +} TIFFHeader; + +/* + * TIFF Image File Directories are comprised of + * a table of field descriptors of the form shown + * below. The table is sorted in ascending order + * by tag. The values associated with each entry + * are disjoint and may appear anywhere in the file + * (so long as they are placed on a word boundary). + * + * If the value is 4 bytes or less, then it is placed + * in the offset field to save space. If the value + * is less than 4 bytes, it is left-justified in the + * offset field. + */ +typedef struct { + uint16 tdir_tag; /* see below */ + uint16 tdir_type; /* data type; see below */ + uint32 tdir_count; /* number of items; length in spec */ + uint32 tdir_offset; /* byte offset to field data */ +} TIFFDirEntry; + +/* + * NB: In the comments below, + * - items marked with a + are obsoleted by revision 5.0, + * - items marked with a ! are introduced in revision 6.0. + * - items marked with a % are introduced post revision 6.0. + * - items marked with a $ are obsoleted by revision 6.0. + */ + +/* + * Tag data type information. + * + * Note: RATIONALs are the ratio of two 32-bit integer values. + */ +typedef enum { + TIFF_NOTYPE = 0, /* placeholder */ + TIFF_BYTE = 1, /* 8-bit unsigned integer */ + TIFF_ASCII = 2, /* 8-bit bytes w/ last byte null */ + TIFF_SHORT = 3, /* 16-bit unsigned integer */ + TIFF_LONG = 4, /* 32-bit unsigned integer */ + TIFF_RATIONAL = 5, /* 64-bit unsigned fraction */ + TIFF_SBYTE = 6, /* !8-bit signed integer */ + TIFF_UNDEFINED = 7, /* !8-bit untyped data */ + TIFF_SSHORT = 8, /* !16-bit signed integer */ + TIFF_SLONG = 9, /* !32-bit signed integer */ + TIFF_SRATIONAL = 10, /* !64-bit signed fraction */ + TIFF_FLOAT = 11, /* !32-bit IEEE floating point */ + TIFF_DOUBLE = 12 /* !64-bit IEEE floating point */ +} TIFFDataType; + +/* + * TIFF Tag Definitions. + */ +#define TIFFTAG_SUBFILETYPE 254 /* subfile data descriptor */ +#define FILETYPE_REDUCEDIMAGE 0x1 /* reduced resolution version */ +#define FILETYPE_PAGE 0x2 /* one page of many */ +#define FILETYPE_MASK 0x4 /* transparency mask */ +#define TIFFTAG_OSUBFILETYPE 255 /* +kind of data in subfile */ +#define OFILETYPE_IMAGE 1 /* full resolution image data */ +#define OFILETYPE_REDUCEDIMAGE 2 /* reduced size image data */ +#define OFILETYPE_PAGE 3 /* one page of many */ +#define TIFFTAG_IMAGEWIDTH 256 /* image width in pixels */ +#define TIFFTAG_IMAGELENGTH 257 /* image height in pixels */ +#define TIFFTAG_BITSPERSAMPLE 258 /* bits per channel (sample) */ +#define TIFFTAG_COMPRESSION 259 /* data compression technique */ +#define COMPRESSION_NONE 1 /* dump mode */ +#define COMPRESSION_CCITTRLE 2 /* CCITT modified Huffman RLE */ +#define COMPRESSION_CCITTFAX3 3 /* CCITT Group 3 fax encoding */ +#define COMPRESSION_CCITTFAX4 4 /* CCITT Group 4 fax encoding */ +#define COMPRESSION_LZW 5 /* Lempel-Ziv & Welch */ +#define COMPRESSION_OJPEG 6 /* !6.0 JPEG */ +#define COMPRESSION_JPEG 7 /* %JPEG DCT compression */ +#define COMPRESSION_NEXT 32766 /* NeXT 2-bit RLE */ +#define COMPRESSION_CCITTRLEW 32771 /* #1 w/ word alignment */ +#define COMPRESSION_PACKBITS 32773 /* Macintosh RLE */ +#define COMPRESSION_THUNDERSCAN 32809 /* ThunderScan RLE */ +/* codes 32895-32898 are reserved for ANSI IT8 TIFF/IT */ +#define COMPRESSION_DCS 32947 /* Kodak DCS encoding */ +#define COMPRESSION_JBIG 34661 /* ISO JBIG */ +#define COMPRESSION_SGILOG 34676 /* SGI Log Luminance RLE */ +#define COMPRESSION_SGILOG24 34677 /* SGI Log 24-bit packed */ +#define TIFFTAG_PHOTOMETRIC 262 /* photometric interpretation */ +#define PHOTOMETRIC_MINISWHITE 0 /* min value is white */ +#define PHOTOMETRIC_MINISBLACK 1 /* min value is black */ +#define PHOTOMETRIC_RGB 2 /* RGB color model */ +#define PHOTOMETRIC_PALETTE 3 /* color map indexed */ +#define PHOTOMETRIC_MASK 4 /* $holdout mask */ +#define PHOTOMETRIC_SEPARATED 5 /* !color separations */ +#define PHOTOMETRIC_YCBCR 6 /* !CCIR 601 */ +#define PHOTOMETRIC_CIELAB 8 /* !1976 CIE L*a*b* */ +#define PHOTOMETRIC_LOGL 32844 /* CIE Log2(L) */ +#define PHOTOMETRIC_LOGLUV 32845 /* CIE Log2(L) (u',v') */ +#define TIFFTAG_THRESHHOLDING 263 /* +thresholding used on data */ +#define THRESHHOLD_BILEVEL 1 /* b&w art scan */ +#define THRESHHOLD_HALFTONE 2 /* or dithered scan */ +#define THRESHHOLD_ERRORDIFFUSE 3 /* usually floyd-steinberg */ +#define TIFFTAG_CELLWIDTH 264 /* +dithering matrix width */ +#define TIFFTAG_CELLLENGTH 265 /* +dithering matrix height */ +#define TIFFTAG_FILLORDER 266 /* data order within a byte */ +#define FILLORDER_MSB2LSB 1 /* most significant -> least */ +#define FILLORDER_LSB2MSB 2 /* least significant -> most */ +#define TIFFTAG_DOCUMENTNAME 269 /* name of doc. image is from */ +#define TIFFTAG_IMAGEDESCRIPTION 270 /* info about image */ +#define TIFFTAG_MAKE 271 /* scanner manufacturer name */ +#define TIFFTAG_MODEL 272 /* scanner model name/number */ +#define TIFFTAG_STRIPOFFSETS 273 /* offsets to data strips */ +#define TIFFTAG_ORIENTATION 274 /* +image orientation */ +#define ORIENTATION_TOPLEFT 1 /* row 0 top, col 0 lhs */ +#define ORIENTATION_TOPRIGHT 2 /* row 0 top, col 0 rhs */ +#define ORIENTATION_BOTRIGHT 3 /* row 0 bottom, col 0 rhs */ +#define ORIENTATION_BOTLEFT 4 /* row 0 bottom, col 0 lhs */ +#define ORIENTATION_LEFTTOP 5 /* row 0 lhs, col 0 top */ +#define ORIENTATION_RIGHTTOP 6 /* row 0 rhs, col 0 top */ +#define ORIENTATION_RIGHTBOT 7 /* row 0 rhs, col 0 bottom */ +#define ORIENTATION_LEFTBOT 8 /* row 0 lhs, col 0 bottom */ +#define TIFFTAG_SAMPLESPERPIXEL 277 /* samples per pixel */ +#define TIFFTAG_ROWSPERSTRIP 278 /* rows per strip of data */ +#define TIFFTAG_STRIPBYTECOUNTS 279 /* bytes counts for strips */ +#define TIFFTAG_MINSAMPLEVALUE 280 /* +minimum sample value */ +#define TIFFTAG_MAXSAMPLEVALUE 281 /* +maximum sample value */ +#define TIFFTAG_XRESOLUTION 282 /* pixels/resolution in x */ +#define TIFFTAG_YRESOLUTION 283 /* pixels/resolution in y */ +#define TIFFTAG_PLANARCONFIG 284 /* storage organization */ +#define PLANARCONFIG_CONTIG 1 /* single image plane */ +#define PLANARCONFIG_SEPARATE 2 /* separate planes of data */ +#define TIFFTAG_PAGENAME 285 /* page name image is from */ +#define TIFFTAG_XPOSITION 286 /* x page offset of image lhs */ +#define TIFFTAG_YPOSITION 287 /* y page offset of image lhs */ +#define TIFFTAG_FREEOFFSETS 288 /* +byte offset to free block */ +#define TIFFTAG_FREEBYTECOUNTS 289 /* +sizes of free blocks */ +#define TIFFTAG_GRAYRESPONSEUNIT 290 /* $gray scale curve accuracy */ +#define GRAYRESPONSEUNIT_10S 1 /* tenths of a unit */ +#define GRAYRESPONSEUNIT_100S 2 /* hundredths of a unit */ +#define GRAYRESPONSEUNIT_1000S 3 /* thousandths of a unit */ +#define GRAYRESPONSEUNIT_10000S 4 /* ten-thousandths of a unit */ +#define GRAYRESPONSEUNIT_100000S 5 /* hundred-thousandths */ +#define TIFFTAG_GRAYRESPONSECURVE 291 /* $gray scale response curve */ +#define TIFFTAG_GROUP3OPTIONS 292 /* 32 flag bits */ +#define GROUP3OPT_2DENCODING 0x1 /* 2-dimensional coding */ +#define GROUP3OPT_UNCOMPRESSED 0x2 /* data not compressed */ +#define GROUP3OPT_FILLBITS 0x4 /* fill to byte boundary */ +#define TIFFTAG_GROUP4OPTIONS 293 /* 32 flag bits */ +#define GROUP4OPT_UNCOMPRESSED 0x2 /* data not compressed */ +#define TIFFTAG_RESOLUTIONUNIT 296 /* units of resolutions */ +#define RESUNIT_NONE 1 /* no meaningful units */ +#define RESUNIT_INCH 2 /* english */ +#define RESUNIT_CENTIMETER 3 /* metric */ +#define TIFFTAG_PAGENUMBER 297 /* page numbers of multi-page */ +#define TIFFTAG_COLORRESPONSEUNIT 300 /* $color curve accuracy */ +#define COLORRESPONSEUNIT_10S 1 /* tenths of a unit */ +#define COLORRESPONSEUNIT_100S 2 /* hundredths of a unit */ +#define COLORRESPONSEUNIT_1000S 3 /* thousandths of a unit */ +#define COLORRESPONSEUNIT_10000S 4 /* ten-thousandths of a unit */ +#define COLORRESPONSEUNIT_100000S 5 /* hundred-thousandths */ +#define TIFFTAG_TRANSFERFUNCTION 301 /* !colorimetry info */ +#define TIFFTAG_SOFTWARE 305 /* name & release */ +#define TIFFTAG_DATETIME 306 /* creation date and time */ +#define TIFFTAG_ARTIST 315 /* creator of image */ +#define TIFFTAG_HOSTCOMPUTER 316 /* machine where created */ +#define TIFFTAG_PREDICTOR 317 /* prediction scheme w/ LZW */ +#define TIFFTAG_WHITEPOINT 318 /* image white point */ +#define TIFFTAG_PRIMARYCHROMATICITIES 319 /* !primary chromaticities */ +#define TIFFTAG_COLORMAP 320 /* RGB map for pallette image */ +#define TIFFTAG_HALFTONEHINTS 321 /* !highlight+shadow info */ +#define TIFFTAG_TILEWIDTH 322 /* !rows/data tile */ +#define TIFFTAG_TILELENGTH 323 /* !cols/data tile */ +#define TIFFTAG_TILEOFFSETS 324 /* !offsets to data tiles */ +#define TIFFTAG_TILEBYTECOUNTS 325 /* !byte counts for tiles */ +#define TIFFTAG_BADFAXLINES 326 /* lines w/ wrong pixel count */ +#define TIFFTAG_CLEANFAXDATA 327 /* regenerated line info */ +#define CLEANFAXDATA_CLEAN 0 /* no errors detected */ +#define CLEANFAXDATA_REGENERATED 1 /* receiver regenerated lines */ +#define CLEANFAXDATA_UNCLEAN 2 /* uncorrected errors exist */ +#define TIFFTAG_CONSECUTIVEBADFAXLINES 328 /* max consecutive bad lines */ +#define TIFFTAG_SUBIFD 330 /* subimage descriptors */ +#define TIFFTAG_INKSET 332 /* !inks in separated image */ +#define INKSET_CMYK 1 /* !cyan-magenta-yellow-black */ +#define TIFFTAG_INKNAMES 333 /* !ascii names of inks */ +#define TIFFTAG_NUMBEROFINKS 334 /* !number of inks */ +#define TIFFTAG_DOTRANGE 336 /* !0% and 100% dot codes */ +#define TIFFTAG_TARGETPRINTER 337 /* !separation target */ +#define TIFFTAG_EXTRASAMPLES 338 /* !info about extra samples */ +#define EXTRASAMPLE_UNSPECIFIED 0 /* !unspecified data */ +#define EXTRASAMPLE_ASSOCALPHA 1 /* !associated alpha data */ +#define EXTRASAMPLE_UNASSALPHA 2 /* !unassociated alpha data */ +#define TIFFTAG_SAMPLEFORMAT 339 /* !data sample format */ +#define SAMPLEFORMAT_UINT 1 /* !unsigned integer data */ +#define SAMPLEFORMAT_INT 2 /* !signed integer data */ +#define SAMPLEFORMAT_IEEEFP 3 /* !IEEE floating point data */ +#define SAMPLEFORMAT_VOID 4 /* !untyped data */ +#define TIFFTAG_SMINSAMPLEVALUE 340 /* !variable MinSampleValue */ +#define TIFFTAG_SMAXSAMPLEVALUE 341 /* !variable MaxSampleValue */ +#define TIFFTAG_JPEGTABLES 347 /* %JPEG table stream */ +/* + * Tags 512-521 are obsoleted by Technical Note #2 + * which specifies a revised JPEG-in-TIFF scheme. + */ +#define TIFFTAG_JPEGPROC 512 /* !JPEG processing algorithm */ +#define JPEGPROC_BASELINE 1 /* !baseline sequential */ +#define JPEGPROC_LOSSLESS 14 /* !Huffman coded lossless */ +#define TIFFTAG_JPEGIFOFFSET 513 /* !pointer to SOI marker */ +#define TIFFTAG_JPEGIFBYTECOUNT 514 /* !JFIF stream length */ +#define TIFFTAG_JPEGRESTARTINTERVAL 515 /* !restart interval length */ +#define TIFFTAG_JPEGLOSSLESSPREDICTORS 517 /* !lossless proc predictor */ +#define TIFFTAG_JPEGPOINTTRANSFORM 518 /* !lossless point transform */ +#define TIFFTAG_JPEGQTABLES 519 /* !Q matrice offsets */ +#define TIFFTAG_JPEGDCTABLES 520 /* !DCT table offsets */ +#define TIFFTAG_JPEGACTABLES 521 /* !AC coefficient offsets */ +#define TIFFTAG_YCBCRCOEFFICIENTS 529 /* !RGB -> YCbCr transform */ +#define TIFFTAG_YCBCRSUBSAMPLING 530 /* !YCbCr subsampling factors */ +#define TIFFTAG_YCBCRPOSITIONING 531 /* !subsample positioning */ +#define YCBCRPOSITION_CENTERED 1 /* !as in PostScript Level 2 */ +#define YCBCRPOSITION_COSITED 2 /* !as in CCIR 601-1 */ +#define TIFFTAG_REFERENCEBLACKWHITE 532 /* !colorimetry info */ +/* tags 32952-32956 are private tags registered to Island Graphics */ +#define TIFFTAG_REFPTS 32953 /* image reference points */ +#define TIFFTAG_REGIONTACKPOINT 32954 /* region-xform tack point */ +#define TIFFTAG_REGIONWARPCORNERS 32955 /* warp quadrilateral */ +#define TIFFTAG_REGIONAFFINE 32956 /* affine transformation mat */ +/* tags 32995-32999 are private tags registered to SGI */ +#define TIFFTAG_MATTEING 32995 /* $use ExtraSamples */ +#define TIFFTAG_DATATYPE 32996 /* $use SampleFormat */ +#define TIFFTAG_IMAGEDEPTH 32997 /* z depth of image */ +#define TIFFTAG_TILEDEPTH 32998 /* z depth/data tile */ +/* tags 33300-33309 are private tags registered to Pixar */ +/* + * TIFFTAG_PIXAR_IMAGEFULLWIDTH and TIFFTAG_PIXAR_IMAGEFULLLENGTH + * are set when an image has been cropped out of a larger image. + * They reflect the size of the original uncropped image. + * The TIFFTAG_XPOSITION and TIFFTAG_YPOSITION can be used + * to determine the position of the smaller image in the larger one. + */ +#define TIFFTAG_PIXAR_IMAGEFULLWIDTH 33300 /* full image size in x */ +#define TIFFTAG_PIXAR_IMAGEFULLLENGTH 33301 /* full image size in y */ +/* tag 33405 is a private tag registered to Eastman Kodak */ +#define TIFFTAG_WRITERSERIALNUMBER 33405 /* device serial number */ +/* tag 33432 is listed in the 6.0 spec w/ unknown ownership */ +#define TIFFTAG_COPYRIGHT 33432 /* copyright string */ +/* IPTC TAG from RichTIFF specifications */ +#define TIFFTAG_RICHTIFFIPTC 33723 +/* 34016-34029 are reserved for ANSI IT8 TIFF/IT */ +#define TIFFTAG_STONITS 37439 /* Sample value to Nits */ +/* tag 34929 is a private tag registered to FedEx */ +#define TIFFTAG_FEDEX_EDR 34929 /* unknown use */ +/* tag 65535 is an undefined tag used by Eastman Kodak */ +#define TIFFTAG_DCSHUESHIFTVALUES 65535 /* hue shift correction data */ + +/* + * The following are ``pseudo tags'' that can be + * used to control codec-specific functionality. + * These tags are not written to file. Note that + * these values start at 0xffff+1 so that they'll + * never collide with Aldus-assigned tags. + * + * If you want your private pseudo tags ``registered'' + * (i.e. added to this file), send mail to sam@sgi.com + * with the appropriate C definitions to add. + */ +#define TIFFTAG_FAXMODE 65536 /* Group 3/4 format control */ +#define FAXMODE_CLASSIC 0x0000 /* default, include RTC */ +#define FAXMODE_NORTC 0x0001 /* no RTC at end of data */ +#define FAXMODE_NOEOL 0x0002 /* no EOL code at end of row */ +#define FAXMODE_BYTEALIGN 0x0004 /* byte align row */ +#define FAXMODE_WORDALIGN 0x0008 /* word align row */ +#define FAXMODE_CLASSF FAXMODE_NORTC /* TIFF Class F */ +#define TIFFTAG_JPEGQUALITY 65537 /* Compression quality level */ +/* Note: quality level is on the IJG 0-100 scale. Default value is 75 */ +#define TIFFTAG_JPEGCOLORMODE 65538 /* Auto RGB<=>YCbCr convert? */ +#define JPEGCOLORMODE_RAW 0x0000 /* no conversion (default) */ +#define JPEGCOLORMODE_RGB 0x0001 /* do auto conversion */ +#define TIFFTAG_JPEGTABLESMODE 65539 /* What to put in JPEGTables */ +#define JPEGTABLESMODE_QUANT 0x0001 /* include quantization tbls */ +#define JPEGTABLESMODE_HUFF 0x0002 /* include Huffman tbls */ +/* Note: default is JPEGTABLESMODE_QUANT | JPEGTABLESMODE_HUFF */ +#define TIFFTAG_FAXFILLFUNC 65540 /* G3/G4 fill function */ +#define TIFFTAG_PIXARLOGDATAFMT 65549 /* PixarLogCodec I/O data sz */ +#define PIXARLOGDATAFMT_8BIT 0 /* regular u_char samples */ +#define PIXARLOGDATAFMT_8BITABGR 1 /* ABGR-order u_chars */ +#define PIXARLOGDATAFMT_11BITLOG 2 /* 11-bit log-encoded (raw) */ +#define PIXARLOGDATAFMT_12BITPICIO 3 /* as per PICIO (1.0==2048) */ +#define PIXARLOGDATAFMT_16BIT 4 /* signed short samples */ +#define PIXARLOGDATAFMT_FLOAT 5 /* IEEE float samples */ +/* 65550-65556 are allocated to Oceana Matrix */ +#define TIFFTAG_DCSIMAGERTYPE 65550 /* imager model & filter */ +#define DCSIMAGERMODEL_M3 0 /* M3 chip (1280 x 1024) */ +#define DCSIMAGERMODEL_M5 1 /* M5 chip (1536 x 1024) */ +#define DCSIMAGERMODEL_M6 2 /* M6 chip (3072 x 2048) */ +#define DCSIMAGERFILTER_IR 0 /* infrared filter */ +#define DCSIMAGERFILTER_MONO 1 /* monochrome filter */ +#define DCSIMAGERFILTER_CFA 2 /* color filter array */ +#define DCSIMAGERFILTER_OTHER 3 /* other filter */ +#define TIFFTAG_DCSINTERPMODE 65551 /* interpolation mode */ +#define DCSINTERPMODE_NORMAL 0x0 /* whole image, default */ +#define DCSINTERPMODE_PREVIEW 0x1 /* preview of image (384x256) */ +#define TIFFTAG_DCSBALANCEARRAY 65552 /* color balance values */ +#define TIFFTAG_DCSCORRECTMATRIX 65553 /* color correction values */ +#define TIFFTAG_DCSGAMMA 65554 /* gamma value */ +#define TIFFTAG_DCSTOESHOULDERPTS 65555 /* toe & shoulder points */ +#define TIFFTAG_DCSCALIBRATIONFD 65556 /* calibration file desc */ +/* Note: quality level is on the ZLIB 1-9 scale. Default value is -1 */ +#define TIFFTAG_ZIPQUALITY 65557 /* compression quality level */ +#define TIFFTAG_PIXARLOGQUALITY 65558 /* PixarLog uses same scale */ +/* 65559 is allocated to Oceana Matrix */ +#define TIFFTAG_DCSCLIPRECTANGLE 65559 /* area of image to acquire */ +#define TIFFTAG_SGILOGDATAFMT 65560 /* SGILog user data format */ +#define SGILOGDATAFMT_FLOAT 0 /* IEEE float samples */ +#define SGILOGDATAFMT_16BIT 1 /* 16-bit samples */ +#define SGILOGDATAFMT_RAW 2 /* uninterpreted data */ +#define SGILOGDATAFMT_8BIT 3 /* 8-bit RGB monitor values */ +#endif /* _TIFF_ */ diff --git a/tools/Makefile b/tools/Makefile new file mode 100644 index 00000000..2a56411d --- /dev/null +++ b/tools/Makefile @@ -0,0 +1,251 @@ +# $Header: /d1/sam/tiff/tools/RCS/Makefile.in,v 1.22 1997/08/29 21:46:45 sam Exp $ +# +# Warning, this file was automatically created by the TIFF configure script +# +# TIFF Library Tools +# +# Copyright (c) 1988-1997 Sam Leffler +# Copyright (c) 1991-1997 Silicon Graphics, Inc. +# +# Permission to use, copy, modify, distribute, and sell this software and +# its documentation for any purpose is hereby granted without fee, provided +# that (i) the above copyright notices and this permission notice appear in +# all copies of the software and related documentation, and (ii) the names of +# Sam Leffler and Silicon Graphics may not be used in any advertising or +# publicity relating to the software without the specific, prior written +# permission of Stanford and Silicon Graphics. +# +# THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, +# EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY +# WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. +# +# IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR +# ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, +# OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +# WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF +# LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE +# OF THIS SOFTWARE. +# +DEPTH = .. + +SRCDIR = ../tools +LIBDIR = ../libtiff + +# +# VERSION: v3.4beta037 +# DATE: Wed Feb 3 19:53:27 EST 1999 +# TARGET: i586-unknown-linux +# CCOMPILER: /usr/bin/gcc +# +SHELL = /bin/sh +NULL = +CC = /usr/bin/gcc +INSTALL = ${SHELL} ../port/install.sh +# +COPTS = -g +OPTIMIZER=-O +IPATH = -I. -I${SRCDIR} -I${LIBDIR} +CFLAGS = ${COPTS} ${OPTIMIZER} ${IPATH} +# +TIFFLIB = ${DEPTH}/libtiff/libtiff.a +LIBJPEG = +LIBGZ = +LIBTIFF = ${DEPTH}/libtiff/libtiff.a +LIBPORT = +MACHLIBS= -lm +LIBS = ${LIBTIFF} ${LIBJPEG} ${LIBGZ} ${LIBPORT} ${MACHLIBS} +# +OBJS= \ + fax2tiff.o \ + fax2ps.o \ + gif2tiff.o \ + pal2rgb.o \ + ppm2tiff.o \ + rgb2ycbcr.o \ + ras2tiff.o \ + thumbnail.o \ + tiff2bw.o \ + tiff2ps.o \ + tiffcmp.o \ + tiffcp.o \ + tiffdither.o \ + tiffdump.o \ + tiffinfo.o \ + tiffmedian.o \ + tiffsplit.o \ + ${NULL} +TARGETS =\ + fax2tiff \ + fax2ps \ + gif2tiff \ + pal2rgb \ + ppm2tiff \ + rgb2ycbcr \ + thumbnail \ + ras2tiff \ + tiff2bw \ + tiff2ps \ + tiffcmp \ + tiffcp \ + tiffdither \ + tiffdump \ + tiffinfo \ + tiffmedian \ + tiffsplit \ + ${NULL} + +all: ${TARGETS} + @if [ "no" = yes ]; then \ + ${MAKE} sgi2tiff; \ + else \ + true; \ + fi + @if [ "no" = yes ]; then \ + ${MAKE} tiffgt tiffsv; \ + else \ + true; \ + fi +install: all + ${INSTALL} -idb tiff.sw.tools -m 755 -dir /usr/local/bin + ${INSTALL} -idb tiff.sw.tools -m 755 -F /usr/local/bin -O ${TARGETS} + @if [ "no" = yes ]; then \ + ${INSTALL} -idb tiff.sw.tools -m 755 -F /usr/local/bin -O sgi2tiff; \ + else \ + true; \ + fi + @if [ "no" = yes ]; then \ + ${INSTALL} -idb tiff.sw.tools -m 755 -F /usr/local/bin -O tiffgt tiffsv;\ + else \ + true; \ + fi +clean: + rm -f ${TARGETS} ${OBJS} sgigt.o tiffgt sgisv.o tiffsv \ + sgi2tiff.o sgi2tiff core a.out ycbcr + +# +# System-independent tools +# + +tiffinfo: tiffinfo.o ${TIFFLIB} + ${CC} -o tiffinfo ${CFLAGS} tiffinfo.o ${LIBS} +tiffinfo.o: ${SRCDIR}/tiffinfo.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiffinfo.c + +tiffcmp:tiffcmp.o ${TIFFLIB} + ${CC} -o tiffcmp ${CFLAGS} tiffcmp.o ${LIBS} +tiffcmp.o: ${SRCDIR}/tiffcmp.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiffcmp.c + +tiffcp: tiffcp.o ${TIFFLIB} + ${CC} -o tiffcp ${CFLAGS} tiffcp.o ${LIBS} +tiffcp.o: ${SRCDIR}/tiffcp.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiffcp.c + +tiffdump: tiffdump.o + ${CC} -o tiffdump ${CFLAGS} tiffdump.o ${LIBS} +tiffdump.o: ${SRCDIR}/tiffdump.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiffdump.c + +tiffmedian: tiffmedian.o ${TIFFLIB} + ${CC} -o tiffmedian ${CFLAGS} tiffmedian.o ${LIBS} +tiffmedian.o: ${SRCDIR}/tiffmedian.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiffmedian.c + +tiffsplit: tiffsplit.o ${TIFFLIB} + ${CC} -o tiffsplit ${CFLAGS} tiffsplit.o ${LIBS} +tiffsplit.o: ${SRCDIR}/tiffsplit.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiffsplit.c + +tiff2ps: tiff2ps.o ${TIFFLIB} + ${CC} -o tiff2ps ${CFLAGS} tiff2ps.o ${LIBS} +tiff2ps.o: ${SRCDIR}/tiff2ps.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiff2ps.c + +# +# Junky stuff... programs that are more examples of how +# to use the library than full-blown useful tools. +# + +# convert RGB image to B&W +tiff2bw: tiff2bw.o ${TIFFLIB} + ${CC} -o tiff2bw ${CFLAGS} tiff2bw.o ${LIBS} +tiff2bw.o: ${SRCDIR}/tiff2bw.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiff2bw.c + +# convert B&W image to bilevel w/ FS dithering +tiffdither: tiffdither.o ${TIFFLIB} + ${CC} -o tiffdither ${CFLAGS} tiffdither.o ${LIBS} +tiffdither.o: ${SRCDIR}/tiffdither.c + ${CC} -c ${CFLAGS} ${SRCDIR}/tiffdither.c + +# simple Sun rasterfile converter +ras2tiff: ras2tiff.o ${TIFFLIB} + ${CC} -o ras2tiff ${CFLAGS} ras2tiff.o ${LIBS} +ras2tiff.o: ${SRCDIR}/ras2tiff.c + ${CC} -c ${CFLAGS} ${SRCDIR}/ras2tiff.c + +# simple GIF converter +gif2tiff: gif2tiff.o ${TIFFLIB} + ${CC} -o gif2tiff ${CFLAGS} gif2tiff.o ${LIBS} +gif2tiff.o: ${SRCDIR}/gif2tiff.c + ${CC} -c ${CFLAGS} ${SRCDIR}/gif2tiff.c + +# very limited PBM converter +ppm2tiff: ppm2tiff.o ${TIFFLIB} + ${CC} -o ppm2tiff ${CFLAGS} ppm2tiff.o ${LIBS} +ppm2tiff.o: ${SRCDIR}/ppm2tiff.c + ${CC} -c ${CFLAGS} ${SRCDIR}/ppm2tiff.c + +# Group 3/4 FAX file converter +fax2tiff: fax2tiff.o ${TIFFLIB} + ${CC} -o fax2tiff ${CFLAGS} fax2tiff.o ${LIBS} +fax2tiff.o: ${SRCDIR}/fax2tiff.c + ${CC} -c -I${LIBDIR} -I${DEPTH}/libtiff ${CFLAGS} ${SRCDIR}/fax2tiff.c + +# Group 3/4 FAX to encoded PS converter +fax2ps: fax2ps.o ${TIFFLIB} + ${CC} -o fax2ps ${CFLAGS} fax2ps.o ${LIBS} +fax2ps.o: ${SRCDIR}/fax2ps.c + ${CC} -c ${CFLAGS} ${SRCDIR}/fax2ps.c + +# convert Palette image to RGB +pal2rgb: pal2rgb.o ${TIFFLIB} + ${CC} -o pal2rgb ${CFLAGS} pal2rgb.o ${LIBS} +pal2rgb.o: ${SRCDIR}/pal2rgb.c + ${CC} -c ${CFLAGS} ${SRCDIR}/pal2rgb.c + +# convert RGB image to YCbCr +rgb2ycbcr: rgb2ycbcr.o ${TIFFLIB} + ${CC} -o rgb2ycbcr ${CFLAGS} rgb2ycbcr.o ${LIBS} +rgb2ycbcr.o: ${SRCDIR}/rgb2ycbcr.c + ${CC} -c ${CFLAGS} ${SRCDIR}/rgb2ycbcr.c + +# generate thumbnail images from fax (example of SubIFD usage) +thumbnail: thumbnail.o ${TIFFLIB} + ${CC} -o thumbnail ${CFLAGS} thumbnail.o ${LIBS} +thumbnail.o: ${SRCDIR}/thumbnail.c + ${CC} -c ${CFLAGS} ${SRCDIR}/thumbnail.c + +# +# System-specific tools. +# + +# +# sgi2tiff converts SGI RGB images to TIFF; it requires +# the SGI image library -limage. +# +sgi2tiff: sgi2tiff.o ${TIFFLIB} + ${CC} -o sgi2tiff ${CFLAGS} sgi2tiff.o -limage ${LIBS} +sgi2tiff.o: ${SRCDIR}/sgi2tiff.c + ${CC} -c ${CFLAGS} ${SRCDIR}/sgi2tiff.c + +# SGI versions of tiffgt & tiffsv that require -lgl +tiffgt: sgigt.o ${TIFFLIB} + ${CC} -o tiffgt ${CFLAGS} sgigt.o -lgutil -lgl ${LIBS} +sgigt.o: ${SRCDIR}/sgigt.c + ${CC} -c ${CFLAGS} ${SRCDIR}/sgigt.c + +tiffsv: sgisv.o ${TIFFLIB} + ${CC} -o tiffsv ${CFLAGS} sgisv.o -lgutil -lgl ${LIBS} +sgisv.o: ${SRCDIR}/sgisv.c + ${CC} -c ${CFLAGS} ${SRCDIR}/sgisv.c -- cgit v1.2.1