[98261] trunk/dports/graphics/jgraph/files
ryandesign at macports.org
ryandesign at macports.org
Sun Sep 30 22:39:07 PDT 2012
Revision: 98261
http://trac.macports.org//changeset/98261
Author: ryandesign at macports.org
Date: 2012-09-30 22:39:07 -0700 (Sun, 30 Sep 2012)
Log Message:
-----------
jgraph: add new patches from #36397
Added Paths:
-----------
trunk/dports/graphics/jgraph/files/patch-draw.c.diff
trunk/dports/graphics/jgraph/files/patch-edit.c.diff
trunk/dports/graphics/jgraph/files/patch-jgraph.c.diff
trunk/dports/graphics/jgraph/files/patch-list.h.diff
trunk/dports/graphics/jgraph/files/patch-printline.c.diff
trunk/dports/graphics/jgraph/files/patch-prio_list.c.diff
trunk/dports/graphics/jgraph/files/patch-prio_list.h.diff
trunk/dports/graphics/jgraph/files/patch-process.c.diff
trunk/dports/graphics/jgraph/files/patch-show.c.diff
Added: trunk/dports/graphics/jgraph/files/patch-draw.c.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-draw.c.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-draw.c.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,191 @@
+--- draw.c.orig 2012-10-01 00:08:42.000000000 -0400
++++ draw.c 2012-10-01 00:04:35.000000000 -0400
+@@ -8,12 +8,18 @@
+ #include "jgraph.h"
+ #include <stdio.h>
+ #include <math.h>
++#include <string.h>
+
+ static char real_eof = EOF;
+
+-float ctop(val, axis)
+-float val;
+-Axis axis;
++static void draw_footer(Graphs, int);
++static void draw_header(Graphs, int, int);
++static void draw_arrow(float, float, float, float, Curve);
++static void draw_mark(float, float, Curve, Graph);
++static void draw_curve(Curve, Graph);
++static void draw_label(Label);
++
++float ctop(float val, Axis axis)
+ {
+ if (axis->is_lg) {
+ if (val <= 0.0) {
+@@ -29,9 +35,7 @@ Axis axis;
+ }
+ }
+
+-float disttop(val, axis)
+-float val;
+-Axis axis;
++float disttop(float val, Axis axis)
+ {
+ if (axis->is_lg) {
+ return FCPI * val;
+@@ -40,16 +44,14 @@ Axis axis;
+ }
+ }
+
+-float intop(val)
+-float val;
++float intop(float val)
+ {
+ return FCPI * val;
+ }
+
+ #define MAXIMUM(a,b) ((a > b) ? a : b)
+
+-draw_axis(a, other)
+-Axis a, other;
++void draw_axis(Axis a, Axis other)
+ {
+ char orientation;
+ Hash h;
+@@ -114,16 +116,14 @@ Axis a, other;
+ }
+
+
+-draw_label(l)
+-Label l;
++void draw_label(Label l)
+ {
+ if (l->label == CNULL) return;
+ comment(l->label);
+ print_label(l);
+ }
+
+-set_clip(g)
+-Graph g;
++static void set_clip(Graph g)
+ {
+ comment("Setting Clip");
+ printf("newpath\n");
+@@ -133,8 +133,7 @@ Graph g;
+ printf(" closepath clip newpath\n");
+ }
+
+-draw_curves(g)
+-Graph g;
++static void draw_curves(Graph g)
+ {
+ Curve c;
+
+@@ -148,9 +147,7 @@ Graph g;
+ printf("\n");
+ }
+
+-draw_curve(c, g)
+-Curve c;
+-Graph g;
++void draw_curve(Curve c, Graph g)
+ {
+ Point p, px, py;
+ int i, j;
+@@ -267,10 +264,7 @@ Graph g;
+ printf("\n");
+ }
+
+-draw_mark(x, y, c, g)
+-float x, y;
+-Curve c;
+-Graph g;
++void draw_mark(float x, float y, Curve c, Graph g)
+ {
+ Point p;
+ float ms0, ms1, scx, scy, trx, try;
+@@ -499,9 +493,7 @@ Graph g;
+ grestore();
+ }
+
+-draw_arrow(x1, y1, x2, y2, c)
+-float x1, y1, x2, y2;
+-Curve c;
++void draw_arrow(float x1, float y1, float x2, float y2, Curve c)
+ {
+ float dx, dy;
+ float ms0;
+@@ -539,8 +531,7 @@ Curve c;
+ printf("\n");
+ }
+
+-draw_legend(g)
+-Graph g;
++static void draw_legend(Graph g)
+ {
+ Curve c;
+ Legend l;
+@@ -603,8 +594,7 @@ Graph g;
+ printf("\n");
+ }
+
+-draw_strings(g)
+-Graph g;
++static void draw_strings(Graph g)
+ {
+ String s;
+
+@@ -613,8 +603,7 @@ Graph g;
+ draw_label(s->s);
+ }
+
+-draw_graph(g)
+-Graph g;
++static void draw_graph(Graph g)
+ {
+ comment("Drawing New Graph");
+ printf("%f %f translate\n", g->x_translate, g->y_translate);
+@@ -634,10 +623,7 @@ Graph g;
+
+ }
+
+-draw_graphs(gs, pp, landscape)
+-Graphs gs;
+-int pp;
+-int landscape;
++void draw_graphs(Graphs gs, int pp, int landscape)
+ {
+ Graphs gs_p;
+ Graph g;
+@@ -651,10 +637,7 @@ int landscape;
+ }
+ }
+
+-draw_header(gs, pp, landscape)
+-Graphs gs;
+-int pp;
+-int landscape;
++void draw_header(Graphs gs, int pp, int landscape)
+ {
+ FILE *f;
+ char c;
+@@ -685,7 +668,7 @@ int landscape;
+ (((11.0 * FCPI) - (gs->bb[3] - gs->bb[1])) / 2.0) - gs->bb[1]);
+ }
+ } else if (landscape) {
+- printf("%f 0 translate\n", -gs->bb[2] - gs->bb[0]);
++ printf("%f 0 translate\n", (double)(-gs->bb[2] - gs->bb[0]));
+ }
+ printf("1 setlinecap 1 setlinejoin\n");
+ printf("0.700 setlinewidth\n");
+@@ -746,9 +729,7 @@ int landscape;
+ }
+ }
+
+-draw_footer(gs, pp)
+-Graphs gs;
+-int pp;
++void draw_footer(Graphs gs, int pp)
+ {
+ FILE *f;
+ char c;
Added: trunk/dports/graphics/jgraph/files/patch-edit.c.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-edit.c.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-edit.c.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,180 @@
+--- edit.c.orig 2012-10-01 00:08:42.000000000 -0400
++++ edit.c 2012-09-30 23:54:16.000000000 -0400
+@@ -7,14 +7,14 @@
+
+
+ #include <stdio.h>
++#include <string.h>
+
+ #include "jgraph.h"
+
+ #define MAX(a,b) ((a > b) ? a : b)
+ #define MIN(a,b) ((a < b) ? a : b)
+
+-edit_label(l)
+-Label l;
++static void edit_label(Label l)
+ {
+ char *txt, inp_str[80];
+ float f;
+@@ -72,8 +72,7 @@ Label l;
+ }
+ }
+
+-copy_curve(c1, c2) /* Copies curve c2 to c1 */
+-Curve c1, c2;
++static void copy_curve(Curve c1, Curve c2) /* Copies curve c2 to c1 */
+ {
+ Flist f, newf;
+ Point p, newp;
+@@ -138,8 +137,7 @@ Curve c1, c2;
+ c1->bezier = c2->bezier;
+ }
+
+-copy_label(l1, l2) /* Copies label l2 to l1 */
+-Label l1, l2;
++void copy_label(Label l1, Label l2) /* Copies label l2 to l1 */
+ {
+ l1->label = l2->label;
+ l1->x = l2->x;
+@@ -156,8 +154,7 @@ Label l1, l2;
+ l1->linesep = l2->linesep;
+ }
+
+-copy_axis(a1, a2) /* Copies axis a2 to a1 */
+-Axis a1, a2;
++static void copy_axis(Axis a1, Axis a2) /* Copies axis a2 to a1 */
+ {
+ copy_label(a1->label, a2->label);
+ copy_label(a1->hl, a2->hl);
+@@ -201,10 +198,7 @@ Axis a1, a2;
+ a1->is_x = a2->is_x;
+ }
+
+-Curve do_copy_curve(g, gs, all_gs)
+-Graph g;
+-Graphs gs;
+-Graphs all_gs;
++static Curve do_copy_curve(Graph g, Graphs gs, Graphs all_gs)
+ {
+ Curve lastc, newc;
+ Graph oldg;
+@@ -254,10 +248,7 @@ Graphs all_gs;
+ return newc; /* To shut lint up */
+ }
+
+-Label do_copy_string(g, gs, all_gs)
+-Graph g;
+-Graphs gs;
+-Graphs all_gs;
++static Label do_copy_string(Graph g, Graphs gs, Graphs all_gs)
+ {
+ String lastl, newl;
+ Graph oldg;
+@@ -307,10 +298,7 @@ Graphs all_gs;
+ }
+ }
+
+-Graph last_graph(g, gs, all_gs)
+-Graph g;
+-Graphs gs;
+-Graphs all_gs;
++static Graph last_graph(Graph g, Graphs gs, Graphs all_gs)
+ {
+ Graph lastg;
+
+@@ -329,8 +317,7 @@ Graphs all_gs;
+ return lastg;
+ }
+
+-copy_legend(l1, l2)
+-Legend l1, l2;
++static void copy_legend(Legend l1, Legend l2)
+ {
+ l1->linelength = l2->linelength;
+ l1->linebreak = l2->linebreak;
+@@ -339,9 +326,7 @@ Legend l1, l2;
+ copy_label(l1->l, l2->l);
+ }
+
+-inherit_axes(g, lastg)
+-Graph g;
+-Graph lastg;
++static void inherit_axes(Graph g, Graph lastg)
+ {
+ char *s;
+ copy_axis(g->x_axis, lastg->x_axis);
+@@ -356,9 +341,7 @@ Graph lastg;
+ g->title->label = s;
+ }
+
+-getpattern(inp_str, key, p, a)
+-char *inp_str, *key, *p;
+-float *a;
++static void getpattern(char *inp_str, char *key, char *p, float *a)
+ {
+ int i;
+ float f;
+@@ -385,9 +368,7 @@ float *a;
+ return;
+ }
+
+-edit_curve(c, g)
+-Curve c;
+-Graph g;
++static void edit_curve(Curve c, Graph g)
+ {
+ char inp_str[256], *txt;
+ float x, y, f, e1, e2;
+@@ -680,8 +661,7 @@ Graph g;
+ }
+ }
+
+-edit_hash_label(a)
+-Axis a;
++static void edit_hash_label(Axis a)
+ {
+ float at, f;
+ char *s;
+@@ -731,8 +711,7 @@ Axis a;
+ }
+ }
+
+-edit_axis(a)
+-Axis a;
++static void edit_axis(Axis a)
+ {
+ char inp_str[256];
+ float f;
+@@ -907,8 +886,7 @@ Axis a;
+ }
+ }
+
+-edit_legend(l)
+-Legend l;
++static void edit_legend(Legend l)
+ {
+ char inp_str[256];
+ float f;
+@@ -974,10 +952,7 @@ Legend l;
+ }
+ }
+
+-edit_graph(g, gs, all_gs)
+-Graph g;
+-Graphs gs;
+-Graphs all_gs;
++static void edit_graph(Graph g, Graphs gs, Graphs all_gs)
+ {
+ char inp_str[80];
+ int num;
+@@ -1049,8 +1024,7 @@ Graphs all_gs;
+ }
+ }
+
+-edit_graphs(gs)
+-Graphs gs;
++void edit_graphs(Graphs gs)
+ {
+ Graphs the_g;
+ Graph g, tmp_g;
Added: trunk/dports/graphics/jgraph/files/patch-jgraph.c.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-jgraph.c.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-jgraph.c.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,143 @@
+--- jgraph.c.orig 2012-10-01 00:08:42.000000000 -0400
++++ jgraph.c 2012-09-30 23:50:23.000000000 -0400
+@@ -6,12 +6,14 @@
+ */
+
+ #include <stdio.h>
++#include <string.h>
+
+ #ifdef VMS
+ #include <redexp.VMS>
+ #endif
+
+ #include "jgraph.h"
++#include "prio_list.h"
+
+ int NMARKTYPES = 17;
+ int NORMALMARKTYPES = 6;
+@@ -49,9 +51,7 @@ Label new_label()
+ }
+
+
+-Curve new_curve(c, num)
+-Curve c;
+-int num;
++Curve new_curve(Curve c, int num)
+ {
+ Curve new_c;
+ int i;
+@@ -105,9 +105,7 @@ int num;
+ return new_c;
+ }
+
+-Curve new_line(c, num)
+-Curve c;
+-int num;
++Curve new_line(Curve c, int num)
+ {
+ Curve new_c;
+ new_c = new_curve(c, num);
+@@ -117,9 +115,7 @@ int num;
+ }
+
+
+-Curve get_curve(c, num)
+-Curve c;
+-int num;
++Curve get_curve(Curve c, int num)
+ {
+ Curve new_c;
+ for(new_c = last(c); new_c != nil(c) && new_c->num > num; new_c = prev(new_c));
+@@ -127,8 +123,7 @@ int num;
+ return new_c;
+ }
+
+-Axis new_axis(is_x)
+-int is_x;
++static Axis new_axis(int is_x)
+ {
+ int i;
+ Axis a;
+@@ -185,7 +180,7 @@ int is_x;
+ return a;
+ }
+
+-Legend new_legend()
++static Legend new_legend()
+ {
+ Legend l;
+ l = (Legend) malloc (sizeof(struct legend));
+@@ -202,7 +197,7 @@ Legend new_legend()
+ return l;
+ }
+
+-Label new_title()
++static Label new_title()
+ {
+ Label t;
+
+@@ -216,9 +211,7 @@ Label new_title()
+ return t;
+ }
+
+-String new_string(s, num)
+-String s;
+-int num;
++String new_string(String s, int num)
+ {
+ String new_s;
+
+@@ -229,9 +222,7 @@ int num;
+ return new_s;
+ }
+
+-String get_string(s, num)
+-String s;
+-int num;
++String get_string(String s, int num)
+ {
+ String new_s;
+ for(new_s = last(s); new_s != nil(s) && new_s->num > num; new_s = prev(new_s));
+@@ -259,9 +250,7 @@ Default new_default()
+ }
+ */
+
+-Graph new_graph(gs, num)
+-Graph gs;
+-int num;
++Graph new_graph(Graph gs, int num)
+ {
+ Graph g;
+
+@@ -286,9 +275,7 @@ int num;
+ return g;
+ }
+
+-Graph get_graph(g, num)
+-Graph g;
+-int num;
++Graph get_graph(Graph g, int num)
+ {
+ Graph new_g;
+ for(new_g = last(g); new_g != nil(g) && new_g->num > num; new_g = prev(new_g));
+@@ -296,8 +283,7 @@ int num;
+ return new_g;
+ }
+
+-new_graphs(gs)
+-Graphs gs;
++void new_graphs(Graphs gs)
+ {
+ Graphs newg;
+
+@@ -315,9 +301,7 @@ Graphs gs;
+ insert(newg, gs);
+ }
+
+-main(argc, argv)
+-int argc;
+-char **argv;
++int main(int argc, char *argv[])
+ {
+ Graphs gs;
+ int i;
Added: trunk/dports/graphics/jgraph/files/patch-list.h.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-list.h.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-list.h.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,18 @@
+--- list.h.orig 2012-10-01 00:08:42.000000000 -0400
++++ list.h 2012-09-30 22:22:26.000000000 -0400
+@@ -25,9 +25,14 @@ typedef struct list {
+
+ /* These are the routines for manipluating lists */
+
+-/* void insert(node list); Inserts a node to the end of a list */
++/* void insert(node, list); Inserts a node to the end of a list */
+ /* void delete_item(node); Deletes an arbitrary node */
+ /* List make_list(node_size); Creates a new list */
+ /* List get_node(list); Allocates a node to be inserted into the list */
+ /* void free_node(node, list); Deallocates a node from the list */
+
++extern void insert(void *, void *);
++extern void delete_item(void *);
++extern List make_list(int);
++extern List get_node(void *);
++extern void free_node(void *, void *);
Added: trunk/dports/graphics/jgraph/files/patch-printline.c.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-printline.c.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-printline.c.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,213 @@
+--- printline.c.orig 2012-10-01 00:08:42.000000000 -0400
++++ printline.c 2012-09-30 23:52:16.000000000 -0400
+@@ -7,6 +7,7 @@
+
+ #include "jgraph.h"
+ #include <stdio.h>
++#include <string.h>
+
+ #define LINEWIDTHFACTOR 0.700
+ #define MAX(a, b) ((a > b) ? (a) : (b))
+@@ -23,7 +24,7 @@ static Fontlist Jgraph_fonts;
+ static int Jgraph_gsave_level = -100;
+ static int Jgraph_comment;
+
+-gsave()
++void gsave()
+ {
+ if (Jgraph_gsave_level == -100) {
+ Jgraph_gsave_level = 0;
+@@ -33,7 +34,7 @@ gsave()
+ printf(" gsave ");
+ }
+
+-grestore()
++void grestore()
+ {
+ Fontlist l;
+
+@@ -48,9 +49,7 @@ grestore()
+ printf(" grestore ");
+ }
+
+-setfont(f, s)
+-char *f;
+-float s;
++void setfont(char *f, float s)
+ {
+ Fontlist l;
+ int ins;
+@@ -75,10 +74,7 @@ float s;
+ }
+ }
+
+-setfill( x, y, t, f, p, a)
+-char t, p ;
+-float x, y;
+-float f[], a ;
++void setfill(float x, float y, char t, float *f, char p, float a)
+ {
+ /* fprintf(stderr, "Hello? %c %f %c %f\n", t, f[0], p, a); */
+ if (t == 'g' && f[0] < 0.0) return;
+@@ -100,9 +96,7 @@ float f[], a ;
+ printf(" grestore\n");
+ }
+
+-setgray( t, f)
+-char t ;
+-float f[] ;
++void setgray(char t, float *f)
+ {
+ if ( t == 'g' ) {
+ if( f[0] >= 0.0 ) printf("%f setgray\n", f[0] );
+@@ -111,9 +105,7 @@ float f[] ;
+ }
+ }
+
+-printline(x1, y1,x2, y2, orientation)
+-float x1, y1, x2, y2;
+-char orientation;
++void printline(float x1, float y1, float x2, float y2, char orientation)
+ {
+ if (orientation == 'x')
+ printf("newpath %f %f moveto %f %f lineto stroke\n", x1, y1, x2, y2);
+@@ -122,30 +114,25 @@ char orientation;
+ fflush(stdout);
+ }
+
+-print_ebar(x1, y1, x2, ms, orientation)
+-float x1, y1, x2, ms;
+-char orientation;
++void print_ebar(float x1, float y1, float x2, float ms, char orientation)
+ {
+ printline(x1, y1, x2, y1, orientation);
+ printline(x2, y1-ms, x2, y1+ms, orientation);
+ }
+
+-start_line(x1, y1, c)
+-float x1, y1;
+-Curve c;
++void start_line(float x1, float y1, Curve c)
+ {
+ setlinewidth(c->linethick);
+ setlinestyle(c->linetype, c->gen_linetype);
+ printf("%f %f moveto ", x1, y1);
+ }
+
+-cont_line(x1, y1)
+-float x1, y1;
++void cont_line(float x1, float y1)
+ {
+ printf(" %f %f lineto\n", x1, y1);
+ }
+
+-end_line()
++void end_line()
+ {
+ printf("stroke\n");
+ setlinewidth(1.0);
+@@ -154,35 +141,28 @@ end_line()
+
+ }
+
+-bezier_control(x1, y1)
+-float x1, y1;
++void bezier_control(float x1, float y1)
+ {
+ printf(" %f %f ", x1, y1);
+ }
+
+-bezier_end(x1, y1)
+-float x1, y1;
++void bezier_end(float x1, float y1)
+ {
+ printf(" %f %f curveto\n", x1, y1);
+ }
+
+
+-start_poly(x1, y1)
+-float x1, y1;
++void start_poly(float x1, float y1)
+ {
+ printf(" newpath %f %f moveto", x1, y1);
+ }
+
+-cont_poly(x1, y1)
+-float x1, y1;
++void cont_poly(float x1, float y1)
+ {
+ printf(" %f %f lineto\n", x1, y1);
+ }
+
+-end_poly(x, y, ftype, fill, pattern, parg)
+-float x, y;
+-char ftype, pattern ;
+-float fill[], parg;
++void end_poly(float x, float y, char ftype, float *fill, char pattern, float parg)
+ {
+ printf("closepath ");
+ setfill( x, y, ftype, fill, pattern, parg );
+@@ -192,9 +172,7 @@ float fill[], parg;
+
+ /* Ellipse at 0, 0 -- assumes that you've already translated to x, y */
+
+-printellipse(x, y, radius1, radius2, ftype, fill, pattern, parg)
+-char ftype, pattern;
+-float x, y, radius1, radius2, fill[], parg;
++void printellipse(float x, float y, float radius1, float radius2, char ftype, float *fill, char pattern, float parg)
+ {
+ printf("newpath %f %f JDE\n", radius1, radius2);
+ setfill( x, y, ftype, fill, pattern, parg );
+@@ -202,28 +180,25 @@ float x, y, radius1, radius2, fill[], pa
+ fflush(stdout);
+ }
+
+-set_comment(c)
+-int c;
++void set_comment(int c)
+ {
+ Jgraph_comment = c;
+ }
+
+-comment(s)
+-char *s;
++void comment(const char *s)
+ {
+ if (Jgraph_comment) printf("%% %s\n", s);
+ }
+
+-printline_c(x1, y1, x2, y2, g)
+-float x1, y1, x2, y2;
+-Graph g;
++#if 0
++static void printline_c(float x1, float y1, float x2, float y2, Graph g)
+ {
+ printline(ctop(x1, g->x_axis), ctop(y1, g->y_axis),
+ ctop(x2, g->x_axis), ctop(y2, g->y_axis), 'x');
+ }
++#endif
+
+-print_label(l)
+-Label l;
++void print_label(Label l)
+ {
+ int f, i, nlines;
+ float fnl;
+@@ -290,15 +265,12 @@ Label l;
+ printf("grestore\n");
+ }
+
+-setlinewidth(size)
+-float size;
++void setlinewidth(float size)
+ {
+ printf("%f setlinewidth ", size * LINEWIDTHFACTOR);
+ }
+
+-setlinestyle(style, glist)
+-char style;
+-Flist glist;
++void setlinestyle(char style, Flist glist)
+ {
+ Flist fl;
+
Added: trunk/dports/graphics/jgraph/files/patch-prio_list.c.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-prio_list.c.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-prio_list.c.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,17 @@
+--- prio_list.c.orig 2012-10-01 00:08:42.000000000 -0400
++++ prio_list.c 2012-09-30 23:49:29.000000000 -0400
+@@ -25,11 +25,10 @@ typedef struct prio_list {
+ * checks for inserting into the head or tail, and then proceeds sequentially.
+ * Thus, it is worst case linear, but for most cases constant time (right). */
+
+-prio_insert(node, list, desc)
+-Prio_list node;
+-Prio_list list;
+-Boolean desc;
++void prio_insert(void *node_, void *list_, Boolean desc)
+ {
++ Prio_list node = node_;
++ Prio_list list = list_;
+ Prio_list p;
+
+ /* Check nil and head of list */
Added: trunk/dports/graphics/jgraph/files/patch-prio_list.h.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-prio_list.h.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-prio_list.h.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,8 @@
+--- prio_list.h.orig 2012-10-01 00:08:42.000000000 -0400
++++ prio_list.h 2012-09-30 23:48:41.000000000 -0400
+@@ -25,4 +25,4 @@ struct prio_list {
+ */
+
+ /* void prio_insert(node, list, descending); */
+-
++extern void prio_insert(void *, void *, int);
Added: trunk/dports/graphics/jgraph/files/patch-process.c.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-process.c.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-process.c.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,200 @@
+--- process.c.orig 2012-10-01 00:08:42.000000000 -0400
++++ process.c 2012-09-30 23:15:16.000000000 -0400
+@@ -7,6 +7,7 @@
+
+ #include <stdio.h>
+ #include <math.h>
++#include <string.h>
+
+ #include "jgraph.h"
+
+@@ -18,8 +19,10 @@
+
+ static double Pi;
+
+-process_title(g)
+-Graph g;
++static void process_label_max_n_mins(Label, float, float);
++static void process_label(Label, Graph, int);
++
++static void process_title(Graph g)
+ {
+
+ float ytitleloc;
+@@ -43,8 +46,7 @@ Graph g;
+ process_label(g->title, g, 0);
+ }
+
+-process_legend(g)
+-Graph g;
++static void process_legend(Graph g)
+ {
+ Legend l;
+ int anything;
+@@ -208,8 +210,7 @@ Graph g;
+ process_label_max_n_mins(l->l, width, height);
+ }
+
+-float find_reasonable_hash_interval(a)
+-Axis a;
++static float find_reasonable_hash_interval(Axis a)
+ {
+ float s, d;
+
+@@ -237,8 +238,7 @@ Axis a;
+ }
+ }
+
+-float find_reasonable_hash_start(a)
+-Axis a;
++static float find_reasonable_hash_start(Axis a)
+ {
+ int i;
+
+@@ -248,8 +248,7 @@ Axis a;
+ return ((float) i) * a->hash_interval;
+ }
+
+-int find_reasonable_precision(a)
+-Axis a;
++static int find_reasonable_precision(Axis a)
+ {
+ int i, b, b2, done;
+ float x, x2, tolerance;
+@@ -292,8 +291,7 @@ Axis a;
+ return MAX(b, b2);
+ }
+
+-int find_reasonable_minor_hashes(a)
+-Axis a;
++static int find_reasonable_minor_hashes(Axis a)
+ {
+ float d;
+ int i;
+@@ -315,9 +313,7 @@ Axis a;
+ }
+ }
+
+-process_axis1(a, g)
+-Axis a;
+-Graph g;
++static void process_axis1(Axis a, Graph g)
+ {
+ float tmp;
+ int i;
+@@ -385,9 +381,7 @@ Graph g;
+ }
+ }
+
+-process_axis2(a, g)
+-Axis a;
+-Graph g;
++static void process_axis2(Axis a, Graph g)
+ {
+ float t1, t2, t3, minor_hashes, hloc, tmp;
+ float ymin, ymax, xmin, xmax;
+@@ -575,10 +569,7 @@ Graph g;
+ process_label (a->label, g, 0);
+ }
+
+-process_label(l, g, adjust)
+-Label l;
+-Graph g;
+-int adjust;
++void process_label(Label l, Graph g, int adjust)
+ {
+ float len, height;
+ int f, i;
+@@ -617,10 +608,7 @@ int adjust;
+ process_label_max_n_mins(l, len, height);
+ }
+
+-process_label_max_n_mins(l, len, height)
+-Label l;
+-float len;
+-float height;
++void process_label_max_n_mins(Label l, float len, float height)
+ {
+ float xlen, ylen, xheight, yheight;
+ float x, y;
+@@ -666,8 +654,7 @@ float height;
+
+ }
+
+-process_strings(g)
+-Graph g;
++static void process_strings(Graph g)
+ {
+ String s;
+
+@@ -676,9 +663,7 @@ Graph g;
+ }
+ }
+
+-process_curve(c, g)
+-Curve c;
+-Graph g;
++static void process_curve(Curve c, Graph g)
+ {
+ if (c->bezier && (c->npts < 4 || (c->npts % 3 != 1))) {
+ error_header();
+@@ -704,8 +689,7 @@ Graph g;
+ if (c->pparg == FSIG) c->pparg = 0.0;
+ }
+
+-process_curves(g)
+-Graph g;
++static void process_curves(Graph g)
+ {
+ Curve c;
+ for(c = first(g->curves); c != nil(g->curves); c = next(c)) {
+@@ -713,8 +697,16 @@ Graph g;
+ }
+ }
+
+-process_extrema(g) /* This finds all the minval/maxvals for bbox calc */
+-Graph g;
++static void process_label_extrema(Label l, Graph g)
++{
++ if (l->label == CNULL) return;
++ g->yminval = MIN(g->yminval, l->ymin);
++ g->ymaxval = MAX(g->ymaxval, l->ymax);
++ g->xminval = MIN(g->xminval, l->xmin);
++ g->xmaxval = MAX(g->xmaxval, l->xmax);
++}
++
++static void process_extrema(Graph g) /* This finds all the minval/maxvals for bbox calc */
+ {
+ Curve c;
+ String s;
+@@ -763,19 +755,7 @@ Graph g;
+ }
+ }
+
+-process_label_extrema(l, g)
+-Label l;
+-Graph g;
+-{
+- if (l->label == CNULL) return;
+- g->yminval = MIN(g->yminval, l->ymin);
+- g->ymaxval = MAX(g->ymaxval, l->ymax);
+- g->xminval = MIN(g->xminval, l->xmin);
+- g->xmaxval = MAX(g->xmaxval, l->xmax);
+-}
+-
+-process_graph(g)
+-Graph g;
++static void process_graph(Graph g)
+ {
+ g->x_translate = intop(g->x_translate);
+ g->y_translate = intop(g->y_translate);
+@@ -790,8 +770,7 @@ Graph g;
+ process_extrema(g);
+ }
+
+-process_graphs(gs)
+-Graphs gs;
++void process_graphs(Graphs gs)
+ {
+ Graphs the_g;
+ Graph g;
Added: trunk/dports/graphics/jgraph/files/patch-show.c.diff
===================================================================
--- trunk/dports/graphics/jgraph/files/patch-show.c.diff (rev 0)
+++ trunk/dports/graphics/jgraph/files/patch-show.c.diff 2012-10-01 05:39:07 UTC (rev 98261)
@@ -0,0 +1,142 @@
+--- show.c.orig 2012-10-01 00:08:42.000000000 -0400
++++ show.c 2012-09-30 23:16:30.000000000 -0400
+@@ -9,21 +9,17 @@
+ #include <math.h>
+ #include "jgraph.h"
+
+-static spaces(nsp)
+-int nsp;
++static void spaces(int nsp)
+ {
+ while(nsp-- > 0) putchar(' ');
+ }
+
+-float ptoin(p)
+-float p;
++static float ptoin(float p)
+ {
+ return p / FCPI;
+ }
+
+-float ptoc(p, a)
+-float p;
+-Axis a;
++static float ptoc(float p, Axis a)
+ {
+ if (a->is_lg) {
+ return (float) exp((p / a->factor + a->logmin) * a->logfactor);
+@@ -32,9 +28,7 @@ Axis a;
+ }
+ }
+
+-float ptodist(p, a)
+-float p;
+-Axis a;
++static float ptodist(float p, Axis a)
+ {
+ if (a->is_lg) {
+ return p / FCPI;
+@@ -43,8 +37,7 @@ Axis a;
+ }
+ }
+
+-static show_mltiline(s)
+-char *s;
++static void show_mltiline(const char *s)
+ {
+ int i;
+
+@@ -57,8 +50,7 @@ char *s;
+ putchar('\n');
+ }
+
+-show_string(s)
+-char *s;
++static void show_string(const char *s)
+ {
+ int i;
+
+@@ -74,10 +66,7 @@ char *s;
+ }
+
+
+-show_label(l, nsp, g)
+-Label l;
+-int nsp;
+-Graph g;
++static void show_label(Label l, int nsp, Graph g)
+ {
+ spaces(nsp);
+ show_string(l->label);
+@@ -98,10 +87,7 @@ Graph g;
+ return;
+ }
+
+-show_lmark(l, nsp, g)
+-Label l;
+-int nsp;
+-Graph g;
++static void show_lmark(Label l, int nsp, Graph g)
+ {
+ spaces(nsp); show_string(l->label);
+ spaces(nsp); printf("x %f ", ptodist(l->x, g->x_axis));
+@@ -110,13 +96,9 @@ Graph g;
+ printf("rotate %f\n", l->rotate);
+ spaces(nsp); printf("font %s ", l->font);
+ printf("fontsize %f\n", l->fontsize);
+- return;
+ }
+
+-show_curve(c, nsp, g)
+-Curve c;
+-int nsp;
+-Graph g;
++static void show_curve(Curve c, int nsp, Graph g)
+ {
+ Point p;
+ Point px;
+@@ -251,10 +233,7 @@ Graph g;
+ ptodist(c->asize[1], g->y_axis) * 2.0);
+ }
+
+-show_axis(a, nsp, g)
+-Axis a;
+-int nsp;
+-Graph g;
++static void show_axis(Axis a, int nsp, Graph g)
+ {
+ Axis other;
+ Hash h;
+@@ -342,10 +321,7 @@ Graph g;
+ }
+ }
+
+-show_legend(l, nsp, g)
+-Legend l;
+-int nsp;
+-Graph g;
++static void show_legend(Legend l, int nsp, Graph g)
+ {
+ if (l->type == 'c') {
+ spaces(nsp); printf("custom\n");
+@@ -362,9 +338,7 @@ Graph g;
+ }
+ }
+
+-show_graph(g, nsp)
+-Graph g;
+-int nsp;
++static void show_graph(Graph g, int nsp)
+ {
+
+ Curve c;
+@@ -394,8 +368,7 @@ int nsp;
+ }
+ }
+
+-show_graphs(gs)
+-Graphs gs;
++void show_graphs(Graphs gs)
+ {
+ Graphs the_g;
+ Graph g;
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20120930/e2c00205/attachment-0001.html>
More information about the macports-changes
mailing list