Commits

Anonymous committed 4f31a0c

- sync to 1.8.3

Comments (0)

Files changed (3)

 #for your system. 
 AR=ar
 
-#If the install command is not in your path, provide
-#an explicit path for it here, or install manually.
-INSTALL=install
-
 #If you don't have FreeType, libjpeg and/or Xpm installed, including the
 #header files, uncomment this (default).
 CFLAGS=-O
 #If you do have FreeType, libjpeg and/or Xpm fully installed, uncomment a
 #variation of this and comment out the line above. See also LIBS below.
-#CFLAGS=-O -DHAVE_XPM -DHAVE_JPEG -DHAVE_LIBTTF
+#CFLAGS=-O  -DHAVE_XPM -DHAVE_JPEG -DHAVE_LIBTTF
 
 #If you don't have FreeType and/or Xpm fully installed, uncomment this
 #(default).
+
+#PLEASE NOTE: YOU MAY HAVE TO JUGGLE THE ORDER OF THE LIBRARIES.
+#Some systems are very picky about link order. They don't all agree
+#on the right order, either.
+
 LIBS=-lm -lgd -lpng -lz
 
 #If you do have FreeType, JPEG and/or Xpm fully installed, uncomment a 
 #variation of this and comment out the line above. Note that
 #Xpm requires X11. See also CFLAGS above.
+
+#PLEASE NOTE: YOU MAY HAVE TO JUGGLE THE ORDER OF THE LIBRARIES.
+#Some systems are very picky about link order. They don't all agree
+#on the right order, either.
+
 #LIBS=-lm -lgd -lpng -lz -ljpeg -lttf -lXpm -lX11
 
 #Typical install locations for freetype, zlib, xpm, libjpeg and libpng header files.
 #If yours are somewhere else, change this. 
-INCLUDEDIRS=-I/usr/local/include -I/usr/include/X11 -I/usr/X11R6/include/X11
+#-I. is important to ensure that the version of gd you are installing
+#is used, and not an older release in your directory tree somewhere.
+
+INCLUDEDIRS=-I. -I/usr/local/include -I/usr/include/X11 -I/usr/X11R6/include/X11
 
 #Typical install locations for freetype, zlib, xpm and libpng libraries.
 #If yours are somewhere else, other than a standard location
 #
 #
 
-VERSION=1.7
+VERSION=1.8.1
 
 CC=$(COMPILER) $(INCLUDEDIRS)
 LINK=$(CC) $(LIBDIRS) $(LIBS)
 all: libgd.a $(PROGRAMS)
 
 install: libgd.a $(BIN_PROGRAMS)
