diff -u h5utils-1.12.1/debian/changelog h5utils-1.12.1/debian/changelog --- h5utils-1.12.1/debian/changelog +++ h5utils-1.12.1/debian/changelog @@ -1,3 +1,10 @@ +h5utils (1.12.1-1.1) unstable; urgency=low + + * Non-maintainer upload. + * Fix FTBFS with libpng 1.5. + + -- Nobuhiro Iwamatsu Mon, 14 May 2012 17:58:15 +0900 + h5utils (1.12.1-1) unstable; urgency=low * New upstream release with better Octave autodetection. only in patch2: unchanged: --- h5utils-1.12.1.orig/writepng.c +++ h5utils-1.12.1/writepng.c @@ -240,6 +240,7 @@ double skewsin = sin(skew), skewcos = cos(skew); REAL minoverlay = 0, maxoverlay = 0; png_byte mask_byte; + png_colorp palette; /* we must use direct color for translucent overlays */ if (overlay) @@ -309,7 +310,12 @@ } /* Set error handling. REQUIRED if you aren't supplying your own * * error hadnling functions in the png_create_write_struct() call. */ + +#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4 + if (setjmp(png_jmpbuf(png_ptr))) { +#else if (setjmp(png_ptr->jmpbuf)) { +#endif /* If we get here, we had a problem reading the file */ fclose(fp); png_destroy_write_struct(&png_ptr, (png_infopp) NULL); @@ -334,7 +340,6 @@ PNG_INTERLACE_NONE, PNG_COMPRESSION_TYPE_BASE, PNG_FILTER_TYPE_BASE); else { - png_colorp palette; png_set_IHDR(png_ptr, info_ptr, width, height, 8 /* bit_depth */ , PNG_COLOR_TYPE_PALETTE, @@ -434,7 +439,12 @@ png_write_end(png_ptr, info_ptr); /* if you malloced the palette, free it here */ +#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4 + png_free(png_ptr, palette); + palette = NULL; +#else free(info_ptr->palette); +#endif /* if you allocated any text comments, free them here */