Update htmldoc to 1.8.28.

This commit is contained in:
benoit 2014-11-07 13:33:40 +00:00
parent fe681b3352
commit 163a21bdcb
9 changed files with 38 additions and 155 deletions

View File

@ -1,13 +1,11 @@
# $OpenBSD: Makefile,v 1.33 2013/10/11 23:50:39 naddy Exp $
# $OpenBSD: Makefile,v 1.34 2014/11/07 13:33:40 benoit Exp $
COMMENT= convert HTML pages to PDF/PS format
V= 1.8.27
V = 1.8.28
DISTNAME= htmldoc-${V}
CATEGORIES= print www
REVISION = 7
HOMEPAGE = http://www.msweet.org/projects.php?Z1
MAINTAINER= Benoit Lecocq <benoit@openbsd.org>
@ -15,7 +13,7 @@ MAINTAINER= Benoit Lecocq <benoit@openbsd.org>
# GPLv2 with OpenSSL exception.
PERMIT_PACKAGE_CDROM= Yes
WANTLIB += c crypto m ssl z jpeg png
WANTLIB += c crypto m ssl z jpeg png stdc++
DISTFILES= ${DISTNAME}-source${EXTRACT_SUFX}
MASTER_SITES = http://www.msweet.org/files/project1/ \
@ -26,7 +24,7 @@ LIB_DEPENDS= graphics/jpeg \
graphics/png
CONFIGURE_STYLE= gnu dest
CONFIGURE_ARGS+= --without-gui
CONFIGURE_ARGS+= --without-gui --disable-gnutls
CONFIGURE_ENV= LDFLAGS="-L${LOCALBASE}/lib" \
CXXFLAGS="${CXXFLAGS} -I${LOCALBASE}/include" \
CPPFLAGS="-I${LOCALBASE}/include"

View File

@ -1,2 +1,2 @@
SHA256 (htmldoc-1.8.27-source.tar.gz) = ZPbZ9A8A+cxo32UIEj6I7TD++SSIH9KNykU1js150yA=
SIZE (htmldoc-1.8.27-source.tar.gz) = 4462252
SHA256 (htmldoc-1.8.28-source.tar.gz) = AipRnNho82lm29peEoNo8TSslEGLaNfKa+B5TGGZfTo=
SIZE (htmldoc-1.8.28-source.tar.gz) = 4662299

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-Makedefs_in,v 1.2 2006/09/23 10:14:34 steven Exp $
--- Makedefs.in.orig Fri Sep 22 19:27:17 2006
+++ Makedefs.in Fri Sep 22 19:27:30 2006
@@ -81,13 +81,10 @@ OPTIM = @OPTIM@ @SSLFLAGS@
$OpenBSD: patch-Makedefs_in,v 1.3 2014/11/07 13:33:40 benoit Exp $
--- Makedefs.in.orig Fri Dec 23 07:23:11 2011
+++ Makedefs.in Sun Apr 6 17:57:37 2014
@@ -70,13 +70,10 @@ OPTIM = @OPTIM@ @SSLFLAGS@
# Rules...
#

View File

