comparison src/gnuplot-1-fixes.patch @ 4343:16d2b997c31b

gnuplot: update t 5.0.5 * src/gnuplot-1-fixes.patch: update patch * src/gnuplot.mk: update version, checksum
author John D
date Fri, 20 Jan 2017 12:15:15 -0500
parents 8f864b4ea93b
children 6aa7dd77d82c
comparison
equal deleted inserted replaced
4342:5eef82cc581c 4343:16d2b997c31b
1 diff -ur a/config/mingw/Makefile b/config/mingw/Makefile 1 diff -ur gnuplot-5.0.5.orig/config/mingw/Makefile gnuplot-5.0.5/config/mingw/Makefile
2 --- a/config/mingw/Makefile 2016-03-31 12:40:56.000000000 +0900 2 --- gnuplot-5.0.5.orig/config/mingw/Makefile 2017-01-20 12:00:04.522364256 -0500
3 +++ b/config/mingw/Makefile 2016-08-09 12:56:38.576941000 +0900 3 +++ gnuplot-5.0.5/config/mingw/Makefile 2017-01-20 12:10:38.856621795 -0500
4 @@ -119,14 +119,14 @@ 4 @@ -101,15 +101,16 @@
5 # Uncomment the following lines to compile it.
6 #WXT=1
7 #CAIROLIBS=1
8 +WX_CONFIG ?= wx-config
9
10 # Build qt terminal?
11 #QT = 1
12 # specify QT installation directory
13 #QT_DIR = /c/Qt/5.2.1/mingw48_32
14 ifndef MINGW64
15 -QT_DIR = /d/Source/Qt-5.2.1-mingw/5.2.1/mingw48_32
16 +QT_DIR ?= /d/Source/Qt-5.2.1-mingw/5.2.1/mingw48_32
17 else
18 -QT_DIR = /mingw64
19 +QT_DIR ?= /mingw64
20 endif
21
22 # Uncomment the following line to select the lua/tikz terminal
23 @@ -119,14 +120,14 @@
5 # Requires libcaca version 0.99.beta15 or newer. A post-beta18 24 # Requires libcaca version 0.99.beta15 or newer. A post-beta18
6 # svn version is recommended since it contains an improved 25 # svn version is recommended since it contains an improved
7 # win32 backend. 26 # win32 backend.
8 -CACA=1 27 -CACA=1
9 +#CACA=1 28 +#CACA=1
16 -CERF=1 35 -CERF=1
17 +#CERF=1 36 +#CERF=1
18 37
19 # Below you can adapt paths according to your software setup: 38 # Below you can adapt paths according to your software setup:
20 39
21 @@ -155,7 +155,7 @@ 40 @@ -155,7 +156,7 @@
22 DESTDIR = "$(PROGRAMFILES)/gnuplot" 41 DESTDIR = "$(PROGRAMFILES)/gnuplot"
23 42
24 # Do you want some special optimization / flags? 43 # Do you want some special optimization / flags?
25 -#CFLAGS += 44 -#CFLAGS +=
26 +CFLAGS += -DDISABLE_SPACE_RAISES_CONSOLE 45 +CFLAGS += -DDISABLE_SPACE_RAISES_CONSOLE
27 ifdef CLANG 46 ifdef CLANG
28 CFLAGS += -fcolor-diagnostics -fansi-escape-codes 47 CFLAGS += -fcolor-diagnostics -fansi-escape-codes
29 CFLAGS += -Wno-error=incompatible-ms-struct -Wno-ignored-attributes 48 CFLAGS += -Wno-error=incompatible-ms-struct -Wno-ignored-attributes
30 @@ -171,8 +171,8 @@ 49 @@ -171,8 +172,8 @@
31 # http://go.microsoft.com/fwlink/?LinkId=154968 50 # http://go.microsoft.com/fwlink/?LinkId=154968
32 # We need to explicitly set the correct path here since we also need 51 # We need to explicitly set the correct path here since we also need
33 # adjust the include and library paths. 52 # adjust the include and library paths.
34 -HHWPATH = $(PROGRAMFILES32)/HTML\ Help\ Workshop/ 53 -HHWPATH = $(PROGRAMFILES32)/HTML\ Help\ Workshop/
35 -HHC = $(HHWPATH)hhc 54 -HHC = $(HHWPATH)hhc
36 +#HHWPATH = $(PROGRAMFILES32)/HTML\ Help\ Workshop/ 55 +#HHWPATH = $(PROGRAMFILES32)/HTML\ Help\ Workshop/
37 +#HHC = $(HHWPATH)hhc 56 +#HHC = $(HHWPATH)hhc
38 57
39 # Choose which resource compiler you want to use (GNU windres or MS rc): 58 # Choose which resource compiler you want to use (GNU windres or MS rc):
40 GNU_RC = 1 59 GNU_RC = 1
41 @@ -186,7 +186,7 @@ 60 @@ -186,7 +187,7 @@
42 61
43 # Inno Setup Compiler 62 # Inno Setup Compiler
44 # get it from: http://www.jrsoftware.org/isdl.php 63 # get it from: http://www.jrsoftware.org/isdl.php
45 -ISCC = $(PROGRAMFILES32)/Inno\ Setup\ 5/iscc 64 -ISCC = $(PROGRAMFILES32)/Inno\ Setup\ 5/iscc
46 +#ISCC = $(PROGRAMFILES32)/Inno\ Setup\ 5/iscc 65 +#ISCC = $(PROGRAMFILES32)/Inno\ Setup\ 5/iscc
47 66
48 # Directory that might contain extra files to be shipped with the installer. 67 # Directory that might contain extra files to be shipped with the installer.
49 # This should include dependencies like DLLs, but also fontconfig configuration files. 68 # This should include dependencies like DLLs, but also fontconfig configuration files.
50 @@ -514,7 +514,7 @@
51 FULLVERSION := $(MAINVERSION) patchlevel $(PATCHLEVEL)
52
53
54 -default: $(TARGET) $(MENUFILE) support
55 +default: $(TARGET) $(MENUFILE) # support
56
57 console:
58 $(MAKE) TARGET=gnuplot.exe default
59 @@ -556,8 +556,8 @@
60 $(CC) -c $(CFLAGS) $(CFLAGSEXTRA) -MMD -MT '$*.$$(O)' -MF $*.d -o $@ $<
61
62 LDLIBS = -lkernel32 -lgdi32 -lwinspool -lcomdlg32 -lcomctl32 -ladvapi32 -lshell32 -lmsimg32 -lgdiplus
63 -LDLIBS += -lhtmlhelp
64 -LDFLAGS2 += -L$(HHWPATH)lib
65 +#LDLIBS += -lhtmlhelp
66 +#LDFLAGS2 += -L$(HHWPATH)lib
67 ifdef MINGW64
68 LDFLAGS2 += -L.
69 endif
70 diff -ur gnuplot-5.0.4.orig/src/command.c gnuplot-5.0.4/src/command.c
71 --- gnuplot-5.0.4.orig/src/command.c 2016-07-21 13:47:51.987062163 -0400
72 +++ gnuplot-5.0.4/src/command.c 2016-07-21 13:48:27.860546987 -0400
73 @@ -125,7 +125,7 @@
74 # endif
75 #endif /* _Windows */
76
77 -#ifdef _Windows
78 +#ifdef IGNORE_Windows
79 # include <windows.h>
80 # ifdef __MSC__
81 # include <malloc.h>
82 @@ -2535,6 +2535,7 @@
83 void
84 help_command()
85 {
86 +#ifndef __MINGW32__
87 HWND parent;
88
89 c_token++;
90 @@ -2570,6 +2571,7 @@
91 link.fIndexOnFail = TRUE;
92 HtmlHelp(parent, winhelpname, HH_KEYWORD_LOOKUP, (DWORD_PTR)&link);
93 }
94 +#endif
95 }
96 #else /* !_Windows */
97 #ifndef VMS
98 diff -ur gnuplot-5.0.4.orig/src/internal.c gnuplot-5.0.4/src/internal.c
99 --- gnuplot-5.0.4.orig/src/internal.c 2016-07-21 13:47:52.006061890 -0400
100 +++ gnuplot-5.0.4/src/internal.c 2016-07-21 13:48:27.861546973 -0400
101 @@ -47,7 +47,7 @@
102
103 #include <math.h>
104
105 -#ifndef _WIN64
106 +#if !defined(__MINGW64_VERSION_MAJOR)
107 /*
108 * FIXME: This is almost certainly out of date on linux, since the matherr
109 * mechanism has been replaced by math_error() and supposedly is only
110 diff -ur gnuplot-5.0.4.orig/src/syscfg.h gnuplot-5.0.4/src/syscfg.h
111 --- gnuplot-5.0.4.orig/src/syscfg.h 2016-07-21 13:47:51.994062063 -0400
112 +++ gnuplot-5.0.4/src/syscfg.h 2016-07-21 13:49:02.401050952 -0400
113 @@ -345,7 +345,11 @@
114 #endif
115
116 #ifndef GP_MATHERR
117 -# define GP_MATHERR matherr
118 +# if __MINGW32__
119 +# define GP_MATHERR _matherr
120 +#else
121 +# define GP_MATHERR matherr
122 +#endif
123 #endif
124
125 #ifdef HAVE_STRUCT_EXCEPTION_IN_MATH_H
126 diff -ur gnuplot-5.0.4.orig/config/mingw/Makefile gnuplot-5.0.4/config/mingw/Makefile
127 --- gnuplot-5.0.4.orig/config/mingw/Makefile 2016-12-27 08:55:41.906600912 -0500
128 +++ gnuplot-5.0.4/config/mingw/Makefile 2016-12-27 08:57:30.033448266 -0500
129 @@ -101,6 +101,7 @@
130 # Uncomment the following lines to compile it.
131 #WXT=1
132 #CAIROLIBS=1
133 +WX_CONFIG ?= wx-config
134
135 # Build qt terminal?
136 #QT = 1
137 @@ -422,9 +423,9 @@ 69 @@ -422,9 +423,9 @@
138 70
139 ifdef WXT 71 ifdef WXT
140 CFLAGS += -DWXWIDGETS 72 CFLAGS += -DWXWIDGETS
141 - WXT_CXXFLAGS := $(shell wx-config --cxxflags) 73 - WXT_CXXFLAGS := $(shell wx-config --cxxflags)
144 - WX_LIBS := $(shell wx-config --libs | sed -e "s+-Wl,--subsystem,windows++g" -e "s+-mwindows++g") 76 - WX_LIBS := $(shell wx-config --libs | sed -e "s+-Wl,--subsystem,windows++g" -e "s+-mwindows++g")
145 + WX_LIBS := $(shell $(WX_CONFIG) --libs | sed -e "s+-Wl,--subsystem,windows++g" -e "s+-mwindows++g") 77 + WX_LIBS := $(shell $(WX_CONFIG) --libs | sed -e "s+-Wl,--subsystem,windows++g" -e "s+-mwindows++g")
146 WX_OBJS = wxt_gui.$(O) 78 WX_OBJS = wxt_gui.$(O)
147 endif 79 endif
148 80
149 diff -ur gnuplot-5.0.4.orig/src/wxterminal/wxt_gui.h gnuplot-5.0.4/src/wxterminal/wxt_gui.h 81 @@ -514,7 +515,7 @@
150 --- gnuplot-5.0.4.orig/src/wxterminal/wxt_gui.h 2016-12-27 12:29:33.624151543 -0500 82 FULLVERSION := $(MAINVERSION) patchlevel $(PATCHLEVEL)
151 +++ gnuplot-5.0.4/src/wxterminal/wxt_gui.h 2016-12-27 12:30:09.419977685 -0500 83
152 @@ -174,7 +174,7 @@ 84
153 # ifndef _WIN32_WINNT 85 -default: $(TARGET) $(MENUFILE) support
154 # define _WIN32_WINNT 0x0500 86 +default: $(TARGET) $(MENUFILE) #support
155 # endif 87
156 -# include "Windows.h" 88 console:
157 +# include "windows.h" 89 $(MAKE) TARGET=gnuplot.exe default
158 # include "win/wtext.h" 90 @@ -556,8 +557,8 @@
159 # include "win/winmain.h" 91 $(CC) -c $(CFLAGS) $(CFLAGSEXTRA) -MMD -MT '$*.$$(O)' -MF $*.d -o $@ $<
92
93 LDLIBS = -lkernel32 -lgdi32 -lwinspool -lcomdlg32 -lcomctl32 -ladvapi32 -lshell32 -lmsimg32 -lgdiplus
94 -LDLIBS += -lhtmlhelp
95 -LDFLAGS2 += -L$(HHWPATH)lib
96 +#LDLIBS += -lhtmlhelp
97 +#LDFLAGS2 += -L$(HHWPATH)lib
98 ifdef MINGW64
99 LDFLAGS2 += -L.
100 endif
101 diff -ur gnuplot-5.0.5.orig/src/command.c gnuplot-5.0.5/src/command.c
102 --- gnuplot-5.0.5.orig/src/command.c 2017-01-20 12:00:04.431361673 -0500
103 +++ gnuplot-5.0.5/src/command.c 2017-01-20 12:04:46.221964530 -0500
104 @@ -125,7 +125,7 @@
160 # endif 105 # endif
161 diff -ur gnuplot-5.0.4.orig/config/mingw/Makefile gnuplot-5.0.4/config/mingw/Makefile 106 #endif /* _Windows */
162 --- gnuplot-5.0.4.orig/config/mingw/Makefile 2016-12-27 12:42:32.612130064 -0500
163 +++ gnuplot-5.0.4/config/mingw/Makefile 2016-12-27 12:43:31.994500570 -0500
164 @@ -108,9 +108,9 @@
165 # specify QT installation directory
166 #QT_DIR = /c/Qt/5.2.1/mingw48_32
167 ifndef MINGW64
168 -QT_DIR = /d/Source/Qt-5.2.1-mingw/5.2.1/mingw48_32
169 +QT_DIR ?= /d/Source/Qt-5.2.1-mingw/5.2.1/mingw48_32
170 else
171 -QT_DIR = /mingw64
172 +QT_DIR ?= /mingw64
173 endif
174 107
175 # Uncomment the following line to select the lua/tikz terminal 108 -#ifdef _Windows
109 +#ifdef IGNORE_Windows
110 # include <windows.h>
111 # ifdef __MSC__
112 # include <malloc.h>
113 @@ -2537,6 +2537,7 @@
114 void
115 help_command()
116 {
117 +#ifndef __MINGW32__
118 HWND parent;
119
120 c_token++;
121 @@ -2572,6 +2573,7 @@
122 link.fIndexOnFail = TRUE;
123 HtmlHelp(parent, winhelpname, HH_KEYWORD_LOOKUP, (DWORD_PTR)&link);
124 }
125 +#endif
126 }
127 #else /* !_Windows */
128 #ifndef VMS
129 diff -ur gnuplot-5.0.5.orig/src/internal.c gnuplot-5.0.5/src/internal.c
130 --- gnuplot-5.0.5.orig/src/internal.c 2017-01-20 12:00:04.456279047 -0500
131 +++ gnuplot-5.0.5/src/internal.c 2017-01-20 12:05:51.920459353 -0500
132 @@ -47,7 +47,7 @@
133
134 #include <math.h>
135
136 -#ifndef _WIN64
137 +#if !defined(__MINGW64_VERSION_MAJOR)
138 /*
139 * FIXME: This is almost certainly out of date on linux, since the matherr
140 * mechanism has been replaced by math_error() and supposedly is only
141 diff -ur gnuplot-5.0.5.orig/src/syscfg.h gnuplot-5.0.5/src/syscfg.h
142 --- gnuplot-5.0.5.orig/src/syscfg.h 2017-01-20 12:00:04.441111950 -0500
143 +++ gnuplot-5.0.5/src/syscfg.h 2017-01-20 12:06:54.955043738 -0500
144 @@ -346,6 +346,11 @@
145
146 #ifndef GP_MATHERR
147 # define GP_MATHERR matherr
148 +# if __MINGW32__
149 +# define GP_MATHERR _matherr
150 +#else
151 +# define GP_MATHERR matherr
152 +#endif
153 #endif
154
155 #ifdef HAVE_STRUCT_EXCEPTION_IN_MATH_H