From 128c3c24a3ea2f37cb40371d87d6dbe62651b1e9 Mon Sep 17 00:00:00 2001 From: dmcmahill Date: Fri, 9 Sep 2005 12:07:23 +0000 Subject: fix syntax error when using older (before gcc3) compilers --- cad/gschem/distinfo | 4 +++- cad/gschem/patches/patch-aa | 55 +++++++++++++++++++++++++++++++++++++++++++++ cad/gschem/patches/patch-ab | 55 +++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 113 insertions(+), 1 deletion(-) create mode 100644 cad/gschem/patches/patch-aa create mode 100644 cad/gschem/patches/patch-ab (limited to 'cad') diff --git a/cad/gschem/distinfo b/cad/gschem/distinfo index 51804887f1e..d446e02e1ab 100644 --- a/cad/gschem/distinfo +++ b/cad/gschem/distinfo @@ -1,5 +1,7 @@ -$NetBSD: distinfo,v 1.14 2005/08/23 00:02:20 dmcmahill Exp $ +$NetBSD: distinfo,v 1.15 2005/09/09 12:07:23 dmcmahill Exp $ SHA1 (geda/geda-gschem-20050820.tar.gz) = 5f9f89b065b456f87d5d4d784325d787ff1ff3f1 RMD160 (geda/geda-gschem-20050820.tar.gz) = 1afa28f8166cef38879768f849b0a6858e631e69 Size (geda/geda-gschem-20050820.tar.gz) = 1595185 bytes +SHA1 (patch-aa) = 52fc97bae3b30785429554b1314ffd856a596ed0 +SHA1 (patch-ab) = 288936ba52b1949e0b233ed4693e22821b45b737 diff --git a/cad/gschem/patches/patch-aa b/cad/gschem/patches/patch-aa new file mode 100644 index 00000000000..983e874e09d --- /dev/null +++ b/cad/gschem/patches/patch-aa @@ -0,0 +1,55 @@ +$NetBSD: patch-aa,v 1.7 2005/09/09 12:07:23 dmcmahill Exp $ + +--- noweb/x_dialog.nw.orig 2005-08-20 14:13:28.000000000 +0000 ++++ noweb/x_dialog.nw +@@ -901,6 +901,7 @@ text_edit_dialog (TOPLEVEL *w_current, c + char *text_size_string; + int len; + int num_selected; ++ int select_index=0; + + num_selected = o_selection_return_num(w_current->page_current->selection2_head); + +@@ -977,7 +978,6 @@ text_edit_dialog (TOPLEVEL *w_current, c + gtk_widget_show(label); + + optionmenu = gtk_option_menu_new(); +- int select_index=0; + + gtk_option_menu_set_menu(GTK_OPTION_MENU(optionmenu), create_color_menu(w_current, &select_index)); + gtk_option_menu_set_history(GTK_OPTION_MENU(optionmenu), select_index); +@@ -3466,14 +3466,15 @@ create_color_menu (TOPLEVEL * w_current, + char *temp=NULL; + int found=0; + +- menu = gtk_menu_new (); +- group = NULL; +- + /* first lets see if we have a selected object, if so select its color */ + int select_col = -1; + int item_index = 0; + SELECTION *s_current = NULL; + OBJECT *object = NULL; ++ ++ menu = gtk_menu_new (); ++ group = NULL; ++ + /* skip over head */ + s_current = w_current->page_current->selection2_head->next; + +@@ -3651,6 +3652,7 @@ color_edit_dialog (TOPLEVEL *w_current) + GtkWidget *buttonapply = NULL; + GtkWidget *optionmenu; + GtkWidget *vbox, *action_area; ++ int select_index = 0; + + if (!w_current->clwindow) { + w_current->clwindow = x_create_dialog_box(&vbox, &action_area); +@@ -3679,7 +3681,6 @@ color_edit_dialog (TOPLEVEL *w_current) + #endif + + optionmenu = gtk_option_menu_new (); +- int select_index = 0; + gtk_option_menu_set_menu(GTK_OPTION_MENU(optionmenu), + create_color_menu (w_current, &select_index)); + gtk_option_menu_set_history(GTK_OPTION_MENU (optionmenu), select_index); diff --git a/cad/gschem/patches/patch-ab b/cad/gschem/patches/patch-ab new file mode 100644 index 00000000000..7c867a67c1c --- /dev/null +++ b/cad/gschem/patches/patch-ab @@ -0,0 +1,55 @@ +$NetBSD: patch-ab,v 1.6 2005/09/09 12:07:23 dmcmahill Exp $ + +--- src/x_dialog.c.orig 2005-08-20 14:27:39.000000000 +0000 ++++ src/x_dialog.c +@@ -555,6 +555,7 @@ text_edit_dialog(TOPLEVEL * w_current, c + char *text_size_string; + int len; + int num_selected; ++ int select_index = 0; + + num_selected = + o_selection_return_num(w_current->page_current->selection2_head); +@@ -632,7 +633,6 @@ text_edit_dialog(TOPLEVEL * w_current, c + gtk_widget_show(label); + + optionmenu = gtk_option_menu_new(); +- int select_index = 0; + + gtk_option_menu_set_menu(GTK_OPTION_MENU(optionmenu), + create_color_menu(w_current, &select_index)); +@@ -2638,14 +2638,15 @@ static GtkWidget *create_color_menu(TOPL + char *temp = NULL; + int found = 0; + +- menu = gtk_menu_new(); +- group = NULL; +- + /* first lets see if we have a selected object, if so select its color */ + int select_col = -1; + int item_index = 0; + SELECTION *s_current = NULL; + OBJECT *object = NULL; ++ ++ menu = gtk_menu_new(); ++ group = NULL; ++ + /* skip over head */ + s_current = w_current->page_current->selection2_head->next; + +@@ -2788,6 +2789,7 @@ void color_edit_dialog(TOPLEVEL * w_curr + GtkWidget *buttonapply = NULL; + GtkWidget *optionmenu; + GtkWidget *vbox, *action_area; ++ int select_index = 0; + + if (!w_current->clwindow) { + w_current->clwindow = x_create_dialog_box(&vbox, &action_area); +@@ -2815,7 +2817,6 @@ void color_edit_dialog(TOPLEVEL * w_curr + #endif + + optionmenu = gtk_option_menu_new(); +- int select_index = 0; + gtk_option_menu_set_menu(GTK_OPTION_MENU(optionmenu), + create_color_menu(w_current, &select_index)); + gtk_option_menu_set_history(GTK_OPTION_MENU(optionmenu), select_index); -- cgit v1.2.3