diff options
Diffstat (limited to 'Build/source/texk/dvipng/dvipng-PATCHES')
6 files changed, 311 insertions, 0 deletions
diff --git a/Build/source/texk/dvipng/dvipng-PATCHES/ChangeLog b/Build/source/texk/dvipng/dvipng-PATCHES/ChangeLog new file mode 100644 index 00000000000..64d6ffe16c1 --- /dev/null +++ b/Build/source/texk/dvipng/dvipng-PATCHES/ChangeLog @@ -0,0 +1,129 @@ +2015-03-04 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-07-w64-ptr: Better handling of WIN64 ptr->long. + +2015-03-03 Peter Breitenlohner <peb@mppmu.mpg.de> + + * Imported release 1.15 from savannah.nongnu.org. + * patch-01-gd-copyright: Removed. + * patch-05-sys_wait (removed): Included in 1.15. + * patch-02-const, patch-03-programname, patch-06-WIN32, + patch-07-w64-ptr: Adapted. + +2014-11-05 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-07-w64-ptr: Fixed a typo. + +2014-07-15 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-07-w64-ptr: Avoid WIN64 warning due to different size. + +2013-07-09 Peter Breitenlohner <peb@mppmu.mpg.de> + + * COPYING.gd (new): From libgd-2.1.0/COPYING, with '@' => '@@'. + * patch-01-gd-copyright: Refer to COPYING.gd instead of + including it into dvipng.texi. + + * patch-04-dvigif (removed): Merged into patch-03-programname. + * patch-03-programname: Use kpse_program_basename(). + +2012-08-25 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-06-WIN32: Avoid warning when redefining pipe. + +2012-08-01 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-06-WIN32: Do not redefine snprintf, handled by kpathsea. + Also, kpathsea has included <fcntl.h>, <io.h>, and <process.h>. + +2011-08-03 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-06-WIN32 (new): Call texlive_gs_init() for MINGW32, + as for native WIN32, from Akira. + +2011-02-07 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-05-sys_wait (new): #include <sys/wait.h>, not <wait.h>. + Reported by Nikola Lecic <nikola.lecic@anthesphoria.net>. + +2010-12-30 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-03-programname (new): Use basename() as defined in + <libgen.h> or xbasename() from kpathsea to extract programname + from argv[0]. Avoid uninitialized use of programname. + + * patch-04-dvigif (new): Check for argv[0] with .exe via + strcasecmp(), if possible. + +2010-12-15 Peter Breitenlohner <peb@mppmu.mpg.de> + + * Imported release 1.14 from savannah.nongnu.org. + * patch-2?-* (removed): Included in 1.14. + + * patch-01-gd-copyright (new): Include full gd copyright notice + into dvipng.texi; seems the safe thing to do. + + * patch-02-const (new): Avoid compiler warnings. + +2010-10-02 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-22-win32-bugfix (new): WIN32 bug fix from Akira Kakuto. + +2010-03-18 Peter Breitenlohner <peb@mppmu.mpg.de> + + * Imported release 1.13 from savannah.nongnu.org. + * patch-[01]?-* (removed): Included in 1.13. + + * patch-20-rpl_malloc (new): Avoid implicit decl of malloc(). + * patch-21-win32 (new): Avoid unnecessary warning in WIN32 code. + +2010-03-09 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-12-set_program_name: Replace kpse_set_progname() by + kpse_set_program_name(). + +2010-02-24 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-10-mmap-for-WIN32 (new): Former MIKTEX code for mmap + from Fabrice Popineau (?) now used for all WIN32 variants. + * patch-11-win32-fork-and-pipe (new): WIN32 specific replacement + for fork and pipe, using code from Akira Kakuto. + +2010-02-21 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-07-always-undef (new): Always undefine min/max before + redefining them (for MinGW32). + * patch-08-HAVE_MMAP (new): #include <sys/mman.h> only + #if defined(HAVE_MMAP) (for MinGW32). + * patch-09-sleep (new): Use Sleep and #include <stdlib.h> + (for WIN32/MinGW32). + +2010-01-29 Karl Berry <karl@tug.org> + + * patch-06-mathptmx (new): Do not use \usepackage{mathptmx} + in test_dvipng.tex. + +2009-06-12 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-05-warnings (new): Avoid more compiler warnings. + +2009-06-09 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-04-static (new): Avoid warnings when compiling with + 'gcc --Wmissing-prototypes'. + +2009-02-22 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-03-have-ft2 (new): Bug fix - skip FT2 code when + compiling without FT2 library. + +2009-03-25 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-02-use-ifdef (new): Use #ifdef instead of #if to avoid + preprocessor warnings. + +2009-03-24 Peter Breitenlohner <peb@mppmu.mpg.de> + + * patch-01-portability (new): Portability fix - put variable + declarations at the beginning of the block. + diff --git a/Build/source/texk/dvipng/dvipng-PATCHES/TL-Changes b/Build/source/texk/dvipng/dvipng-PATCHES/TL-Changes new file mode 100644 index 00000000000..15cd6bb63db --- /dev/null +++ b/Build/source/texk/dvipng/dvipng-PATCHES/TL-Changes @@ -0,0 +1,18 @@ +Changes applied to the dvipng-1.15 tree as obtained from: + http://savannah.nongnu.org/files/?group=dvipng + +Removed: + configure + config.h + install-sh + mkinstalldirs + +Created Autoconf macro files ../m4/gs-device.m4 and ../m4/makeinfo.m4 + adapting code in aclocal.m4. + +Copied these files to ../doc/: + dvipng.texi + install.texi + macros.texi + readme.texi + diff --git a/Build/source/texk/dvipng/dvipng-PATCHES/patch-02-const b/Build/source/texk/dvipng/dvipng-PATCHES/patch-02-const new file mode 100644 index 00000000000..f10faef62e4 --- /dev/null +++ b/Build/source/texk/dvipng/dvipng-PATCHES/patch-02-const @@ -0,0 +1,15 @@ +diff -ur dvipng-1.15.orig/special.c dvipng-1.15/special.c +--- dvipng-1.15.orig/special.c 2015-03-02 20:33:55.000000000 +0100 ++++ dvipng-1.15/special.c 2015-03-03 12:51:18.000000000 +0100 +@@ -44,9 +44,9 @@ + struct pscode { + struct pscode* next; + char* special; /* complete special */ +- char* code; /* PS string, null if a file */ ++ const char* code; /* PS string, null if a file */ + char* filename; /* file name, null if a string */ +- char* postcode; /* post PS string */ ++ const char* postcode; /* post PS string */ + struct filemmap fmmap; /* file mmap */ + }; + diff --git a/Build/source/texk/dvipng/dvipng-PATCHES/patch-03-programname b/Build/source/texk/dvipng/dvipng-PATCHES/patch-03-programname new file mode 100644 index 00000000000..e106c3a0789 --- /dev/null +++ b/Build/source/texk/dvipng/dvipng-PATCHES/patch-03-programname @@ -0,0 +1,62 @@ +diff -ur dvipng-1.15.orig/misc.c dvipng-1.15/misc.c +--- dvipng-1.15.orig/misc.c 2015-03-02 20:33:56.000000000 +0100 ++++ dvipng-1.15/misc.c 2015-03-03 13:35:10.000000000 +0100 +@@ -47,24 +47,43 @@ + int32_t number; /* Temporary storage for numeric parameter */ + char *dviname=NULL; /* Name of dvi file */ + char *outname=NULL; /* Name of output file */ ++ char *base; /* basename of argv[0] */ + +- if (argv[0]) { ++#ifdef HAVE_LIBKPATHSEA ++ /* we certainly don't want to modify argv[0]. */ ++ programname = xstrdup (argv[0] ? argv[0] : PACKAGE_NAME); ++# ifdef HAVE_KPSE_PROGRAM_BASENAME ++ base = kpse_program_basename (programname); ++# else ++ base = xstrdup (xbasename (programname)); ++ { ++ char *dot = strrchr (base, '.'); ++ if (dot && FILESTRCASEEQ (dot, ".exe")) ++ *dot = 0; ++ } ++# endif ++#else ++ /* we certainly don't want to modify argv[0]. */ ++ programname = strdup (argv[0] ? argv[0] : PACKAGE_NAME); ++ base = strrchr (programname, '/'); ++ if (base) ++ base++; ++ else ++ base = programname; ++#endif + #ifdef HAVE_GDIMAGEGIF +- programname=strrchr(argv[0],'/'); +- if (programname!=NULL) +- programname++; +- else +- programname=argv[0]; +- if (strncmp(programname,"dvigif",6)==0) +- option_flags |= GIF_OUTPUT; ++# ifdef HAVE_LIBKPATHSEA ++ if (FILESTRCASEEQ (base, "dvigif")) ++# else ++ if (strncmp(programname,"dvigif",6)==0) ++# endif ++ option_flags |= GIF_OUTPUT; + #endif +- programname=argv[0]; +- Message(BE_NONQUIET,"This is %s",programname); +- if (strcmp(basename(programname),PACKAGE_NAME)!=0) +- Message(BE_NONQUIET," (%s)", PACKAGE_NAME); +- Message(BE_NONQUIET," %s Copyright 2002-2015 Jan-Ake Larsson\n", +- PACKAGE_VERSION); +- } ++ Message(BE_NONQUIET,"This is %s",programname); ++ if (strcmp(base,PACKAGE_NAME)!=0) ++ Message(BE_NONQUIET," (%s)", PACKAGE_NAME); ++ Message(BE_NONQUIET," %s Copyright 2002-2015 Jan-Ake Larsson\n", ++ PACKAGE_VERSION); + + for (i=1; i<argc; i++) { + if (*argv[i]=='-') { diff --git a/Build/source/texk/dvipng/dvipng-PATCHES/patch-06-WIN32 b/Build/source/texk/dvipng/dvipng-PATCHES/patch-06-WIN32 new file mode 100644 index 00000000000..252b15abee5 --- /dev/null +++ b/Build/source/texk/dvipng/dvipng-PATCHES/patch-06-WIN32 @@ -0,0 +1,30 @@ +diff -ur dvipng-1.15.orig/dvipng.c dvipng-1.15/dvipng.c +--- dvipng-1.15.orig/dvipng.c 2015-03-02 20:33:56.000000000 +0100 ++++ dvipng-1.15/dvipng.c 2015-03-03 13:04:09.000000000 +0100 +@@ -79,6 +79,10 @@ + kpse_set_program_enabled (kpse_pk_format, makeTexPK, kpse_src_compile); + #endif + ++#ifdef WIN32 ++ texlive_gs_init (); ++#endif ++ + initcolor(); + parsestdin = DecodeArgs(argc, argv); + +diff -ur -x COPYING.gd dvipng-1.15.orig/special.c dvipng-1.15/special.c +--- dvipng-1.15.orig/special.c 2015-03-03 12:51:18.000000000 +0100 ++++ dvipng-1.15/special.c 2015-03-03 13:04:09.000000000 +0100 +@@ -28,11 +28,8 @@ + #ifndef WIN32 + #include <sys/wait.h> + #else /* WIN32 */ +-#include <fcntl.h> +-#include <io.h> +-#include <process.h> ++#undef pipe + #define pipe(p) _pipe(p, 65536, O_BINARY | _O_NOINHERIT) +-#define snprintf _snprintf + #endif /* WIN32 */ + #endif + diff --git a/Build/source/texk/dvipng/dvipng-PATCHES/patch-07-w64-ptr b/Build/source/texk/dvipng/dvipng-PATCHES/patch-07-w64-ptr new file mode 100644 index 00000000000..4c4ff5b6064 --- /dev/null +++ b/Build/source/texk/dvipng/dvipng-PATCHES/patch-07-w64-ptr @@ -0,0 +1,57 @@ +diff -ur dvipng-1.15.orig/pk.c dvipng-1.15/pk.c +--- dvipng-1.15.orig/pk.c 2015-03-02 20:33:56.000000000 +0100 ++++ dvipng-1.15/pk.c 2015-03-04 08:26:11.000000000 +0100 +@@ -347,7 +347,7 @@ + position = skip_specials(position); + while (*position != PK_POST) { + DEBUG_PRINT(DEBUG_PK,("\n @%ld PK CHAR:\t%d", +- (long)position - (long)tfontp->fmmap.data, *position)); ++ (long)((char *)position - tfontp->fmmap.data), *position)); + if ((tcharptr = malloc(sizeof(struct char_entry))) == NULL) + Fatal("cannot allocate space for char_entry"); + tcharptr->flag_byte = *position; +diff -ur dvipng-1.15.orig/special.c dvipng-1.15/special.c +--- dvipng-1.15.orig/special.c 2015-03-03 13:04:09.000000000 +0100 ++++ dvipng-1.15/special.c 2015-03-03 13:11:16.000000000 +0100 +@@ -214,7 +214,7 @@ + savestdout = _dup(fileno(stdout)); + _dup2(pngpipe[WRITE_END], fileno(stdout)); + if ((hchild= +- (HANDLE)spawnlp(_P_NOWAIT, GS_PATH, GS_PATH, device, resolution, ++ (HANDLE)_spawnlp(_P_NOWAIT, GS_PATH, GS_PATH, device, resolution, + "-dBATCH", "-dNOPAUSE", "-q", "-sOutputFile=-", + "-dTextAlphaBits=4", "-dGraphicsAlphaBits=4", + (option_flags & NO_GSSAFER) ? "-": "-dSAFER", +diff -ur dvipng-1.15.orig/tfm.c dvipng-1.15/tfm.c +--- dvipng-1.15.orig/tfm.c 2015-03-02 20:33:56.000000000 +0100 ++++ dvipng-1.15/tfm.c 2015-03-04 08:27:58.000000000 +0100 +@@ -56,7 +56,7 @@ + position=(unsigned char*)fmmap.data+24+lh*4; + while(c <= ec) { + DEBUG_PRINT(DEBUG_TFM,("\n@%ld TFM METRICS:\t", +- (long)position - (long)fmmap.data)); ++ (long)((char *)position - fmmap.data))); + if ((tcharptr=malloc(sizeof(struct char_entry)))==NULL) + Fatal("cannot allocate memory for TFM char entry"); + tcharptr->data=NULL; +diff -ur dvipng-1.15.orig/vf.c dvipng-1.15/vf.c +--- dvipng-1.15.orig/vf.c 2015-03-02 20:33:56.000000000 +0100 ++++ dvipng-1.15/vf.c 2015-03-04 08:29:50.000000000 +0100 +@@ -80,7 +80,7 @@ + position += 8; + while(*position >= FNT_DEF1 && *position <= FNT_DEF4) { + DEBUG_PRINT(DEBUG_VF,("\n @%ld VF:\t%s", +- (long)position - (long)tfontp->fmmap.data, ++ (long)((char *)position - tfontp->fmmap.data), + dvi_commands[*position])); + FontDef(position,tfontp); + length = dvi_commandlength[*position]; +@@ -95,7 +95,7 @@ + /* Read char definitions */ + while(*position < FNT_DEF1) { + DEBUG_PRINT(DEBUG_VF,("\n@%ld VF CHAR:\t", +- (long)position - (long)tfontp->fmmap.data)); ++ (long)((char *)position - tfontp->fmmap.data))); + if ((tcharptr=malloc(sizeof(struct char_entry)))==NULL) + Fatal("cannot allocate memory for VF char entry"); + switch (*position) { |