@ -1,12 +1,12 @@
$OpenBSD: patch-configure,v 1.3 2007/05/02 18:34:00 ajacoutot Exp $
--- configure.orig Wed May 2 20:21:26 2007
+++ configure Wed May 2 20:21:38 2007
@@ -5944,7 +5944,7 @@ echo "${ECHO_T}yes" >&6
fi
$OpenBSD: patch-configure,v 1.4 2014/11/07 13:33:40 benoit Exp $
--- configure.orig Mon Jan 6 05:28:07 2014
+++ configure Sun Apr 6 17:57:37 2014
@@ -5278,7 +5278,7 @@ _ACEOF
if test -n "$GXX"; then
if test -z "$OPTIM"; then
- OPTIM="-Os -g"
+ OPTIM=""
fi
OPTIM="-Wall -Wunused -Wno-char-subscripts $OPTIM"
OPTIM="-Wall -Wunused -Wno-char-subscripts -Wno-format-y2k $OPTIM"

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-htmldoc_file_c,v 1.4 2007/05/02 18:34:00 ajacoutot Exp $
--- htmldoc/file.c.orig Wed May 31 21:00:02 2006
+++ htmldoc/file.c Wed May 2 16:56:21 2007
@@ -78,7 +78,7 @@
$OpenBSD: patch-htmldoc_file_c,v 1.5 2014/11/07 13:33:40 benoit Exp $
--- htmldoc/file.c.orig Fri Dec 30 06:03:21 2011
+++ htmldoc/file.c Sun Apr 6 17:57:37 2014
@@ -66,7 +66,7 @@
# define OPENPERM (_S_IREAD | _S_IWRITE)
#else
# define TEMPLATE "%s/%06ld.%06d.tmp"
@ -10,7 +10,7 @@ $OpenBSD: patch-htmldoc_file_c,v 1.4 2007/05/02 18:34:00 ajacoutot Exp $
# define OPENPERM 0600
#endif /* WIN32 */
@@ -176,7 +176,7 @@ file_cleanup(void)
@@ -164,7 +164,7 @@ file_cleanup(void)
}
#else
if ((tmpdir = getenv("TMPDIR")) == NULL)
@ -19,7 +19,7 @@ $OpenBSD: patch-htmldoc_file_c,v 1.4 2007/05/02 18:34:00 ajacoutot Exp $
#endif /* WIN32 */
/*
@@ -1097,7 +1097,7 @@ file_temp(char *name, /* O - Filename */
@@ -1086,7 +1086,7 @@ file_temp(char *name, /* O - Filename */
}
#else
if ((tmpdir = getenv("TMPDIR")) == NULL)

View File

