Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!wuarchive!uunet!stanford.edu!agate!ucbvax!gdstech.grumman.com!englund From: englund@gdstech.grumman.com (Dave Englund) Newsgroups: comp.sys.sgi Subject: RE: Forms 1.2 under IRIX 3.2 Message-ID: <9105071227.AA09119@gdstech.grumman.com> Date: 7 May 91 12:27:13 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 75 I've managed to hack Forms 1.2 to run under IRIX 3.2. There aren't that many changes necessary, so I'll just list them here. Changes in "forms.h" line 36: void (*form_call_back)(struct objs *); line 76: void (*obj_call_back)(struct objs *, long); These changes in the header require these chnages in the ".c" files" events.c : change all occurrences of: obj->form->call_back TO obj->form->form_call_back obj->call_back TO obj->obj_call_back objects.c change all occurrences of: form->call_back TO form->form_call_back ob->call_back TO ob->obj_call_back Those changes are enough to get the package to compile, but alas are not enough to make the package work correctly. The remaining problems have to do with the C compiler promoting floats to doubles when passing them as arguments. More changes in "forms.h" All of the prototypes of the forms: OBJECT *add_{sometypeofobject}(int, float, float, float, float, char []); should become: OBJECT *add_{sometypeofobject}(int, double, double, double, double, char []); These changes require you to change the corresponding function headers in the {sometypeofobject}.c files. The handle_{something} routines also need their float arguments changed to double. Here is a list of the routines that need there declarations changed: NEW.c:static int handle_NEW NEW.c:OBJECT *add_NEW bitmap.c:static int handle_bitmap bitmap.c:OBJECT *add_bitmap box.c:static int handle_box box.c:OBJECT *add_box browser.c:static int handle_browser browser.c:OBJECT *add_browser button.c:static int handle_it button.c:static OBJECT *add_it button.c:OBJECT *add_button button.c:OBJECT *add_lightbutton button.c:OBJECT *add_roundbutton choice.c:static int handle_choice choice.c:OBJECT *add_choice clock.c:static int handle_clock clock.c:OBJECT *add_clock default.c:static int handle_default default.c:OBJECT *add_default dial.c:static int handle_dial dial.c:OBJECT *add_dial free.c:OBJECT *add_free input.c:static int handle_input input.c:OBJECT *add_input menu.c:static int handle_menu menu.c:OBJECT *add_menu positioner.c:static int handle_positioner positioner.c:OBJECT *add_positioner slider.c:static int handle_slider slider.c:OBJECT *add_slider text.c:static int handle_text text.c:OBJECT *add_text It looks like a lot, but something like a keyboard macro in emacs, the changes are done pretty easily. Good Luck! Dave Englund | #include englund@gdstech.grumman.com | main() Grumman Corp. | { Corporate Research Center | printf("hello, world\n"); Bethpage, NY | }