aboutsummaryrefslogtreecommitdiffstats
path: root/x11-toolkits/xmhtml/files
diff options
context:
space:
mode:
authormiwi <miwi@FreeBSD.org>2014-03-11 10:44:55 +0800
committermiwi <miwi@FreeBSD.org>2014-03-11 10:44:55 +0800
commit62f42f2bf579c1e69d119cc0050e50765c36857e (patch)
tree2be4fe45742cc1163dd8243b5c76b8feaf2c5a1d /x11-toolkits/xmhtml/files
parentaa41e27b7c259a2b94c8c08c1f2858d337ebc72b (diff)
downloadfreebsd-ports-gnome-62f42f2bf579c1e69d119cc0050e50765c36857e.tar.gz
freebsd-ports-gnome-62f42f2bf579c1e69d119cc0050e50765c36857e.tar.zst
freebsd-ports-gnome-62f42f2bf579c1e69d119cc0050e50765c36857e.zip
- Update to 1.1.8
- Stage support - Add License PR: 187297 Submitted by: ports fury
Diffstat (limited to 'x11-toolkits/xmhtml/files')
-rw-r--r--x11-toolkits/xmhtml/files/patch-Makefile (renamed from x11-toolkits/xmhtml/files/patch-aa)49
-rw-r--r--x11-toolkits/xmhtml/files/patch-af69
-rw-r--r--x11-toolkits/xmhtml/files/patch-ag11
-rw-r--r--x11-toolkits/xmhtml/files/patch-ai80
-rw-r--r--x11-toolkits/xmhtml/files/patch-book__Makefile (renamed from x11-toolkits/xmhtml/files/patch-ah)4
-rw-r--r--x11-toolkits/xmhtml/files/patch-examples__Makefile (renamed from x11-toolkits/xmhtml/files/patch-ab)4
-rw-r--r--x11-toolkits/xmhtml/files/patch-http__Makefile (renamed from x11-toolkits/xmhtml/files/patch-ac)19
-rw-r--r--x11-toolkits/xmhtml/files/patch-lib__Makefile (renamed from x11-toolkits/xmhtml/files/patch-ad)27
-rw-r--r--x11-toolkits/xmhtml/files/patch-lib_common_readPNG.c169
-rw-r--r--x11-toolkits/xmhtml/files/patch-tools__Makefile (renamed from x11-toolkits/xmhtml/files/patch-ae)23
10 files changed, 212 insertions, 243 deletions
diff --git a/x11-toolkits/xmhtml/files/patch-aa b/x11-toolkits/xmhtml/files/patch-Makefile
index 041ac03a1166..bab978c13960 100644
--- a/x11-toolkits/xmhtml/files/patch-aa
+++ b/x11-toolkits/xmhtml/files/patch-Makefile
@@ -1,6 +1,6 @@
---- Makefile.orig 1999-02-03 18:43:27.000000000 -0600
-+++ Makefile 2009-07-12 10:57:05.000000000 -0500
-@@ -40,7 +40,7 @@
+--- Makefile.orig
++++ Makefile
+@@ -43,7 +43,7 @@
# remove the examples directory from this line.
# If you want to build the XmHTML tutorial examples, add the book directory.
@@ -9,7 +9,7 @@
# some common definitions
#
-@@ -55,7 +55,7 @@
+@@ -58,7 +58,7 @@
RANLIB= ranlib
SHELL = /bin/sh
@@ -18,7 +18,7 @@
# change this to makedepend if your system doesn't have gcc
MAKEDEPEND= gccmakedep
-@@ -64,9 +64,9 @@
+@@ -67,9 +67,9 @@
# Compiler Settings #
# #
#####################
@@ -31,46 +31,43 @@
# The following flags are *very* usefull if you are getting unresolved
# references to functions in libraries that you *know* to exist.
-@@ -115,7 +115,7 @@
+@@ -122,7 +122,7 @@
# HAVE_LIBZ => zlib.h
ZLIBINC =
-IMAGEINCLUDES = $(ZLIBINC)
-+IMAGEINCLUDES = -I${LOCALBASE}/include $(ZLIBINC)
++IMAGEINCLUDES = `libpng-config --cflags` -I${LOCALBASE}/include $(ZLIBINC)
# Image libraries
# No need to add -lXpm if you need to include it with LIBS below
-@@ -126,7 +126,7 @@
+@@ -133,7 +133,7 @@
# HAVE_LIBZ => libz (and possibly libm)
ZLIBLIB = -lz -lm
-IMAGELIBS = -ljpeg -lpng $(ZLIBLIB)
-+IMAGELIBS = -L${LOCALBASE}/lib -ljpeg -lpng $(ZLIBLIB)
++IMAGELIBS = `libpng-config --libs` -L${LOCALBASE}/lib -ljpeg $(ZLIBLIB)
# It might be troublesome to know what the correct defines are for your
# system. A possible set of defines for some OS's is given below. Pick
-@@ -166,17 +166,17 @@
+@@ -173,7 +173,7 @@
# Add -DDEBUG to enable selective debug output (see the file DEBUGGING for more
# info).
#
--CPPFLAGS = -DDEBUG -D_GNU_SOURCE -D_BSD_SOURCE -D_POSIX_SOURCE -DHAVE_REGEX_H $(IMAGEDEFINES)
-+CPPFLAGS = -DHAVE_REGEX_H $(IMAGEDEFINES)
-
- # Various include directories
- LIBINC=-I. -I../include -I../include/common -I../../include -I../../include/common
+-CPPFLAGS = -D_GNU_SOURCE -D_BSD_SOURCE -D_POSIX_SOURCE -DHAVE_REGEX_H \
++CPPFLAGS = -DHAVE_REGEX_H \
+ $(EXTRA_CPPFLAGS) \
+ $(IMAGEDEFINES) \
+ $(XFT_DEFINES)
+@@ -183,7 +183,7 @@
# Platform specific includes
ifeq ($(PLATFORM),Motif)
--PLATFORMINC=-I../../include/XmHTML -I/usr/X11R6/include
-+PLATFORMINC=-I../../include/XmHTML -I${LOCALBASE}/include
+-PLATFORMINC=-I../../include/XmHTML -I/usr/X11R6/include -I/usr/include/freetype2
++PLATFORMINC=-I../../include/XmHTML `pkg-config --cflags xft`
else
ifeq ($(PLATFORM),gtk)
--PLATFORMINC=-I../../include/gtk-xmhtml -I/usr/local/include
-+PLATFORMINC=-I../../include/gtk-xmhtml -I${LOCALBASE}/include
- endif
- endif
-
-@@ -192,10 +192,10 @@
+ PLATFORMINC=\
+@@ -206,7 +206,7 @@
# Motif version (default)
ifeq ($(PLATFORM),Motif)
@@ -78,8 +75,4 @@
+LIBDIR = -L${LOCALBASE}/lib
# This is what is required under Linux (Motif 2.0.1).
# Your mileage may vary.
--LIBS = -lXm -lXpm -lXmu -lXt -lXext -lX11 -lSM -lICE
-+LIBS = ${MOTIFLIB} -lXpm -lXmu -lXt -lXext -lX11 -lSM -lICE
-
- else
-
+ LIBS = -lXm -lXpm -lXmu -lXt -lXext -lX11 -lSM -lICE
diff --git a/x11-toolkits/xmhtml/files/patch-af b/x11-toolkits/xmhtml/files/patch-af
deleted file mode 100644
index c0c6932e90b0..000000000000
--- a/x11-toolkits/xmhtml/files/patch-af
+++ /dev/null
@@ -1,69 +0,0 @@
-The patch fixes:
-1) <HR> placement
-2) formatting inside <PRE></PRE> (not really nice HTML, but any browser
- supports it)
-3) "Can't convert XmHTML_DEFAULT_GAMMA" runtime warning
-
---- XmHTML-1.1.7/lib/common/layout.c.orig Thu Jan 28 02:10:17 1999
-+++ XmHTML-1.1.7/lib/common/layout.c Mon Jun 12 21:55:01 2000
-@@ -2377,14 +2377,16 @@
- * Linefeeds in rules are divided accross the rule: half above and
- * half below.
- *****/
-- if(data->linefeed)
-+ if(data->linefeed) {
-+ box->y += data->linefeed;
- y_offset = data->linefeed/2;
-- else
-+ } else {
- y_offset = data->font->height/2;
-+ }
-
- data->y = box->y + y_offset;
--
-- /* take height of rule into account as well */
-+
-+ /* take height of rule into account as well */
- y_offset += data->height/2;
-
- /* full height of the box */
---- XmHTML-1.1.7/lib/common/parse.c.orig Wed Jan 20 07:13:08 1999
-+++ XmHTML-1.1.7/lib/common/parse.c Mon Jun 12 01:40:19 2000
-@@ -1258,6 +1258,24 @@
- current == HT_U || current == HT_VAR ||
- current == HT_FONT || current == HT_ZTEXT)
- return(True);
-+
-+ /* allow most container elements as well if we can relax */
-+ if(!parser->strict_checking &&
-+ (current == HT_TABLE || current == HT_TR || current == HT_TH ||
-+ current == HT_TD || current == HT_OL || current == HT_UL ||
-+ current == HT_DL || current == HT_P || current == HT_DIV ||
-+ current == HT_BLOCKQUOTE || current == HT_CENTER ||
-+ current == HT_FORM || current == HT_CAPTION ||
-+ current == HT_H1 || current == HT_H2 || current == HT_H3 ||
-+ current == HT_H4 || current == HT_H5 || current == HT_H6))
-+ {
-+#ifdef MINIPARSE
-+ tag_is_wrong_but_allowed = True;
-+#endif
-+ /* but always issue a warning */
-+ parserCallback(parser, current, state, HTML_VIOLATION);
-+ return(True);
-+ }
- break;
-
- case HT_ZTEXT:
---- XmHTML-1.1.7/include/XmHTML/resources.h.orig Sun Dec 13 14:48:46 1998
-+++ XmHTML-1.1.7/include/XmHTML/resources.h Tue Jun 13 02:29:30 2000
-@@ -102,7 +102,9 @@
- #define _resources_h_
-
- #define Offset(field) XtOffsetOf(XmHTMLRec, html.field)
--#define Stringify(VAL) #VAL
-+/* Must use cpp prescan for two levels of macros */
-+#define Stringify(VAL) _Stringify(VAL)
-+#define _Stringify(VAL) #VAL
-
- static XtResource resources [] =
- {
diff --git a/x11-toolkits/xmhtml/files/patch-ag b/x11-toolkits/xmhtml/files/patch-ag
deleted file mode 100644
index 6ad0f27833b4..000000000000
--- a/x11-toolkits/xmhtml/files/patch-ag
+++ /dev/null
@@ -1,11 +0,0 @@
---- XmHTML.cf.orig 1998-10-08 16:50:32.000000000 -0500
-+++ XmHTML.cf 2009-07-12 10:57:05.000000000 -0500
-@@ -61,7 +61,7 @@
-
- #define IHaveJPEG YES
- JPEGINC =
--JPEGLIB = -ljpeg
-+JPEGLIB = -L${LOCALBASE}/lib -ljpeg
-
- XCOMM PNG Support. Enabled by default.
- XCOMM You require libpng, version 0.96 or above. If you don't have this lib
diff --git a/x11-toolkits/xmhtml/files/patch-ai b/x11-toolkits/xmhtml/files/patch-ai
deleted file mode 100644
index f8947a0e59a9..000000000000
--- a/x11-toolkits/xmhtml/files/patch-ai
+++ /dev/null
@@ -1,80 +0,0 @@
---- lib/common/debug.c.old Tue Oct 6 21:58:00 1998
-+++ lib/common/debug.c Tue Feb 5 12:08:16 2002
-@@ -110,7 +110,7 @@
- /*** Private Function Prototype Declarations ****/
-
- /*** Private Variable Declarations ***/
--static FILE *__rsd_debug_file = stdout;
-+static FILE *__rsd_debug_file;
-
- /*****
- * When debug output is send to a file, we register an exit func to close
-@@ -128,7 +128,11 @@
- #endif
- {
- /* close output file */
-- fclose(__rsd_debug_file);
-+ if (__rsd_debug_file) {
-+ fclose(__rsd_debug_file);
-+ __rsd_debug_file = NULL;
-+ }
-+
- }
-
- /*****
-@@ -146,6 +150,7 @@
- #ifdef __STDC__
- __rsd_fprintf(char *fmt, ...)
- {
-+ register FILE *fp = (__rsd_debug_file ? __rsd_debug_file : stdout);
- va_list arg_list;
- va_start(arg_list, fmt);
-
-@@ -155,15 +160,16 @@
- char *fmt;
- va_dcl
- {
-+ register FILE *fp = (__rsd_debug_file ? __rsd_debug_file : stdout);
- va_list arg_list;
- va_start(arg_list);
- #endif /* __STDC__ */
-
- /* flush to file */
-- vfprintf(__rsd_debug_file, fmt, arg_list);
-+ vfprintf(fp, fmt, arg_list);
- va_end(arg_list);
-
-- fflush(__rsd_debug_file);
-+ fflush(fp);
- }
-
- /*****
-@@ -298,8 +304,10 @@
- if((chPtr = strstr(argv[i], ":")) != NULL)
- {
- /* close any existing output file */
-- if(__rsd_debug_file != stdout)
-+ if(__rsd_debug_file) {
- fclose(__rsd_debug_file);
-+ __rsd_debug_file = NULL;
-+ }
-
- chPtr++; /* skip : */
- if(!strcmp(chPtr, "pid")) /* <pid>.out */
-@@ -336,14 +344,14 @@
- fprintf(stderr, "__rsd_setDebugLevels: failed to open "
- "output file %s (errno = %i), reverting to "
- "stdout\n", tmp, errno);
-- __rsd_debug_file = stdout;
-+ __rsd_debug_file = NULL;
- }
- }
- else
- {
- fprintf(stderr, "__rsd_setDebugLevels: missing arg to "
- "-dfile:, reverting to stdout\n");
-- __rsd_debug_file = stdout;
-+ __rsd_debug_file = NULL;
- }
- /* remove from cmd line */
- REMOVE_ARG;
diff --git a/x11-toolkits/xmhtml/files/patch-ah b/x11-toolkits/xmhtml/files/patch-book__Makefile
index cffff2e4df63..d2ccd2bbb76d 100644
--- a/x11-toolkits/xmhtml/files/patch-ah
+++ b/x11-toolkits/xmhtml/files/patch-book__Makefile
@@ -1,5 +1,5 @@
---- book/Makefile.orig 1999-02-03 18:43:27.000000000 -0600
-+++ book/Makefile 2009-07-12 11:11:05.000000000 -0500
+--- book/Makefile.orig
++++ book/Makefile
@@ -12,13 +12,13 @@
# The library
diff --git a/x11-toolkits/xmhtml/files/patch-ab b/x11-toolkits/xmhtml/files/patch-examples__Makefile
index 34f708228488..3949e2aeef7b 100644
--- a/x11-toolkits/xmhtml/files/patch-ab
+++ b/x11-toolkits/xmhtml/files/patch-examples__Makefile
@@ -1,5 +1,5 @@
---- examples/Makefile.orig 1999-02-03 18:43:27.000000000 -0600
-+++ examples/Makefile 2009-07-12 11:02:35.000000000 -0500
+--- examples/Makefile.orig
++++ examples/Makefile
@@ -11,10 +11,10 @@
EXAMPLES=example_1 example_2 example_4
diff --git a/x11-toolkits/xmhtml/files/patch-ac b/x11-toolkits/xmhtml/files/patch-http__Makefile
index 7dbdb547a9d1..67a9fd32202f 100644
--- a/x11-toolkits/xmhtml/files/patch-ac
+++ b/x11-toolkits/xmhtml/files/patch-http__Makefile
@@ -1,31 +1,32 @@
---- http/Makefile.orig 1999-02-03 18:43:27.000000000 -0600
-+++ http/Makefile 2009-07-12 11:03:51.000000000 -0500
+--- http/Makefile.orig
++++ http/Makefile
@@ -2,7 +2,7 @@
# lint configuration. I use lclint.
#
-LIBRARY=libhttp.a
+LIBRARY=libhttp.la
+ SHAREDLIB=libhttp.so.0
+ SONAME=libhttp.so.0
- # List of source, object and header files
- SRCS=HTTP.c cookie.c
-@@ -20,16 +20,15 @@
+@@ -23,16 +23,15 @@
# rule to create .o files from .c files
.c.o:
$(RM) $@
- $(CC) $(CFLAGS) $(CPPFLAGS) $(INCLUDES) -c $<
+ $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) $(CPPFLAGS) $(INCLUDES) -c $<
- all: $(TARGET)
+-all: $(TARGET_STATIC) $(TARGET_SHARED)
++all: $(TARGET_STATIC)
# targets to build
- $(TARGET):: $(OBJS)
+ $(TARGET_STATIC):: $(OBJS)
- $(RM) $@ \
- $(AR) $@ $(OBJS)
- $(RANLIB) $@
+ $(RM) $@
+ $(LIBTOOL) --mode=link $(CC) -o $@ $(OBJS:.o=.lo) -rpath ${PREFIX}/lib -version-info 0:2
- stamp-includes:
- @if [ -d ../include ]; then set +x; \
+ $(TARGET_SHARED):: $(OBJS)
+ $(RM) $@ ; \
diff --git a/x11-toolkits/xmhtml/files/patch-ad b/x11-toolkits/xmhtml/files/patch-lib__Makefile
index 67e7f696c31b..cd15195c865e 100644
--- a/x11-toolkits/xmhtml/files/patch-ad
+++ b/x11-toolkits/xmhtml/files/patch-lib__Makefile
@@ -1,24 +1,33 @@
---- lib/Makefile.orig 1999-02-03 18:43:26.000000000 -0600
-+++ lib/Makefile 2009-07-12 11:05:25.000000000 -0500
+--- lib/Makefile.orig
++++ lib/Makefile
@@ -25,7 +25,7 @@
# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #
##############################################################################
#
-LIBRARY=libXmHTML.a
+LIBRARY=libXmHTML.la
+ SHAREDLIB=libXmHTML.so.$(ARCHIVE)
+ SONAME=$(basename $(SHAREDLIB))
- # Target to make
- TARGET=$(LIBRARY)
-@@ -44,9 +44,9 @@
+@@ -37,7 +37,7 @@
+ SUBDIRS= common $(PLATFORM)
+
+ # Target rules
+-all:: $(TARGET_STATIC) $(TARGET_SHARED)
++all:: $(TARGET_STATIC)
+
+ # Separate rules for all targets
+ $(PLATFORM)::
+@@ -47,9 +47,9 @@
@(set -x; cd common; $(MAKE) all $(pass_flags) )
- $(TARGET):: common $(PLATFORM)
+ $(TARGET_STATIC):: common $(PLATFORM)
- $(RM) $@ \
- $(AR) $@ common/*.o $(PLATFORM)/*.o
- $(RANLIB) $@
+ $(RM) $@
+ $(LIBTOOL) --mode=link $(CC) -o $@ common/*.lo $(PLATFORM)/*.lo \
+ -rpath ${PREFIX}/lib -version-info 1:2
-
- depend::
- @( for dir in $(SUBDIRS) ; do \
+
+ $(TARGET_SHARED):: common $(PLATFORM)
+ $(RM) $@ ; \
diff --git a/x11-toolkits/xmhtml/files/patch-lib_common_readPNG.c b/x11-toolkits/xmhtml/files/patch-lib_common_readPNG.c
index 5bbffea2ef9e..b7469d27663d 100644
--- a/x11-toolkits/xmhtml/files/patch-lib_common_readPNG.c
+++ b/x11-toolkits/xmhtml/files/patch-lib_common_readPNG.c
@@ -1,28 +1,149 @@
--- lib/common/readPNG.c.orig 1998-11-16 23:56:19.000000000 +0100
+++ lib/common/readPNG.c 2012-05-26 14:16:45.000000000 +0200
-@@ -82,6 +82,7 @@
-
- #ifdef HAVE_LIBPNG
- #include <png.h>
-+#include <pngpriv.h>
- #include <setjmp.h>
- #include <math.h> /* required for full alpha channel processing */
- #endif
-@@ -132,7 +133,7 @@
-
- _XmHTMLWarning(__WFUNC__(NULL, "png_error"), XMHTML_MSG_121, "png",
- ib->file, msg);
-- longjmp(png_ptr->jmpbuf, 1);
-+ longjmp(png_jmpbuf(png_ptr), 1);
- }
-
- /*****
-@@ -232,7 +233,7 @@
- return((XmHTMLRawImageData*)NULL);
+@@ -184,9 +184,11 @@
+ int i, idx, npass;
+ int width, height, color_type;
+ int ncolors, max_colors;
+- float gamma, fg_gamma;
++ float gamma;
++ double fg_gamma;
+ Boolean has_alpha = False, has_cmap = False, do_gamma = True;
+ png_bytep *row_ptrs;
++ png_colorp palette;
+ char msg[128];
+ static XmHTMLRawImageData *img_data;
+
+@@ -265,17 +267,18 @@
+ ResetRawImage(img_data);
+
+ /* save width & height */
+- width = img_data->width = info_ptr->width;
+- height = img_data->height = info_ptr->height;
++ width = img_data->width = png_get_image_width(png_ptr, info_ptr);
++ height = img_data->height = png_get_image_height(png_ptr, info_ptr);
+
+ /* image depth */
+- ib->depth = info_ptr->bit_depth;
++ ib->depth = png_get_bit_depth(png_ptr, info_ptr);
+
+ /* no of colors */
+- ncolors = img_data->cmapsize = info_ptr->num_palette;
++ png_get_PLTE(png_ptr, info_ptr, &palette, &ncolors);
++ img_data->cmapsize = ncolors;
+
+ /* type of image */
+- color_type = info_ptr->color_type;
++ color_type = png_get_color_type(png_ptr, info_ptr);
+
+ /*
+ * The fun stuff. This is based on readPNG by Greg Roelofs as found
+@@ -306,7 +309,7 @@
+ * Actual image creation is postponed until the image is
+ * needed.
+ */
+- if(info_ptr->valid & PNG_INFO_tRNS)
++ if(png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS))
+ {
+ _XmHTMLDebug(15, ("readPNG.c: tRNS chunk present\n"));
+ png_set_expand(png_ptr);
+@@ -319,9 +322,9 @@
+ AllocRawImageCmap(img_data, ncolors);
+ for(i = 0; i < ncolors; i++)
+ {
+- GETR(img_data->cmap[i]) = info_ptr->palette[i].red;
+- GETG(img_data->cmap[i]) = info_ptr->palette[i].green;
+- GETB(img_data->cmap[i]) = info_ptr->palette[i].blue;
++ GETR(img_data->cmap[i]) = palette[i].red;
++ GETG(img_data->cmap[i]) = palette[i].green;
++ GETB(img_data->cmap[i]) = palette[i].blue;
+ }
+ has_cmap = True;
+ data = (Byte*)malloc(width*height*sizeof(Byte));
+@@ -355,7 +358,7 @@
+ * grayscale with transparency is expanded to RGB with alpha
+ * channel.
+ */
+- if(info_ptr->valid & PNG_INFO_tRNS)
++ if(png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS))
+ {
+ _XmHTMLDebug(15, ("readPNG.c: tRNS chunk present\n"));
+ png_set_gray_to_rgb(png_ptr);
+@@ -434,7 +437,7 @@
+ break;
+ default:
+ sprintf(msg, "bad PNG image: unknown color type (%d)",
+- info_ptr->color_type);
++ png_get_color_type(png_ptr, info_ptr));
+ my_png_error(png_ptr, msg);
+ break;
}
- /* now set error handler */
-- if(setjmp(png_ptr->jmpbuf))
-+ if(setjmp(png_jmpbuf(png_ptr)))
+@@ -444,16 +447,18 @@
+ * Doing that for alpha channel images would change the colortype of the
+ * current image, leading to weird results.
+ */
+- if(!has_alpha && info_ptr->valid & PNG_INFO_bKGD)
++ if(!has_alpha && png_get_valid(png_ptr, info_ptr, PNG_INFO_bKGD))
{
- /*
- * PNG signalled an error. Destroy image data, free any allocated
+- png_set_background(png_ptr, &(info_ptr->background),
++ png_color_16p background;
++ png_get_bKGD(png_ptr, info_ptr, &background);
++ png_set_background(png_ptr, background,
+ PNG_BACKGROUND_GAMMA_FILE, 1, 1.0);
+- img_data->bg = info_ptr->background.index;
++ img_data->bg = background->index;
+ }
+
+ /* handle gamma correction */
+- if(info_ptr->valid & PNG_INFO_gAMA)
+- fg_gamma = info_ptr->gamma;
++ if(png_get_valid(png_ptr, info_ptr, PNG_INFO_gAMA))
++ png_get_gAMA(png_ptr, info_ptr, &fg_gamma);
+ else
+ fg_gamma = 0.45;
+
+@@ -464,20 +469,20 @@
+ /* dithering gets handled by caller */
+
+ /* one byte per pixel */
+- if(info_ptr->bit_depth < 8)
++ if(png_get_bit_depth(png_ptr, info_ptr) < 8)
+ png_set_packing(png_ptr);
+
+ /* no tRNS chunk handling, we've expanded it to an alpha channel. */
+
+ /* handle interlacing */
+- if(info_ptr->interlace_type)
++ if(png_get_interlace_type(png_ptr, info_ptr))
+ npass = png_set_interlace_handling(png_ptr);
+
+ /* and now update everything */
+ png_read_update_info(png_ptr, info_ptr);
+
+ /* has possibly changed if we have promoted GrayScale or tRNS chunks */
+- color_type = info_ptr->color_type;
++ color_type = png_get_color_type(png_ptr, info_ptr);
+
+ /* new color_type? */
+ if(color_type == PNG_COLOR_TYPE_RGB_ALPHA)
+@@ -497,10 +502,10 @@
+ * will call doAlphaChannel to do the actual image creation.
+ */
+ row_ptrs = (png_bytep*)malloc(height*sizeof(png_bytep));
+- png_data = (png_bytep)malloc(height*info_ptr->rowbytes);
++ png_data = (png_bytep)malloc(height*png_get_rowbytes(png_ptr, info_ptr));
+
+ for(i = 0; i < height; i++)
+- row_ptrs[i] = (png_bytep)png_data + i*info_ptr->rowbytes;
++ row_ptrs[i] = (png_bytep)png_data + i*png_get_rowbytes(png_ptr, info_ptr);
+
+ /* read it */
+ png_read_image(png_ptr, row_ptrs);
+@@ -529,7 +534,7 @@
+ row_ptrs = (png_bytep*)malloc(height*sizeof(png_bytep));
+
+ for(i = 0; i < height; ++i)
+- row_ptrs[i] = (png_bytep)data + i*info_ptr->rowbytes;
++ row_ptrs[i] = (png_bytep)data + i*png_get_rowbytes(png_ptr, info_ptr);
+
+ /* read it */
+ png_read_image(png_ptr, row_ptrs);
diff --git a/x11-toolkits/xmhtml/files/patch-ae b/x11-toolkits/xmhtml/files/patch-tools__Makefile
index 351bc00406ec..6c9d60953705 100644
--- a/x11-toolkits/xmhtml/files/patch-ae
+++ b/x11-toolkits/xmhtml/files/patch-tools__Makefile
@@ -1,5 +1,5 @@
---- tools/Makefile.orig 1999-02-03 18:43:27.000000000 -0600
-+++ tools/Makefile 2009-07-12 11:08:00.000000000 -0500
+--- tools/Makefile.orig
++++ tools/Makefile
@@ -39,7 +39,7 @@
# rule to create .o files from .c files
.c.o:
@@ -34,39 +34,44 @@
#
# All Targets
-@@ -76,29 +76,29 @@
+@@ -76,33 +76,33 @@
reptype:: GetRepTypes.o
$(RM) $@ \
- $(CC) -o $@ $(LDFLAGS) GetRepTypes.o $(LOADLIBES)
-+ $(LIBTOOL) --mode=link $(CC) -o $@ $(LDFLAGS) GetRepTypes.o $(LOADLIBES)
++ $(LIBTOOL) --mode=compile $(CC) -o $@ $(LDFLAGS) GetRepTypes.o $(LOADLIBES)
wsize:: WidgetSize.o
$(RM) $@ \
- $(CC) -o $@ $(LDFLAGS) WidgetSize.o
-+ $(LIBTOOL) --mode=link $(CC) -o $@ $(LDFLAGS) WidgetSize.o
++ $(LIBTOOL) --mode=compile $(CC) -o $@ $(LDFLAGS) WidgetSize.o
gifinfo:: gifinfo.o ImBuffer.o
$(RM) $@ \
- $(CC) -o $@ $(LDFLAGS) gifinfo.o ImBuffer.o
-+ $(LIBTOOL) --mode=link $(CC) -o $@ $(LDFLAGS) gifinfo.o ImBuffer.o
++ $(LIBTOOL) --mode=compile $(CC) -o $@ $(LDFLAGS) gifinfo.o ImBuffer.o
httpget:: httpget.o
$(RM) $@ \
- $(CC) -o $@ $(LDFLAGS) httpget.o -L../http -lhttp $(DMALLOCLIB)
-+ $(LIBTOOL) --mode=link $(CC) -o $@ $(LDFLAGS) httpget.o ../http/libhttp.la $(DMALLOCLIB)
++ $(LIBTOOL) --mode=compile $(CC) -o $@ $(LDFLAGS) httpget.o ../http/libhttp.la $(DMALLOCLIB)
+
+ mkStrings:: mkStrings.o
+ $(RM) $@ \
+- $(CC) -o $@ $(LDFLAGS) mkStrings.o
++ $(LIBTOOL) --mode=compile $(CC) -o $@ $(LDFLAGS) mkStrings.o
# gif to gzf converter
gif2gzf:: gif2gzf.o LZWStream.o ImBuffer.o
$(RM) $@ \
- $(CC) -o $@ $(LDFLAGS) gif2gzf.o LZWStream.o ImBuffer.o $(ZLIBLIB)
-+ $(LIBTOOL) --mode=link $(CC) -o $@ $(LDFLAGS) gif2gzf.o LZWStream.o ImBuffer.o $(ZLIBLIB)
++ $(LIBTOOL) --mode=compile $(CC) -o $@ $(LDFLAGS) gif2gzf.o LZWStream.o ImBuffer.o $(ZLIBLIB)
# stand alone parser
HTMLparse:: parse.o miniparse.o
$(RM) $@
- $(CC) -o $@ $(LDFLAGS) parse.o miniparse.o
-+ $(LIBTOOL) --mode=link $(CC) -o $@ $(LDFLAGS) parse.o miniparse.o
++ $(LIBTOOL) --mode=compile $(CC) -o $@ $(LDFLAGS) parse.o miniparse.o
depend:: $(SRCS)
$(MAKEDEPEND) $(INCLUDES) $(CPPFLAGS) -DMINIPARSE -DNO_XmHTML $(SRCS)