@ -0,0 +1,14 @@
$OpenBSD: patch-htmldoc_http_c,v 1.1 2014/11/07 13:33:40 benoit Exp $
--- htmldoc/http.c.orig Sun Jan 12 10:36:41 2014
+++ htmldoc/http.c Sun Jan 12 10:40:00 2014
@@ -38,6 +38,10 @@
# include <sys/poll.h>
#endif /* HAVE_POLL */
+#if defined(__OpenBSD__)
+# define CUPS_RAND() arc4random()
+# define CUPS_SRAND(v)
+#endif
/*
* Some operating systems have done away with the Fxxxx constants for

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-htmldoc_http_h,v 1.1 2006/09/23 10:14:34 steven Exp $
--- htmldoc/http.h.orig Fri Sep 22 19:28:19 2006
+++ htmldoc/http.h Fri Sep 22 19:28:42 2006
@@ -100,7 +100,7 @@ extern "C" {
#if defined(AF_INET6) && !defined(s6_addr32)
# if defined(__sun)
# define s6_addr32 _S6_un._S6_u32
-# elif defined(__FreeBSD__) || defined(__APPLE__)
+# elif defined(__FreeBSD__) || defined(__APPLE__) || defined(__OpenBSD__)
# define s6_addr32 __u6_addr.__u6_addr32
# elif defined(__osf__)
# define s6_addr32 s6_un.sa6_laddr

View File

@ -1,117 +0,0 @@
$OpenBSD: patch-htmldoc_image_cxx,v 1.1 2011/07/08 20:36:09 naddy Exp $
Fix build with png-1.5.
--- htmldoc/image.cxx.orig Wed May 31 13:00:02 2006
+++ htmldoc/image.cxx Wed Jul 6 15:22:43 2011
@@ -1472,6 +1472,9 @@ image_load_png(image_t *img, /* I - Image pointer */
png_bytep *rows; /* PNG row pointers */
uchar *inptr, /* Input pixels */
*outptr; /* Output pixels */
+ png_bytep trans_alpha;
+ int num_trans;
+ png_color_16p trans_color;
/*
@@ -1499,7 +1502,7 @@ image_load_png(image_t *img, /* I - Image pointer */
rows = NULL;
- if (setjmp(pp->jmpbuf))
+ if (setjmp(png_jmpbuf(pp)))
{
progress_error(HD_ERROR_BAD_FORMAT, "PNG file contains errors!");
@@ -1526,7 +1529,7 @@ image_load_png(image_t *img, /* I - Image pointer */
png_read_info(pp, info);
- if (info->color_type & PNG_COLOR_MASK_PALETTE)
+ if (png_get_color_type(pp, info) & PNG_COLOR_MASK_PALETTE)
{
png_set_expand(pp);
@@ -1535,15 +1538,15 @@ image_load_png(image_t *img, /* I - Image pointer */
if (Encryption)
img->use ++;
}
- else if (info->bit_depth < 8)
+ else if (png_get_bit_depth(pp, info) < 8)
{
png_set_packing(pp);
png_set_expand(pp);
}
- else if (info->bit_depth == 16)
+ else if (png_get_bit_depth(pp, info) == 16)
png_set_strip_16(pp);
- if (info->color_type & PNG_COLOR_MASK_COLOR)
+ if (png_get_color_type(pp, info) & PNG_COLOR_MASK_COLOR)
{
depth = 3;
img->depth = gray ? 1 : 3;
@@ -1554,10 +1557,11 @@ image_load_png(image_t *img, /* I - Image pointer */
img->depth = 1;
}
- img->width = info->width;
- img->height = info->height;
+ img->width = png_get_image_width(pp, info);
+ img->height = png_get_image_height(pp, info);
- if ((info->color_type & PNG_COLOR_MASK_ALPHA) || info->num_trans)
+ png_get_tRNS(pp, info, &trans_alpha, &num_trans, &trans_color);
+ if ((png_get_color_type(pp, info) & PNG_COLOR_MASK_ALPHA) || num_trans)
{
if ((PSLevel == 0 && PDFVersion >= 14) || PSLevel == 3)
image_need_mask(img, 8);
@@ -1571,14 +1575,14 @@ image_load_png(image_t *img, /* I - Image pointer */
#ifdef DEBUG
printf("color_type=0x%04x, depth=%d, img->width=%d, img->height=%d, img->depth=%d\n",
- info->color_type, depth, img->width, img->height, img->depth);
- if (info->color_type & PNG_COLOR_MASK_COLOR)
+ png_get_color_type(pp, info), depth, img->width, img->height, img->depth);
+ if (png_get_color_type(pp, info) & PNG_COLOR_MASK_COLOR)
puts(" COLOR");
else
puts(" GRAYSCALE");
- if ((info->color_type & PNG_COLOR_MASK_ALPHA) || info->num_trans)
+ if ((png_get_color_type(pp, info) & PNG_COLOR_MASK_ALPHA) || num_trans)
puts(" ALPHA");
- if (info->color_type & PNG_COLOR_MASK_PALETTE)
+ if (png_get_color_type(pp, info) & PNG_COLOR_MASK_PALETTE)
puts(" PALETTE");
#endif // DEBUG
@@ -1594,9 +1598,9 @@ image_load_png(image_t *img, /* I - Image pointer */
* Allocate pointers...
*/
- rows = (png_bytep *)calloc(info->height, sizeof(png_bytep));
+ rows = (png_bytep *)calloc(png_get_image_height(pp, info), sizeof(png_bytep));
- for (i = 0; i < (int)info->height; i ++)
+ for (i = 0; i < (int)png_get_image_height(pp, info); i ++)
rows[i] = img->pixels + i * img->width * depth;
/*
@@ -1610,7 +1614,7 @@ image_load_png(image_t *img, /* I - Image pointer */
* Generate the alpha mask as necessary...
*/
- if ((info->color_type & PNG_COLOR_MASK_ALPHA) || info->num_trans)
+ if ((png_get_color_type(pp, info) & PNG_COLOR_MASK_ALPHA) || num_trans)
{
#ifdef DEBUG
for (inptr = img->pixels, i = 0; i < img->height; i ++)
@@ -1639,7 +1643,7 @@ image_load_png(image_t *img, /* I - Image pointer */
* Reformat the data as necessary for the reader...
*/
- if (gray && info->color_type & PNG_COLOR_MASK_COLOR)
+ if (gray && png_get_color_type(pp, info) & PNG_COLOR_MASK_COLOR)
{
/*
* Greyscale output needed...

View File

@ -1,6 +1,6 @@
@comment $OpenBSD: PLIST,v 1.6 2011/07/10 09:40:57 jasper Exp $
@comment $OpenBSD: PLIST,v 1.7 2014/11/07 13:33:40 benoit Exp $
@pkgpath print/htmldoc,no_x11
bin/htmldoc
@bin bin/htmldoc
@man man/man1/htmldoc.1
share/doc/htmldoc/
share/doc/htmldoc/help.html