-	$(INSTALL) -m 644 libgd.a $(INSTALL_LIB)/libgd.a
-	$(INSTALL) -m 755 pngtogd $(INSTALL_BIN)/pngtogd
-	$(INSTALL) -m 755 pngtogd2 $(INSTALL_BIN)/pngtogd2
-	$(INSTALL) -m 755 gdtopng $(INSTALL_BIN)/gdtopng
-	$(INSTALL) -m 755 gd2topng $(INSTALL_BIN)/gd2topng
-	$(INSTALL) -m 755 gd2copypal $(INSTALL_BIN)/gd2copypal
-	$(INSTALL) -m 755 gdparttopng $(INSTALL_BIN)/gdparttopng
-	$(INSTALL) -m 755 webpng $(INSTALL_BIN)/webpng
-	$(INSTALL) -m 755 bdftogd $(INSTALL_BIN)/bdftogd
-	$(INSTALL) -m 644 gd.h $(INSTALL_INCLUDE)/gd.h
-	$(INSTALL) -m 644 gdcache.h $(INSTALL_INCLUDE)/gdcache.h
-	$(INSTALL) -m 644 gd_io.h $(INSTALL_INCLUDE)/gd_io.h
-	$(INSTALL) -m 644 gdfontg.h $(INSTALL_INCLUDE)/gdfontg.h
-	$(INSTALL) -m 644 gdfontl.h $(INSTALL_INCLUDE)/gdfontl.h
-	$(INSTALL) -m 644 gdfontmb.h $(INSTALL_INCLUDE)/gdfontmb.h
-	$(INSTALL) -m 644 gdfonts.h $(INSTALL_INCLUDE)/gdfonts.h
-	$(INSTALL) -m 644 gdfontt.h $(INSTALL_INCLUDE)/gdfontt.h
+	sh ./install-item 644 libgd.a $(INSTALL_LIB)/libgd.a
+	sh ./install-item 755 pngtogd $(INSTALL_BIN)/pngtogd
+	sh ./install-item 755 pngtogd2 $(INSTALL_BIN)/pngtogd2
+	sh ./install-item 755 gdtopng $(INSTALL_BIN)/gdtopng
+	sh ./install-item 755 gd2topng $(INSTALL_BIN)/gd2topng
+	sh ./install-item 755 gd2copypal $(INSTALL_BIN)/gd2copypal
+	sh ./install-item 755 gdparttopng $(INSTALL_BIN)/gdparttopng
+	sh ./install-item 755 webpng $(INSTALL_BIN)/webpng
+	sh ./install-item 755 bdftogd $(INSTALL_BIN)/bdftogd
+	sh ./install-item 644 gd.h $(INSTALL_INCLUDE)/gd.h
+	sh ./install-item 644 gdcache.h $(INSTALL_INCLUDE)/gdcache.h
+	sh ./install-item 644 gd_io.h $(INSTALL_INCLUDE)/gd_io.h
+	sh ./install-item 644 gdfontg.h $(INSTALL_INCLUDE)/gdfontg.h
+	sh ./install-item 644 gdfontl.h $(INSTALL_INCLUDE)/gdfontl.h
+	sh ./install-item 644 gdfontmb.h $(INSTALL_INCLUDE)/gdfontmb.h
+	sh ./install-item 644 gdfonts.h $(INSTALL_INCLUDE)/gdfonts.h
+	sh ./install-item 644 gdfontt.h $(INSTALL_INCLUDE)/gdfontt.h
 
 gddemo: gddemo.o libgd.a
 	$(CC) gddemo.o -o gddemo	$(LIBDIRS) $(LIBS)
 
 libgd.a: gd.o gd_gd.o gd_gd2.o gd_io.o gd_io_dp.o gd_io_file.o gd_ss.o \
 	gd_io_ss.o gd_png.o gd_jpeg.o gdxpm.o gdfontt.o gdfonts.o gdfontmb.o gdfontl.o \
-	gdfontg.o gdtables.o gdttf.o gdcache.o gdkanji.o \
+	gdfontg.o gdtables.o gdttf.o gdcache.o gdkanji.o  wbmp.o gd_wbmp.o \
 	gd.h gdfontt.h gdfonts.h gdfontmb.h gdfontl.h gdfontg.h
 	rm -f libgd.a
 	$(AR) rc libgd.a gd.o gd_gd.o gd_gd2.o gd_io.o gd_io_dp.o \
 		gd_io_file.o gd_ss.o gd_io_ss.o gd_png.o gd_jpeg.o gdxpm.o \
 		gdfontt.o gdfonts.o gdfontmb.o gdfontl.o gdfontg.o \
-		gdtables.o gdttf.o gdcache.o gdkanji.o
+		gdtables.o gdttf.o gdcache.o gdkanji.o wbmp.o gd_wbmp.o
 	-ranlib libgd.a
 
 clean:
-	rm -f *.o *.a ${PROGRAMS}
+	rm -f *.o *.a ${PROGRAMS} test/gdtest.jpg test/gdtest.wbmp
 
 <HTML>
 <HEAD>
-<TITLE>gd 1.8.1</TITLE>
+<TITLE>gd 1.8.3</TITLE>
 </HEAD>
 <BODY>
 <!-- BANNER HERE -->
-<H1>gd 1.8.1</H1>
+<H1>gd 1.8.3</H1>
 <H2>A graphics library for fast image creation</H2>
 <H2>Follow this link to the
 <A HREF="http://www.boutell.com/gd/">latest version
 of this document</A>.</H2>
 <blockquote>
 <strong>HEY! READ THIS!</strong>
-gd 1.8.1 creates PNG, JPEG and WBMP images, not GIF images. This is a good
+gd 1.8.3 creates PNG, JPEG and WBMP images, not GIF images. This is a good
 thing.  PNG is a more compact format, and full compression is
 available.  JPEG works well with photographic images, and is still
 more compatible with the major Web browsers than even PNG is. WBMP is
 solution is to move to legally unencumbered, well-compressed,
 modern image formats such as PNG and JPEG as soon as possible.
 <p>
