Debian 2.2 diffs for ivtools-0.8
Brought to you by:
johnston
|
From: <ivt...@li...> - 2000-02-02 00:17:24
|
Gregor, Thanks for the patch to ivtools-0.8 that allowed you to build it on frozen Debian 2.2. I removed the Makefile diffs and applied the rest to my copy of the source tree. I had to disable the sprintf definition in OS/directory with a temporary " #if Debian_Potato", but that's all, to get it built on RedHat 5.1. I'm forwarding back to you my result, and sending a copy to Guenter Geiger, the ivtools Debian maintainer who might want to do the same thing in the near future. Your changes will be incorporated in ivtools-0.8.1, and are already available on the CVS server at SourceForge: http:://sourceforge.net/cvs/?group_id=275 Scott Johnston p.s. I have not applied or tested your diffs for the clippoly library. Might there be a Debian package for this? -----------------------------8x-------------------------------------- Patch: ivtools-000201-GregorZych-001 For: ivtools-0.8 Author: Gregor Zych This is an intermediate patch to ivtools-0.8. To apply, cd to the top-level directory of the ivtools source tree (the directory with src and config subdirs), and apply like this: patch -p0 <ThisFile Summary of Changes: - patches submitted by Gregor Zych to compile ivtools-0.8 with frozen Debian Potato. The first patch adds a function definition that is disabled by default. Someone would need to change the #if clause to correctly test for the Debian 2.2 release. This was the only thing that didn't compile smoothly on RedHat 5.1. Index: src_os/directory.c diff -c src_os/directory.c:1.1 src_os/directory.c:1.2 *** src_os/directory.c:1.1 Wed Feb 2 03:09:38 2000 --- src/OS/directory.c Wed Feb 2 03:09:38 2000 *************** *** 51,56 **** --- 51,60 ---- */ extern "C" { + #if Debian_Potato + extern int sprintf __P ((char *__restrict __s, + __const char *__restrict __format, ...)); + #endif extern uid_t getuid(); extern void qsort( void*, size_t, size_t, int (*) (const void*, const void*) Index: IVGlyph/textview.h diff -c IVGlyph/textview.h:1.3 IVGlyph/textview.h:1.4 *** IVGlyph/textview.h:1.3 Wed Feb 2 03:09:42 2000 --- src/IVGlyph/textview.h Wed Feb 2 03:09:42 2000 *************** *** 134,140 **** private: void scroll_to_line(int line); void make_visible(const boolean scroll_page = true); ! event_to_index(const Event&); // popup menu stuff Menu* menu_; --- 134,140 ---- private: void scroll_to_line(int line); void make_visible(const boolean scroll_page = true); ! int event_to_index(const Event&); // popup menu stuff Menu* menu_; Index: examples3.1_morpher/figure.c diff -c examples3.1_morpher/figure.c:1.1 examples3.1_morpher/figure.c:1.2 *** examples3.1_morpher/figure.c:1.1 Wed Feb 2 03:09:51 2000 --- src/glyphs/examples3.1/morpher/figure.c Wed Feb 2 03:09:51 2000 *************** *** 1379,1385 **** /**********************************************************************/ declarePtrList(GraphicList, Graphic31); ! implmentPtrList(GraphicList, Graphic31); static Cursor* grabber_cursor = nil; static Cursor* window_cursor = nil; --- 1379,1385 ---- /**********************************************************************/ declarePtrList(GraphicList, Graphic31); ! int implmentPtrList(GraphicList, Graphic31); static Cursor* grabber_cursor = nil; static Cursor* window_cursor = nil; Index: Unidraw/stencilcomp.c diff -c Unidraw/stencilcomp.c:1.1 Unidraw/stencilcomp.c:1.2 *** Unidraw/stencilcomp.c:1.1 Wed Feb 2 03:09:55 2000 --- src/Unidraw/stencilcomp.c Wed Feb 2 03:09:55 2000 *************** *** 169,175 **** StencilComp* comp = (StencilComp*) GetSubject(); Bitmap* image, *mask; comp->GetStencil()->GetOriginal(image, mask); ! char* tag = (image == mask) ? "SSten" : "FSten"; Coord w = image->Width(); Coord h = image->Height(); --- 169,175 ---- StencilComp* comp = (StencilComp*) GetSubject(); Bitmap* image, *mask; comp->GetStencil()->GetOriginal(image, mask); ! const char* tag = (image == mask) ? "SSten" : "FSten"; Coord w = image->Width(); Coord h = image->Height(); Index: UniIdraw/ided.c diff -c UniIdraw/ided.c:1.1 UniIdraw/ided.c:1.2 *** UniIdraw/ided.c:1.1 Wed Feb 2 03:09:58 2000 --- src/UniIdraw/ided.c Wed Feb 2 03:09:58 2000 *************** *** 355,361 **** return commands; } ! static const unit = 15; static Coord xClosed[] = { unit/5, unit, unit, unit*3/5, 0 }; static Coord yClosed[] = { 0, unit/5, unit*3/5, unit, unit*2/5 }; --- 355,361 ---- return commands; } ! static const int unit = 15; static Coord xClosed[] = { unit/5, unit, unit, unit*3/5, 0 }; static Coord yClosed[] = { 0, unit/5, unit*3/5, unit, unit*2/5 }; Index: OverlayUnidraw/ovclip.c diff -c OverlayUnidraw/ovclip.c:1.1 OverlayUnidraw/ovclip.c:1.2 *** OverlayUnidraw/ovclip.c:1.1 Wed Feb 2 03:10:04 2000 --- src/OverlayUnidraw/ovclip.c Wed Feb 2 03:10:04 2000 *************** *** 115,121 **** int n1, n2; Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view)->GetGraphic(); ! n1 = g1->GetOriginal(tx1, ty1); ftx1 = new float[n1]; fty1 = new float[n1]; for (int j = 0; j < n1; j++) { --- 115,121 ---- int n1, n2; Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view)->GetGraphic(); ! n1 = g1->GetOriginal((const Coord*&)tx1,(const Coord*&) ty1); ftx1 = new float[n1]; fty1 = new float[n1]; for (int j = 0; j < n1; j++) { *************** *** 221,227 **** else { if (view->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic; ! n = ml->GetOriginal(x, y); } else if (view->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic; --- 221,227 ---- else { if (view->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic; ! n = ml->GetOriginal((const Coord*&)x,(const Coord*&) y); } else if (view->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic; *************** *** 384,390 **** int n1, n2; Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view)->GetGraphic(); ! n1 = g1->GetOriginal(tx1, ty1); ftx1 = new float[n1]; fty1 = new float[n1]; for (int ii = 0; ii < n1; ii++) { --- 384,390 ---- int n1, n2; Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view)->GetGraphic(); ! n1 = g1->GetOriginal((const Coord *&)tx1,(const Coord *&) ty1); ftx1 = new float[n1]; fty1 = new float[n1]; for (int ii = 0; ii < n1; ii++) { *************** *** 494,500 **** else { if (view->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic; ! n = ml->GetOriginal(x, y); } else if (view->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic; --- 494,500 ---- else { if (view->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic; ! n = ml->GetOriginal((const Coord *&)x,(const Coord *&) y); } else if (view->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic; *************** *** 705,712 **** Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view1)->GetGraphic(); g2 = (SF_Polygon*)((PolygonOvView*)view2)->GetGraphic(); ! n1 = g1->GetOriginal(tx1, ty1); ! n2 = g2->GetOriginal(tx2, ty2); x1 = new float[n1]; y1 = new float[n1]; x2 = new float[n2]; --- 705,712 ---- Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view1)->GetGraphic(); g2 = (SF_Polygon*)((PolygonOvView*)view2)->GetGraphic(); ! n1 = g1->GetOriginal((const Coord *&)tx1,(const Coord *&) ty1); ! n2 = g2->GetOriginal((const Coord *&)tx2,(const Coord *&) ty2); x1 = new float[n1]; y1 = new float[n1]; x2 = new float[n2]; *************** *** 777,783 **** Graphic* graphic1 = view1->GetGraphic(); if (view1->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic1; ! n = ml->GetOriginal(x, y); } else if (view1->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic1; --- 777,783 ---- Graphic* graphic1 = view1->GetGraphic(); if (view1->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic1; ! n = ml->GetOriginal((const Coord *&)x,(const Coord *&) y); } else if (view1->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic1; *************** *** 797,803 **** Coord* px; Coord* py; int pn; ! pn = graphic2->GetOriginal(px, py); graphic2->TotalTransformation(tn2); float* tpx = new float[pn]; float* tpy = new float[pn]; --- 797,803 ---- Coord* px; Coord* py; int pn; ! pn = graphic2->GetOriginal((const Coord *&)px,(const Coord *&) py); graphic2->TotalTransformation(tn2); float* tpx = new float[pn]; float* tpy = new float[pn]; *************** *** 898,905 **** Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view1)->GetGraphic(); g2 = (SF_Polygon*)((PolygonOvView*)view2)->GetGraphic(); ! n1 = g1->GetOriginal(tx1, ty1); ! n2 = g2->GetOriginal(tx2, ty2); x1 = new float[n1]; y1 = new float[n1]; x2 = new float[n2]; --- 898,905 ---- Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view1)->GetGraphic(); g2 = (SF_Polygon*)((PolygonOvView*)view2)->GetGraphic(); ! n1 = g1->GetOriginal((const Coord *&)tx1,(const Coord *&) ty1); ! n2 = g2->GetOriginal((const Coord *&)tx2,(const Coord *&) ty2); x1 = new float[n1]; y1 = new float[n1]; x2 = new float[n2]; *************** *** 970,976 **** Graphic* graphic1 = view2->GetGraphic(); if (view2->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic1; ! n = ml->GetOriginal(x, y); } else if (view2->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic1; --- 970,976 ---- Graphic* graphic1 = view2->GetGraphic(); if (view2->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic1; ! n = ml->GetOriginal((const Coord *&)x,(const Coord *&) y); } else if (view2->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic1; *************** *** 990,996 **** Coord* px; Coord* py; int pn; ! pn = graphic2->GetOriginal(px, py); graphic2->TotalTransformation(tn2); float* tpx = new float[pn]; float* tpy = new float[pn]; --- 990,996 ---- Coord* px; Coord* py; int pn; ! pn = graphic2->GetOriginal((const Coord *&)px,(const Coord *&) py); graphic2->TotalTransformation(tn2); float* tpx = new float[pn]; float* tpy = new float[pn]; *************** *** 1091,1098 **** Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view1)->GetGraphic(); g2 = (SF_Polygon*)((PolygonOvView*)view2)->GetGraphic(); ! n1 = g1->GetOriginal(tx1, ty1); ! n2 = g2->GetOriginal(tx2, ty2); x1 = new float[n1]; y1 = new float[n1]; x2 = new float[n2]; --- 1091,1098 ---- Transformer tn1, tn2; g1 = (SF_Polygon*)((PolygonOvView*)view1)->GetGraphic(); g2 = (SF_Polygon*)((PolygonOvView*)view2)->GetGraphic(); ! n1 = g1->GetOriginal((const Coord *&)tx1,(const Coord *&) ty1); ! n2 = g2->GetOriginal((const Coord *&)tx2,(const Coord *&) ty2); x1 = new float[n1]; y1 = new float[n1]; x2 = new float[n2]; *************** *** 1164,1170 **** Graphic* graphic1 = view1->GetGraphic(); if (view1->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic1; ! n = ml->GetOriginal(x, y); } else if (view1->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic1; --- 1164,1170 ---- Graphic* graphic1 = view1->GetGraphic(); if (view1->IsA(OVMULTILINE_VIEW)) { MultiLine* ml = (MultiLine*)graphic1; ! n = ml->GetOriginal((const Coord *&)x, (const Coord *&)y); } else if (view1->IsA(OVLINE_VIEW)) { Line* line = (Line*)graphic1; *************** *** 1184,1190 **** Coord* px; Coord* py; int pn; ! pn = graphic2->GetOriginal(px, py); graphic2->TotalTransformation(tn2); float* tpx = new float[pn]; float* tpy = new float[pn]; --- 1184,1190 ---- Coord* px; Coord* py; int pn; ! pn = graphic2->GetOriginal((const Coord *&)px,(const Coord *&) py); graphic2->TotalTransformation(tn2); float* tpx = new float[pn]; float* tpy = new float[pn]; Index: OverlayUnidraw/ovcmds.c diff -c OverlayUnidraw/ovcmds.c:1.1 OverlayUnidraw/ovcmds.c:1.2 *** OverlayUnidraw/ovcmds.c:1.1 Wed Feb 2 03:10:04 2000 --- src/OverlayUnidraw/ovcmds.c Wed Feb 2 03:10:04 2000 *************** *** 1256,1262 **** int* y; int np; SF_Polygon* poly = (SF_Polygon*)view->GetGraphic(); ! np = poly->GetOriginal(x, y); float* fx = new float[np]; float* fy = new float[np]; for (int i = 0; i < np; i++) { --- 1256,1262 ---- int* y; int np; SF_Polygon* poly = (SF_Polygon*)view->GetGraphic(); ! np = poly->GetOriginal((const iv2_6_Coord *&)x,(const iv2_6_Coord *&) y); float* fx = new float[np]; float* fy = new float[np]; for (int i = 0; i < np; i++) { Index: OverlayUnidraw/ovhull.c diff -c OverlayUnidraw/ovhull.c:1.1 OverlayUnidraw/ovhull.c:1.2 *** OverlayUnidraw/ovhull.c:1.1 Wed Feb 2 03:10:04 2000 --- src/OverlayUnidraw/ovhull.c Wed Feb 2 03:10:04 2000 *************** *** 53,59 **** if (comp && comp->IsA(OVPOLYGON_COMP)) { SF_Polygon* poly = ((PolygonOvComp*)comp)->GetPolygon(); Coord* x, *y; ! int np = poly->GetOriginal(x, y); if (np > 2) { float* fx = new float[np]; float* fy = new float[np]; --- 53,59 ---- if (comp && comp->IsA(OVPOLYGON_COMP)) { SF_Polygon* poly = ((PolygonOvComp*)comp)->GetPolygon(); Coord* x, *y; ! int np = poly->GetOriginal((const Coord*&)x,(const Coord*&) y); if (np > 2) { float* fx = new float[np]; float* fy = new float[np]; Index: OverlayUnidraw/ovkit.c diff -c OverlayUnidraw/ovkit.c:1.1 OverlayUnidraw/ovkit.c:1.2 *** OverlayUnidraw/ovkit.c:1.1 Wed Feb 2 03:10:04 2000 --- src/OverlayUnidraw/ovkit.c Wed Feb 2 03:10:04 2000 *************** *** 170,176 **** static const char* grid_y_incr = "gridyincr"; static const char* scribble_pointer_attrib = "scribble_pointer"; ! static const unit = 15; static int xClosed[] = { unit/5, unit, unit, unit*3/5, 0 }; static int yClosed[] = { 0, unit/5, unit*3/5, unit, unit*2/5 }; --- 170,176 ---- static const char* grid_y_incr = "gridyincr"; static const char* scribble_pointer_attrib = "scribble_pointer"; ! static const int unit = 15; static int xClosed[] = { unit/5, unit, unit, unit*3/5, 0 }; static int yClosed[] = { 0, unit/5, unit*3/5, unit, unit*2/5 }; Index: OverlayUnidraw/ovstencil.c diff -c OverlayUnidraw/ovstencil.c:1.1 OverlayUnidraw/ovstencil.c:1.2 *** OverlayUnidraw/ovstencil.c:1.1 Wed Feb 2 03:10:04 2000 --- src/OverlayUnidraw/ovstencil.c Wed Feb 2 03:10:04 2000 *************** *** 167,173 **** UStencil* stencil = (UStencil*) GetGraphicComp()->GetGraphic(); Bitmap* image, *mask; stencil->GetOriginal(image, mask); ! char* tag = (image == mask) ? "SSten" : "FSten"; Coord w = image->Width(); Coord h = image->Height(); --- 167,173 ---- UStencil* stencil = (UStencil*) GetGraphicComp()->GetGraphic(); Bitmap* image, *mask; stencil->GetOriginal(image, mask); ! const char* tag = (image == mask) ? "SSten" : "FSten"; Coord w = image->Width(); Coord h = image->Height(); |