summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2017-04-19 22:35:23 +0200
committerAndreas K. Hüttel <dilfridge@gentoo.org>2017-04-19 22:35:47 +0200
commit4bd7efed70836efa9a85f5089ac5a5855b6249b2 (patch)
treefcadb39a3d47a916461916a45873adabec39e806 /sci-visualization
parentmozconfig-v6.52.eclass: remove obsolete USE=skia conditional on arm (diff)
downloadgentoo-4bd7efed70836efa9a85f5089ac5a5855b6249b2.tar.gz
gentoo-4bd7efed70836efa9a85f5089ac5a5855b6249b2.tar.bz2
gentoo-4bd7efed70836efa9a85f5089ac5a5855b6249b2.zip
sci-visualization/spyview: Roll some patches together
Package-Manager: Portage-2.3.5, Repoman-2.3.2
Diffstat (limited to 'sci-visualization')
-rw-r--r--sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-2.patch113
-rw-r--r--sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-3.patch142
-rw-r--r--sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-9.patch (renamed from sci-visualization/spyview/files/spyview-20150124-gcc6cxx14.patch)50
-rw-r--r--sci-visualization/spyview/spyview-20150124-r1.ebuild4
4 files changed, 41 insertions, 268 deletions
diff --git a/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-2.patch b/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-2.patch
deleted file mode 100644
index f23838ced7d5..000000000000
--- a/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-2.patch
+++ /dev/null
@@ -1,113 +0,0 @@
-diff --git a/spyview/ImageData.C b/spyview/ImageData.C
-index a9b2c17..29decea 100644
---- a/spyview/ImageData.C
-+++ b/spyview/ImageData.C
-@@ -180,12 +180,12 @@ void ImageData::load_int(int *data,
- double y1, double y2,
- double z1, double z2)
- {
-- xmin = isnan(x1) ? x1 : 0;
-- xmax = isnan(x2) ? x2 : width-1;
-- ymin = isnan(y1) ? y1 : 0;
-- ymax = isnan(y2) ? y2 : height-1;
-- qmin = isnan(z1) ? z1 : 0;
-- qmax = isnan(z2) ? z2 : QUANT_MAX;
-+ xmin = std::isnan(x1) ? x1 : 0;
-+ xmax = std::isnan(x2) ? x2 : width-1;
-+ ymin = std::isnan(y1) ? y1 : 0;
-+ ymax = std::isnan(y2) ? y2 : height-1;
-+ qmin = std::isnan(z1) ? z1 : 0;
-+ qmax = std::isnan(z2) ? z2 : QUANT_MAX;
- width = w;
- height = h;
-
-@@ -214,10 +214,10 @@ void ImageData::load_raw(double *data,
- double x1, double x2,
- double y1, double y2)
- {
-- xmin = isnan(x1) ? x1 : 0;
-- xmax = isnan(x2) ? x2 : width-1;
-- ymin = isnan(y1) ? y1 : 0;
-- ymax = isnan(y2) ? y2 : height-1;
-+ xmin = std::isnan(x1) ? x1 : 0;
-+ xmax = std::isnan(x2) ? x2 : width-1;
-+ ymin = std::isnan(y1) ? y1 : 0;
-+ ymax = std::isnan(y2) ? y2 : height-1;
- width = w;
- height = h;
-
-@@ -762,7 +762,7 @@ int ImageData::load_Delft(const char *name)
-
- //if (sscanf(linebuffer, "%*f\t%lf\t%lf", &last_sweep, &last_data) != 2)
- last_data = parse_reading(linebuffer, gp_column);
-- if (isnan(last_data))
-+ if (std::isnan(last_data))
- {
- //info("line\n%s\ncgp_column %d\nval %e\n", linebuffer, gp_column, last_data);
- badfilec("invalid data in delft file at line %d\nline: %s\n", nread, linebuffer);
-@@ -1116,7 +1116,7 @@ void ImageData::gamma(double gamma, double epsilon)
- v2 = pow(v1, gamma);
- //if (!isfinite(v2))
- //info("v1 %e v2 %e eps %e\n", v1, v2, epsilon);
-- if (isnan(v2))
-+ if (std::isnan(v2))
- raw_data[i] = 0;
- else
- raw_data[i] = v2;
-@@ -2385,7 +2385,7 @@ int MTX_Data::load_file(const char *name)
- float tmp;
- if (fread(&tmp, bytes, 1, fp) != 1)
- badfilec( "Short read on mtx file: %s", filename.c_str());
-- if (isnan(tmp)) warn( "nan at %d %d %d", i, j, k);
-+ if (std::isnan(tmp)) warn( "nan at %d %d %d", i, j, k);
- getData(i,j,k) = tmp;
- }
- else if (bytes == 8)
-@@ -3419,7 +3419,7 @@ int MTX_Data::load_dat_meta(const char *name, int col)
- else // otherwise try to get new data
- {
- val = nextreading(fp, col, lnum);
-- if (isnan(val)) // failed to read a point
-+ if (std::isnan(val)) // failed to read a point
- {
- if (npoints == 0)
- {
-diff --git a/spyview/ImageWindow.C b/spyview/ImageWindow.C
-index 134b198..e1a8ecb 100644
---- a/spyview/ImageWindow.C
-+++ b/spyview/ImageWindow.C
-@@ -696,7 +696,7 @@ int ImageWindow::handle(int event)
- */
-
- case FL_PUSH:
-- if(isnan(lastFocus) && stupid_windows_focus)
-+ if(std::isnan(lastFocus) && stupid_windows_focus)
- {
- fprintf(stderr,"Ate unfocused click. This apparently never happens.\n");
- hungryFocus = true;
-diff --git a/spyview/bisector.H b/spyview/bisector.H
-index 039c5ff..4326da7 100644
---- a/spyview/bisector.H
-+++ b/spyview/bisector.H
-@@ -105,18 +105,18 @@ public:
- }
- else
- {
-- if(fxp < 0 && (isnan(x1) || (fxp > fx1)))
-+ if(fxp < 0 && (std::isnan(x1) || (fxp > fx1)))
- {
- x1 = xp;
- fx1 = fxp;
- }
-- else if(fxp > 0 && (isnan(x2) || (fxp < fx2)))
-+ else if(fxp > 0 && (std::isnan(x2) || (fxp < fx2)))
- {
- x2 = xp;
- fx2 = fxp;
- }
- }
-- bisection = !(isnan(x1) || isnan(x2));
-+ bisection = !(std::isnan(x1) || std::isnan(x2));
- if(bisection)
- {
- // printf("Bisection step: [%g,%g] {%g,%g}\n", x1,x2,fx1,fx2);
diff --git a/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-3.patch b/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-3.patch
deleted file mode 100644
index 09548b87a3ac..000000000000
--- a/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-3.patch
+++ /dev/null
@@ -1,142 +0,0 @@
-diff --git a/spyview/ImageData.C b/spyview/ImageData.C
-index 29decea..eaac7a6 100644
---- a/spyview/ImageData.C
-+++ b/spyview/ImageData.C
-@@ -9,6 +9,9 @@
- #include "mypam.h"
- #include "../config.h"
-
-+#include <cmath>
-+using std::isnan;
-+
- #include <algorithm>
- // From http://www.redhat.com/docs/manuals/enterprise/RHEL-3-Manual/gcc/variadic-macros.html
-
-@@ -180,12 +183,12 @@ void ImageData::load_int(int *data,
- double y1, double y2,
- double z1, double z2)
- {
-- xmin = std::isnan(x1) ? x1 : 0;
-- xmax = std::isnan(x2) ? x2 : width-1;
-- ymin = std::isnan(y1) ? y1 : 0;
-- ymax = std::isnan(y2) ? y2 : height-1;
-- qmin = std::isnan(z1) ? z1 : 0;
-- qmax = std::isnan(z2) ? z2 : QUANT_MAX;
-+ xmin = isnan(x1) ? x1 : 0;
-+ xmax = isnan(x2) ? x2 : width-1;
-+ ymin = isnan(y1) ? y1 : 0;
-+ ymax = isnan(y2) ? y2 : height-1;
-+ qmin = isnan(z1) ? z1 : 0;
-+ qmax = isnan(z2) ? z2 : QUANT_MAX;
- width = w;
- height = h;
-
-@@ -214,10 +217,10 @@ void ImageData::load_raw(double *data,
- double x1, double x2,
- double y1, double y2)
- {
-- xmin = std::isnan(x1) ? x1 : 0;
-- xmax = std::isnan(x2) ? x2 : width-1;
-- ymin = std::isnan(y1) ? y1 : 0;
-- ymax = std::isnan(y2) ? y2 : height-1;
-+ xmin = isnan(x1) ? x1 : 0;
-+ xmax = isnan(x2) ? x2 : width-1;
-+ ymin = isnan(y1) ? y1 : 0;
-+ ymax = isnan(y2) ? y2 : height-1;
- width = w;
- height = h;
-
-@@ -762,7 +765,7 @@ int ImageData::load_Delft(const char *name)
-
- //if (sscanf(linebuffer, "%*f\t%lf\t%lf", &last_sweep, &last_data) != 2)
- last_data = parse_reading(linebuffer, gp_column);
-- if (std::isnan(last_data))
-+ if (isnan(last_data))
- {
- //info("line\n%s\ncgp_column %d\nval %e\n", linebuffer, gp_column, last_data);
- badfilec("invalid data in delft file at line %d\nline: %s\n", nread, linebuffer);
-@@ -1116,7 +1119,7 @@ void ImageData::gamma(double gamma, double epsilon)
- v2 = pow(v1, gamma);
- //if (!isfinite(v2))
- //info("v1 %e v2 %e eps %e\n", v1, v2, epsilon);
-- if (std::isnan(v2))
-+ if (isnan(v2))
- raw_data[i] = 0;
- else
- raw_data[i] = v2;
-@@ -2385,7 +2388,7 @@ int MTX_Data::load_file(const char *name)
- float tmp;
- if (fread(&tmp, bytes, 1, fp) != 1)
- badfilec( "Short read on mtx file: %s", filename.c_str());
-- if (std::isnan(tmp)) warn( "nan at %d %d %d", i, j, k);
-+ if (isnan(tmp)) warn( "nan at %d %d %d", i, j, k);
- getData(i,j,k) = tmp;
- }
- else if (bytes == 8)
-@@ -3419,7 +3422,7 @@ int MTX_Data::load_dat_meta(const char *name, int col)
- else // otherwise try to get new data
- {
- val = nextreading(fp, col, lnum);
-- if (std::isnan(val)) // failed to read a point
-+ if (isnan(val)) // failed to read a point
- {
- if (npoints == 0)
- {
-diff --git a/spyview/ImageWindow.C b/spyview/ImageWindow.C
-index e1a8ecb..eeae649 100644
---- a/spyview/ImageWindow.C
-+++ b/spyview/ImageWindow.C
-@@ -12,6 +12,9 @@
- #include "ImageWindow_Module.H"
- #include <ctype.h>
-
-+#include <cmath>
-+using std::isnan;
-+
- #include "mypam.h"
-
- #ifdef WIN32
-@@ -696,7 +699,7 @@ int ImageWindow::handle(int event)
- */
-
- case FL_PUSH:
-- if(std::isnan(lastFocus) && stupid_windows_focus)
-+ if(isnan(lastFocus) && stupid_windows_focus)
- {
- fprintf(stderr,"Ate unfocused click. This apparently never happens.\n");
- hungryFocus = true;
-diff --git a/spyview/bisector.H b/spyview/bisector.H
-index 4326da7..c7e64a6 100644
---- a/spyview/bisector.H
-+++ b/spyview/bisector.H
-@@ -3,6 +3,8 @@
- #include <assert.h>
- #include <math.h>
-
-+#include <cmath>
-+using std::isnan;
-
- class bisector
- {
-@@ -105,18 +107,18 @@ public:
- }
- else
- {
-- if(fxp < 0 && (std::isnan(x1) || (fxp > fx1)))
-+ if(fxp < 0 && (isnan(x1) || (fxp > fx1)))
- {
- x1 = xp;
- fx1 = fxp;
- }
-- else if(fxp > 0 && (std::isnan(x2) || (fxp < fx2)))
-+ else if(fxp > 0 && (isnan(x2) || (fxp < fx2)))
- {
- x2 = xp;
- fx2 = fxp;
- }
- }
-- bisection = !(std::isnan(x1) || std::isnan(x2));
-+ bisection = !(isnan(x1) || isnan(x2));
- if(bisection)
- {
- // printf("Bisection step: [%g,%g] {%g,%g}\n", x1,x2,fx1,fx2);
diff --git a/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14.patch b/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-9.patch
index cc5198853bc8..0f302314b190 100644
--- a/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14.patch
+++ b/sci-visualization/spyview/files/spyview-20150124-gcc6cxx14-9.patch
@@ -1,3 +1,18 @@
+diff --git a/configure.ac b/configure.ac
+index 5e1cfff..8850ce8 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -27,6 +27,10 @@ AM_CONDITIONAL(WINDOWS,test $windows_target = yes)
+ AC_PROG_CXX
+ AC_PROG_CC
+ AM_PROG_CC_C_O
++
++# Check for C++11 language standard
++AX_CXX_COMPILE_STDCXX([11], [noext], [mandatory])
++
+ # Check for fluid
+ AC_PATH_PROG(FLUID,fluid,none)
+ AC_ARG_VAR(FLUID,[path to executable to compile .fl files])
diff --git a/spyview/Fl_Listbox.H b/spyview/Fl_Listbox.H
index 35803fc..832792b 100644
--- a/spyview/Fl_Listbox.H
@@ -13,10 +28,20 @@ index 35803fc..832792b 100644
class Fl_Listbox : public Fl_Table
{
diff --git a/spyview/ImageData.C b/spyview/ImageData.C
-index 7ee936a..a9b2c17 100644
+index 7ee936a..eaac7a6 100644
--- a/spyview/ImageData.C
+++ b/spyview/ImageData.C
-@@ -2007,7 +2007,7 @@ void ImageData::grad_mag(double axis_bias)
+@@ -9,6 +9,9 @@
+ #include "mypam.h"
+ #include "../config.h"
+
++#include <cmath>
++using std::isnan;
++
+ #include <algorithm>
+ // From http://www.redhat.com/docs/manuals/enterprise/RHEL-3-Manual/gcc/variadic-macros.html
+
+@@ -2007,7 +2010,7 @@ void ImageData::grad_mag(double axis_bias)
xderv();
width = w;
height = h;
@@ -25,7 +50,7 @@ index 7ee936a..a9b2c17 100644
yderv();
width = w;
height = h;
-@@ -2083,7 +2083,7 @@ void ImageData::dderv(double theta) // theta in degrees!
+@@ -2083,7 +2086,7 @@ void ImageData::dderv(double theta) // theta in degrees!
xderv();
width = w;
height = h;
@@ -62,19 +87,22 @@ index d85b440..f34ee67 100644
class ImageWindow;
class Image_Printer_Control;
diff --git a/spyview/ImageWindow.C b/spyview/ImageWindow.C
-index b8bd0f9..134b198 100644
+index b8bd0f9..eeae649 100644
--- a/spyview/ImageWindow.C
+++ b/spyview/ImageWindow.C
-@@ -12,6 +12,8 @@
+@@ -12,6 +12,11 @@
#include "ImageWindow_Module.H"
#include <ctype.h>
++#include <cmath>
++using std::isnan;
++
+#include "mypam.h"
+
#ifdef WIN32
#include <windows.h>
-@@ -36,8 +38,6 @@
+@@ -36,8 +41,6 @@
#define alt(state) (!(state & FL_CTRL) && !(state & FL_SHIFT) && (state & FL_ALT))
#define none(state) (!(state & FL_CTRL) && !(state & FL_SHIFT) && !(state & FL_ALT))
@@ -83,7 +111,7 @@ index b8bd0f9..134b198 100644
FILE *fopenwarn(const char *name, const char *mode)
{
FILE *fp = fopen(name, mode);
-@@ -482,7 +482,7 @@ double current_time()
+@@ -482,7 +485,7 @@ double current_time()
stop.tv_usec = (long)(tmpres % 1000000UL);
#endif
double time = (((double)(stop.tv_sec)) + ((double)(stop.tv_usec) * 1e-6));
@@ -92,7 +120,7 @@ index b8bd0f9..134b198 100644
info("time %e sec %d usec %d\n", time, stop.tv_sec, stop.tv_usec);
return time;
}
-@@ -1609,7 +1609,7 @@ void ImageWindow::runQueue()
+@@ -1609,7 +1612,7 @@ void ImageWindow::runQueue()
for (int n=0; n<op->num_parameters; n++)
{
operations_string += "-";
@@ -142,15 +170,17 @@ index 683015b..e6f296f 100644
#define LMAX USHRT_MAX
diff --git a/spyview/bisector.H b/spyview/bisector.H
-index b22fb8f..039c5ff 100644
+index b22fb8f..c7e64a6 100644
--- a/spyview/bisector.H
+++ b/spyview/bisector.H
-@@ -2,7 +2,7 @@
+@@ -2,7 +2,9 @@
#define __bisector_h__
#include <assert.h>
#include <math.h>
-using namespace std;
+
++#include <cmath>
++using std::isnan;
class bisector
{
diff --git a/sci-visualization/spyview/spyview-20150124-r1.ebuild b/sci-visualization/spyview/spyview-20150124-r1.ebuild
index fa02a749d043..d873c7d008cc 100644
--- a/sci-visualization/spyview/spyview-20150124-r1.ebuild
+++ b/sci-visualization/spyview/spyview-20150124-r1.ebuild
@@ -30,9 +30,7 @@ RDEPEND="${COMMON_DEPEND}
PATCHES=(
"${FILESDIR}/${P}"-gnuplot_interface_fix.patch
- "${FILESDIR}/${P}"-gcc6cxx14.patch
- "${FILESDIR}/${P}"-gcc6cxx14-2.patch
- "${FILESDIR}/${P}"-gcc6cxx14-3.patch
+ "${FILESDIR}/${P}"-gcc6cxx14-9.patch
)
src_unpack() {