-gd 1.8.1 <strong>requires</strong> that the following libraries 
+gd 1.8.3 <strong>requires</strong> that the following libraries 
 also be installed:
 <p>
 libpng
 <H3>Table of Contents</H3>
 <UL>
 <LI><A HREF="#notice">Credits and license terms</A>
+<LI><A HREF="#whatsnew1.8.3">What's new in version 1.8.3?</A>
+<LI><A HREF="#whatsnew1.8.2">What's new in version 1.8.2?</A>
 <LI><A HREF="#whatsnew1.8.1">What's new in version 1.8.1?</A>
 <LI><A HREF="#whatsnew1.8">What's new in version 1.8?</A>
 <LI><A HREF="#whatsnew1.7.3">What's new in version 1.7.3?</A>
 1994-1998, Thomas G. Lane.  This software is based in part on the work
 of the Independent JPEG Group.
 <p>
-Portions relating to WBMP copyright 2000 Maurice Szmurlo.
+Portions relating to WBMP copyright 2000 Maurice Szmurlo and Johan Van 
+den Brande.
 <p>
 <strong>Permission has been granted to copy, distribute and modify gd in any
 context without fee, including a commercial application, provided that this notice
 fitness for a particular purpose, with respect to this code and accompanying
 documentation.
 <p>
-Although their code does not appear in gd 1.8.1, the authors wish to 
+Although their code does not appear in gd 1.8.3, the authors wish to 
 thank David Koblas, David Rowley, and Hutchison Avenue Software 
 Corporation for their prior contributions.
 </blockquote>
 Lincoln Stein's
 <a href="http://www-genome.wi.mit.edu/ftp/pub/software/WWW/GD.html">
 GD.pm</a> library, which uses gd as the basis for a set of
-Perl 5.x classes. Updated to gd 1.6 and up.
+Perl 5.x classes. Highly recommended.
 <h4>Tcl</h4>
 gd can be used from Tcl with John Ellson's
 <a href=http://www.tcltk.com/ftp/ellson/>Gdtclft</a>
 <h4>Pascal</h4>
 Pascal enthusiasts should look into Michael Bradbury's
 <a href="http://www.elj.com/dev/free-pascal/gdfp/">gdfp</a> package.
+<h4>Haskell</h4>
+A new gd interface is now available for
+<a href="http://www.numeric-quest.com/haskell/gd/index.html">Haskell
+programmers</a>.
 <h4>Any Language</h4>
 There are, at the moment, at least three simple interpreters that
 perform gd operations. You can output the desired commands to a simple
 <li><a href="http://s27w007.pswfs.gov/tgd/">tgd</a>, by Bradley K. Sherman
 <li><a href="http://www.unimelb.edu.au/fly/fly.html">fly</a>, by Martin Gleeson
 </ul>
+<P><A NAME="whatsnew1.8.3"><H3>What's new in version 1.8.3?</H3></A>
+<ul>
+<li>WBMP output memory leak fixed
+<li><code>#include &lt;gd.h&gt;</code> corrected to <code>#include "gd.h"</code> in gd_wbmp.c 
+<li>Documented the fact that the source and output images shouldn't
+match in the WBMP test except for black and white source images
+</ul>
+<P>
+<A NAME="whatsnew1.8.2"><H3>What's new in version 1.8.2?</H3></A>
+<ul>
+<li>WBMP support debugged and improved by Johann Van den Brande
+<li>WBMP tests added to gdtest.c by Thomas Boutell
+<li>Use of platform-dependent 'install' command removed by Thomas Boutell
+<li>Comments added to Makefile warning users to juggle the order of the
+libraries if the linker complains; is there any portable way to do this
+automatically, short of using autoconf?
+<li>Documentation of <a href="#gdImageCreateFromXpm">gdImageCreateFromXpm</a>
+corrected
+<li>Updated links to fast-moving, always dodging libpng and zlib web sites
+</ul>
 <P><A NAME="whatsnew1.8.1"><H3>What's new in version 1.8.1?</H3></A>
 <ul>
 <li>Optional components no longer built by default (following the
 using antialiased TrueType fonts if you also have the libttf
 library installed, but this is not mandatory.
 zlib is available for a variety of platforms from
-<a href="http://www.cdrom.com/pub/infozip/zlib/">the zlib web site</a>.
+<a href="http://www.freesoftware.com/pub/infozip/index.html">the zlib web site</a>.
 libpng is available for a variety of platforms from
 <a href="http://www.cdrom.com/pub/png/">the PNG web site</a>.
 
 <A NAME="getgd"><H3>How do I get gd?</H3></A>
 <h4>By HTTP</h4>
 <ul>
-<li><a href="http://www.boutell.com/gd/http/gd-1.8.1.tar.gz">Gzipped Tar File (Unix)</a>
-<li><a href="http://www.boutell.com/gd/http/gd-1.8.1.zip">.ZIP File (Windows)</a>
+<li><a href="http://www.boutell.com/gd/http/gd-1.8.3.tar.gz">Gzipped Tar File (Unix)</a>
+<li><a href="http://www.boutell.com/gd/http/gd-1.8.3.zip">.ZIP File (Windows)</a>
 </ul>
 <h4>By FTP</h4>
 <ul>
-<li><a href="ftp://ftp.boutell.com/pub/boutell/gd/gd-1.8.1.tar.gz">Gzipped Tar File (Unix)</a>
-<li><a href="ftp://ftp.boutell.com/pub/boutell/gd/gd-1.8.1.zip">.ZIP File (Windows)</a>
+<li><a href="ftp://ftp.boutell.com/pub/boutell/gd/gd-1.8.3.tar.gz">Gzipped Tar File (Unix)</a>
+<li><a href="ftp://ftp.boutell.com/pub/boutell/gd/gd-1.8.3.zip">.ZIP File (Windows)</a>
 </ul>
 <P>
 <A NAME="buildgd"><H3>How do I build gd?</H3></A>
 consult with an experienced user of your system. Sorry, we cannot
 answer questions about basic Internet skills.
 <p>
-Unpacking the archive will produce a directory called "gd-1.8.1".
+Unpacking the archive will produce a directory called "gd-1.8.3".
 <p>
 <h4>For Unix</h4>
-<code>cd</code> to the 1.8.1 directory. Edit the Makefile with
+<code>cd</code> to the 1.8.3 directory. Edit the Makefile with
 your preferred text editor and make any necessary changes to the
 settings at the top, especially if you want Xpm or TrueType support.
 Next, type "make". If you are the system administrator, and you
 /* ... Use the image ... */
 <A HREF="#gdImageDestroy">gdImageDestroy</A>(im);
 </PRE>
-<DT><A NAME="gdImageCreateFromXpm">gdImageCreateFromXpm(FILE *in)</A>
+<DT><A NAME="gdImageCreateFromXpm">gdImageCreateFromXpm(char *filename)</A>
 <strong>(FUNCTION)</strong>
 <DD>
 gdImageCreateFromXbm is called to load images from XPM X Window System
 color bitmap format files. This function is available only if HAVE_XPM
 is selected in the Makefile and the Xpm library is linked with the
-application. Invoke gdImageCreateFromXpm with an already opened pointer 
-to a file containing the desired image.
+application. Unlike most gd file functions, the Xpm functions require
+filenames, not file pointers. 
 gdImageCreateFromXpm
 returns a <A HREF="#gdImagePtr">gdImagePtr</A> to the new image, or NULL
 if unable to load the image (most often because the file is corrupt or
-does not contain an XPM bitmap format image). gdImageCreateFromXpm does
-<em>not</em> close the file. You can inspect the sx and sy members of the
+does not contain an XPM bitmap format image). You can inspect the sx and sy members of the
 image to determine its size. The image must eventually be destroyed
 using <A HREF="#gdImageDestroy">gdImageDestroy()</A>.
 <PRE>
 <A HREF="#gdImageSetStyle">gdImageSetStyle</A>.
 gdTransparent is <strong>not</strong> the transparent
 color index of the image; for that functionality please
-see <A HREF="gdImageColorTransparent">gdImageColorTransparent</A>.
+see <A HREF="#gdImageColorTransparent">gdImageColorTransparent</A>.
 </DL>
 
 <A NAME="gdformat"><H3>About the additional .gd image file format</H3></A>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.