Added debian patchset. It fix some small issues and allows compilation with gcc-4...
authorPeter Volkov <pva@gentoo.org>
Fri, 16 Feb 2007 15:50:01 +0000 (15:50 +0000)
committerPeter Volkov <pva@gentoo.org>
Fri, 16 Feb 2007 15:50:01 +0000 (15:50 +0000)
Package-Manager: portage-2.1.2-r9

14 files changed:
app-emulation/uae/ChangeLog
app-emulation/uae/files/digest-uae-0.8.25-r1 [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-allow_spaces_in_zip_filenames.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-close_window_hack.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-fix_save_config.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-fix_static_declatarions.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-gtk-ui-cleanup.patch [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-makefile_more_cleaning.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-memory_leaks_in_gui.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-preserve_home_in_writing_optionsfile.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-struct_uae_wrong_fields_name.diff [new file with mode: 0644]
app-emulation/uae/files/uae-0.8.25-uae_reset_args.diff [new file with mode: 0644]
app-emulation/uae/uae-0.8.25-r1.ebuild [new file with mode: 0644]
app-emulation/uae/uae-0.8.25.ebuild

index cd8c7a802cb26165c0f17d22cd16d60cf3ad022c..155efd45cfb2a98945fa7c3ab31263f4d1ff721b 100644 (file)
@@ -1,6 +1,23 @@
 # ChangeLog for app-emulation/uae
-# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/uae/ChangeLog,v 1.27 2006/12/14 17:50:21 pva Exp $
+# Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/uae/ChangeLog,v 1.28 2007/02/16 15:50:01 pva Exp $
+
+*uae-0.8.25-r1 (16 Feb 2007)
+
+  16 Feb 2007; <pva@gentoo.org>
+  +files/uae-0.8.25-allow_spaces_in_zip_filenames.diff,
+  +files/uae-0.8.25-close_window_hack.diff,
+  +files/uae-0.8.25-fix_save_config.diff,
+  +files/uae-0.8.25-fix_static_declatarions.diff,
+  +files/uae-0.8.25-gtk-ui-cleanup.patch,
+  +files/uae-0.8.25-makefile_more_cleaning.diff,
+  +files/uae-0.8.25-memory_leaks_in_gui.diff,
+  +files/uae-0.8.25-preserve_home_in_writing_optionsfile.diff,
+  +files/uae-0.8.25-struct_uae_wrong_fields_name.diff,
+  +files/uae-0.8.25-uae_reset_args.diff, uae-0.8.25.ebuild,
+  +uae-0.8.25-r1.ebuild:
+  Added debian patchset. It fix some small issues and allows compilation with
+  gcc-4.x but compilation with sdl is still broken.
 
 *uae-0.8.25 (14 Dec 2006)
 
diff --git a/app-emulation/uae/files/digest-uae-0.8.25-r1 b/app-emulation/uae/files/digest-uae-0.8.25-r1
new file mode 100644 (file)
index 0000000..1c1390f
--- /dev/null
@@ -0,0 +1,3 @@
+MD5 e660ca2bec3c016c978ef88117b0c432 uae-0.8.25.tar.gz 970727
+RMD160 6990dc7aaf43c8bda0d7b86e6d0ae164209d1eb1 uae-0.8.25.tar.gz 970727
+SHA256 611a7e04dd77080d87c7e9680aed997ed2be45116eec91613eb36a85235a686a uae-0.8.25.tar.gz 970727
diff --git a/app-emulation/uae/files/uae-0.8.25-allow_spaces_in_zip_filenames.diff b/app-emulation/uae/files/uae-0.8.25-allow_spaces_in_zip_filenames.diff
new file mode 100644 (file)
index 0000000..629ae70
--- /dev/null
@@ -0,0 +1,18 @@
+## 03_allow_spaces_in_zip_filenames.dpatch by Florian Ernst <florian@debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Allow spaces in filenames for zipped files, bug#238678
+
+@DPATCH@
+diff -urNad uae-0.8.25~/src/zfile.c uae-0.8.25/src/zfile.c
+--- uae-0.8.25~/src/zfile.c    2005-07-01 17:53:26.000000000 +0200
++++ uae-0.8.25/src/zfile.c     2005-11-08 01:17:59.000000000 +0100
+@@ -126,7 +126,7 @@
+     if (!dst)
+       return 1;
+ #if defined AMIGA || defined __unix
+-    sprintf (cmd, "unzip -p %s '*.adf' >%s", src, dst);
++    sprintf (cmd, "unzip -p \"%s\" '*.adf' >%s", src, dst);
+     return !system (cmd);
+ #endif
+ }
diff --git a/app-emulation/uae/files/uae-0.8.25-close_window_hack.diff b/app-emulation/uae/files/uae-0.8.25-close_window_hack.diff
new file mode 100644 (file)
index 0000000..8607eb7
--- /dev/null
@@ -0,0 +1,33 @@
+The program did't quit after closing the GUI window with the close button, so
+we force the backend to exit, just to make the user happy.
+
+Antonio Ospite <ospite@studenti.unina.it>
+
+diff -bpruN uae-0.8.25/src/gtkui.c uae-0.8.25_patched/src/gtkui.c
+--- uae-0.8.25/src/gtkui.c     2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25_patched/src/gtkui.c     2006-06-08 22:38:34.000000000 +0200
+@@ -557,7 +557,8 @@ static int my_idle (void)
+       }
+     }
+-    if (gtk_notebook_get_current_page (GTK_NOTEBOOK (notebook)) == 0) {
++    int ret = gtk_notebook_get_current_page (GTK_NOTEBOOK (notebook));
++    if (ret == 0) {
+       for (i = 0; i < 5; i++) {
+           unsigned int mask = 1 << i;
+           unsigned int on = leds & mask;
+@@ -570,6 +571,14 @@ static int my_idle (void)
+       }
+       prevledstate = leds;
+     }
++
++    /* XXX Ugly hack here:
++     * exit if the gui gives error,
++     * this happens when we close the window.
++     */
++    if (ret < 0)
++      exit(0);
++
+   out:
+     return 1;
+ }
diff --git a/app-emulation/uae/files/uae-0.8.25-fix_save_config.diff b/app-emulation/uae/files/uae-0.8.25-fix_save_config.diff
new file mode 100644 (file)
index 0000000..c8b6630
--- /dev/null
@@ -0,0 +1,16 @@
+The program did't save the changed version of the preferences structure.
+
+Antonio Ospite <ospite@studenti.unina.it>
+
+diff -bpruN uae-0.8.25/src/gtkui.c uae-0.8.25_patched/src/gtkui.c
+--- uae-0.8.25/src/gtkui.c     2006-06-08 23:57:36.000000000 +0200
++++ uae-0.8.25_patched/src/gtkui.c     2006-06-09 09:31:08.000000000 +0200
+@@ -282,7 +282,7 @@ static void save_config (void)
+       write_log ("Error saving options file!\n");
+       return;
+     }
+-    save_options (f, &currprefs);
++    save_options (f, &changed_prefs);
+     fclose (f);
+ }
diff --git a/app-emulation/uae/files/uae-0.8.25-fix_static_declatarions.diff b/app-emulation/uae/files/uae-0.8.25-fix_static_declatarions.diff
new file mode 100644 (file)
index 0000000..c22a743
--- /dev/null
@@ -0,0 +1,89 @@
+Fix some compilations errors due to external use of static variables.
+
+Antonio Ospite <ospite@studenti.unina.it>
+
+diff -pruN uae-0.8.25.orig/src/autoconf.c uae-0.8.25/src/autoconf.c
+--- uae-0.8.25.orig/src/autoconf.c     2006-06-07 15:31:17.000000000 +0200
++++ uae-0.8.25/src/autoconf.c  2006-06-07 15:38:03.000000000 +0200
+@@ -218,7 +218,7 @@ uaecptr EXPANSION_cddevice;
+ /* ROM tag area memory access */
+-static uae_u8 *rtarea;
++uae_u8 *rtarea;
+ static uae_u32 rtarea_lget (uaecptr) REGPARAM;
+ static uae_u32 rtarea_wget (uaecptr) REGPARAM;
+diff -pruN uae-0.8.25.orig/src/cia.c uae-0.8.25/src/cia.c
+--- uae-0.8.25.orig/src/cia.c  2006-06-07 15:31:17.000000000 +0200
++++ uae-0.8.25/src/cia.c       2006-06-07 15:38:03.000000000 +0200
+@@ -46,18 +46,18 @@ static unsigned int clock_control_d = RT
+ static unsigned int clock_control_e = 0;
+ static unsigned int clock_control_f = RTC_F_24_12;
+-static unsigned int ciaaicr, ciaaimask, ciabicr, ciabimask;
+-static unsigned int ciaacra, ciaacrb, ciabcra, ciabcrb;
++unsigned int ciaaicr, ciaaimask, ciabicr, ciabimask;
++unsigned int ciaacra, ciaacrb, ciabcra, ciabcrb;
+ /* Values of the CIA timers.  */
+-static unsigned long ciaata, ciaatb, ciabta, ciabtb;
++unsigned long ciaata, ciaatb, ciabta, ciabtb;
+ /* Computed by compute_passed_time.  */
+ static unsigned long ciaata_passed, ciaatb_passed, ciabta_passed, ciabtb_passed;
+-static unsigned long ciaatod, ciabtod, ciaatol, ciabtol, ciaaalarm, ciabalarm;
+-static int ciaatlatch, ciabtlatch;
++unsigned long ciaatod, ciabtod, ciaatol, ciabtol, ciaaalarm, ciabalarm;
++int ciaatlatch, ciabtlatch;
+-static unsigned int ciabpra;
++unsigned int ciabpra;
+ unsigned int gui_ledstate;
+diff -pruN uae-0.8.25.orig/src/custom.c uae-0.8.25/src/custom.c
+--- uae-0.8.25.orig/src/custom.c       2006-06-07 15:31:17.000000000 +0200
++++ uae-0.8.25/src/custom.c    2006-06-07 15:38:03.000000000 +0200
+@@ -111,7 +111,8 @@ static unsigned int sprctl[MAX_SPRITES],
+ static uae_u16 sprdata[MAX_SPRITES][4], sprdatb[MAX_SPRITES][4];
+ static int sprite_last_drawn_at[MAX_SPRITES];
+ static int last_sprite_point, nr_armed;
+-static int sprite_width, sprres, sprite_buffer_res;
++static int sprres, sprite_buffer_res;
++int sprite_width;
+ static uae_u32 bpl1dat, bpl2dat, bpl3dat, bpl4dat, bpl5dat, bpl6dat, bpl7dat, bpl8dat;
+ static uae_s16 bpl1mod, bpl2mod;
+@@ -234,7 +235,7 @@ struct decision line_decisions[2 * (MAXV
+ struct draw_info line_drawinfo[2][2 * (MAXVPOS + 1) + 1];
+ struct color_entry color_tables[2][(MAXVPOS + 1) * 2];
+-static int next_sprite_entry = 0;
++int next_sprite_entry = 0;
+ static int prev_next_sprite_entry;
+ static int next_sprite_forced = 1;
+diff -pruN uae-0.8.25.orig/src/inputdevice.c uae-0.8.25/src/inputdevice.c
+--- uae-0.8.25.orig/src/inputdevice.c  2006-06-07 15:31:17.000000000 +0200
++++ uae-0.8.25/src/inputdevice.c       2006-06-07 15:40:17.000000000 +0200
+@@ -511,8 +511,8 @@ void read_inputdevice_config (struct uae
+ /* Mousehack stuff */
+-static int ievent_alive = 0;
+-static int lastmx, lastmy;
++int ievent_alive = 0;
++int lastmx, lastmy;
+ int mousehack_alive (void)
+ {
+@@ -1739,7 +1739,7 @@ int inputdevice_translatekeycode (int ke
+     return 0;
+ }
+-static struct inputdevice_functions idev[3];
++struct inputdevice_functions idev[3];
+ void inputdevice_init (void)
+ {
diff --git a/app-emulation/uae/files/uae-0.8.25-gtk-ui-cleanup.patch b/app-emulation/uae/files/uae-0.8.25-gtk-ui-cleanup.patch
new file mode 100644 (file)
index 0000000..2c05d4d
--- /dev/null
@@ -0,0 +1,47 @@
+--- uae-0.8.25/src/gtkui.c.orig        2007-02-16 18:40:02.000000000 +0300
++++ uae-0.8.25/src/gtkui.c     2007-02-16 18:40:06.000000000 +0300
+@@ -762,8 +762,8 @@
+       return;
+     write_comm_pipe_int (&from_gui_pipe, 0, 0);
+-    write_comm_pipe_int (&from_gui_pipe, (int)data, 1);
+-    gtk_label_set_text (GTK_LABEL (disk_text_widget[(int)data]), "");
++    write_comm_pipe_int (&from_gui_pipe, GPOINTER_TO_INT(data), 1);
++    gtk_label_set_text (GTK_LABEL (disk_text_widget[GPOINTER_TO_INT(data)]), "");
+ }
+ static void pause_uae (void)
+@@ -851,7 +851,7 @@
+ static void did_insert (GtkWidget *w, gpointer data)
+ {
+-    int n = (int)data;
++    int n = GPOINTER_TO_INT(data);
+     if (filesel_active != -1)
+       return;
+     filesel_active = n;
+@@ -1131,7 +1131,7 @@
+     gdk_color_alloc (colormap, led_off + nr);
+     led_widgets[nr] = thing;
+     gtk_signal_connect (GTK_OBJECT (thing), "event",
+-                      (GtkSignalFunc) driveled_event, (gpointer) thing);
++                      (GtkSignalFunc) driveled_event, GINT_TO_POINTER(thing));
+     gtk_widget_show (thing);
+     thing = gtk_preview_new (GTK_PREVIEW_COLOR);
+@@ -1198,13 +1198,13 @@
+       gtk_box_pack_start (GTK_BOX (buttonbox), thing, FALSE, TRUE, 0);
+       gtk_widget_show (thing);
+       disk_eject_widget[i] = thing;
+-      gtk_signal_connect (GTK_OBJECT (thing), "clicked", (GtkSignalFunc) did_eject, (gpointer) i);
++      gtk_signal_connect (GTK_OBJECT (thing), "clicked", (GtkSignalFunc) did_eject, GINT_TO_POINTER(i));
+       thing = gtk_button_new_with_label ("Insert");
+       gtk_box_pack_start (GTK_BOX (buttonbox), thing, FALSE, TRUE, 0);
+       gtk_widget_show (thing);
+       disk_insert_widget[i] = thing;
+-      gtk_signal_connect (GTK_OBJECT (thing), "clicked", (GtkSignalFunc) did_insert, (gpointer) i);
++      gtk_signal_connect (GTK_OBJECT (thing), "clicked", (GtkSignalFunc) did_insert, GINT_TO_POINTER(i));
+     }
+     add_empty_vbox (vbox);
diff --git a/app-emulation/uae/files/uae-0.8.25-makefile_more_cleaning.diff b/app-emulation/uae/files/uae-0.8.25-makefile_more_cleaning.diff
new file mode 100644 (file)
index 0000000..f6c1d42
--- /dev/null
@@ -0,0 +1,16 @@
+Do some more cleaning, so we can build packages from the pristine upstream
+source even after the very first build.
+
+Antonio Ospite <ospite@studenti.unina.it>
+
+diff -pruN uae-0.8.25.orig/Makefile.in uae-0.8.25/Makefile.in
+--- uae-0.8.25.orig/Makefile.in        2006-06-07 15:31:17.000000000 +0200
++++ uae-0.8.25/Makefile.in     2006-06-07 16:12:12.000000000 +0200
+@@ -15,3 +15,7 @@ streifenfrei:
+       cd src && $(MAKE) streifenfrei
+       rm -f uae readdisk
+       rm -f config.cache config.log config.status Makefile
++      rm -f confdefs.h
++      rm -f src/tools/Makefile src/tools/config.* \
++              src/tools/cpudefs.c src/tools/sysconfig.h
++      rm -f src/md-fpp.h
diff --git a/app-emulation/uae/files/uae-0.8.25-memory_leaks_in_gui.diff b/app-emulation/uae/files/uae-0.8.25-memory_leaks_in_gui.diff
new file mode 100644 (file)
index 0000000..9ce71c2
--- /dev/null
@@ -0,0 +1,29 @@
+## 02_memory_leaks_in_gui.dpatch by Florian Ernst <florian@debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Fix memory leaks in GUI code as mentioned in bug#201563
+
+@DPATCH@
+diff -urNad uae-0.8.25~/src/gtkui.c uae-0.8.25/src/gtkui.c
+--- uae-0.8.25~/src/gtkui.c    2005-07-02 18:24:02.000000000 +0200
++++ uae-0.8.25/src/gtkui.c     2005-11-08 01:12:34.000000000 +0100
+@@ -798,7 +798,7 @@
+     uae_sem_post (&gui_sem);
+     write_comm_pipe_int (&from_gui_pipe, 1, 0);
+     write_comm_pipe_int (&from_gui_pipe, filesel_active, 1);
+-    gtk_label_set_text (GTK_LABEL (disk_text_widget[filesel_active]), strdup (s));
++    gtk_label_set_text (GTK_LABEL (disk_text_widget[filesel_active]), s);
+     filesel_active = -1;
+     enable_disk_buttons (1);
+     gtk_widget_destroy (disk_selector);
+diff -urNad uae-0.8.25~/src/xwin.c uae-0.8.25/src/xwin.c
+--- uae-0.8.25~/src/xwin.c     2005-07-02 18:24:06.000000000 +0200
++++ uae-0.8.25/src/xwin.c      2005-11-08 01:13:01.000000000 +0100
+@@ -758,6 +758,7 @@
+     hints->window_group = mywin;
+     hints->flags = WindowGroupHint;
+     XSetWMHints(display, mywin, hints);
++    XFree(hints);
+     XMapRaised (display, mywin);
+     XSync (display, 0);
diff --git a/app-emulation/uae/files/uae-0.8.25-preserve_home_in_writing_optionsfile.diff b/app-emulation/uae/files/uae-0.8.25-preserve_home_in_writing_optionsfile.diff
new file mode 100644 (file)
index 0000000..eee7658
--- /dev/null
@@ -0,0 +1,28 @@
+Keep saving optionsfile to home dir, even if there is not one when reading
+config for the first time.
+
+Antonio Ospite <ospite@studenti.unina.it>
+
+diff -bpruN uae-0.8.25/src/main.c uae-0.8.25_patched/src/main.c
+--- uae-0.8.25/src/main.c      2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25_patched/src/main.c      2006-06-08 20:33:05.000000000 +0200
+@@ -357,6 +357,7 @@ void parse_cmdline (int argc, char **arg
+ static void parse_cmdline_and_init_file (int argc, char **argv)
+ {
+     char *home;
++    char *pwd_optionsfile;
+     strcpy (optionsfile, "");
+@@ -374,8 +375,9 @@ static void parse_cmdline_and_init_file 
+     if (! cfgfile_load (&currprefs, optionsfile)) {
+ #ifdef OPTIONS_IN_HOME
+       /* sam: if not found in $HOME then look in current directory */
+-      strcpy (optionsfile, OPTIONSFILENAME);
+-      cfgfile_load (&currprefs, optionsfile);
++  /* ao: but let's use a temporary name, so we save to home dir, yet :) */
++      strcpy (pwd_optionsfile, OPTIONSFILENAME);
++      cfgfile_load (&currprefs, pwd_optionsfile);
+ #endif
+     }
diff --git a/app-emulation/uae/files/uae-0.8.25-struct_uae_wrong_fields_name.diff b/app-emulation/uae/files/uae-0.8.25-struct_uae_wrong_fields_name.diff
new file mode 100644 (file)
index 0000000..cd8d7e0
--- /dev/null
@@ -0,0 +1,18 @@
+Somewhere wrong (old) names are used in accessing the preferences structure.
+
+This is just a remainder for the upstream!!
+
+Antonio Ospite <ospite@studenti.unina.it>
+
+diff -pruN uae-0.8.25/src/tui.c uae-0.8.25_patched/src/tui.c
+--- uae-0.8.25/src/tui.c       2006-06-07 17:45:55.000000000 +0200
++++ uae-0.8.25_patched/src/tui.c       2006-06-07 17:55:39.000000000 +0200
+@@ -606,7 +606,7 @@ static void SoundOptions (void)
+               currprefs.sound_freq = atoi (tmp);
+           break;
+        case 5:
+-          currprefs.stereo = (currprefs.stereo + 1) % 3;
++          currprefs.sound_stereo = (currprefs.sound_stereo + 1) % 3;
+           break;
+       }
+     }
diff --git a/app-emulation/uae/files/uae-0.8.25-uae_reset_args.diff b/app-emulation/uae/files/uae-0.8.25-uae_reset_args.diff
new file mode 100644 (file)
index 0000000..f9bf6e3
--- /dev/null
@@ -0,0 +1,102 @@
+uae_reset() now wants some argument!
+
+Antonio Ospite <ospite@studenti.unina.it>
+
+diff -pruN uae-0.8.25___orig/src/ncurses.c uae-0.8.25/src/ncurses.c
+--- uae-0.8.25___orig/src/ncurses.c    2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/ncurses.c   2006-06-07 17:42:33.000000000 +0200
+@@ -596,7 +596,7 @@ void handle_events(void)
+       if (ch == 16) --lastmy; /* ^P */
+       if (ch == 11) {buttonstate[0] = keydelay;ch = 0;} /* ^K */
+       if (ch == 25) {buttonstate[2] = keydelay;ch = 0;} /* ^Y */
+-      if (ch == 15) uae_reset (); /* ^O */
++      if (ch == 15) uae_reset (0); /* ^O */
+       if (ch == 17) uae_quit (); /* ^Q */
+       if (ch == KEY_F(1)) {
+         curses_insert_disk();
+diff -pruN uae-0.8.25___orig/src/NeXTwin.m uae-0.8.25/src/NeXTwin.m
+--- uae-0.8.25___orig/src/NeXTwin.m    2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/NeXTwin.m   2006-06-07 17:42:15.000000000 +0200
+@@ -86,7 +86,7 @@ static int keycode2amiga(NXEvent * theEv
+ @implementation AmigaView
+ -reset:sender
+       {
+-      uae_reset();
++      uae_reset(0);
+       //m68k_reset();
+       return self;
+       }
+diff -pruN uae-0.8.25___orig/src/od-beos/beos.cpp uae-0.8.25/src/od-beos/beos.cpp
+--- uae-0.8.25___orig/src/od-beos/beos.cpp     2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/od-beos/beos.cpp    2006-06-07 17:43:48.000000000 +0200
+@@ -719,7 +719,7 @@ void handle_events(void)
+       uint32 mouse_buttons;
+       if (reset_thyself) {
+-              uae_reset();
++              uae_reset(0);
+               reset_thyself = false;
+       }
+diff -pruN uae-0.8.25___orig/src/od-win32/keyboard.c uae-0.8.25/src/od-win32/keyboard.c
+--- uae-0.8.25___orig/src/od-win32/keyboard.c  2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/od-win32/keyboard.c 2006-06-07 17:44:04.000000000 +0200
+@@ -489,8 +489,8 @@ int my_kbd_handler (int keycode, int sca
+       record_key ((akey << 1) + 1);
+     /* "Affengriff" */
+-      if(  (keystate[AK_CTRL] || keystate[AK_RCTRL] ) && keystate[AK_LAMI] && keystate[AK_RAMI])uae_reset();
+-    //if(  (keystate[AK_CTRL] || keystate[AK_RCTRL] ) && keystate[AK_RAMI])uae_reset();
++      if(  (keystate[AK_CTRL] || keystate[AK_RCTRL] ) && keystate[AK_LAMI] && keystate[AK_RAMI])uae_reset(0);
++    //if(  (keystate[AK_CTRL] || keystate[AK_RCTRL] ) && keystate[AK_RAMI])uae_reset(0);
+     return 0;
+ }
+diff -pruN uae-0.8.25___orig/src/od-win32/win32gui.c uae-0.8.25/src/od-win32/win32gui.c
+--- uae-0.8.25___orig/src/od-win32/win32gui.c  2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/od-win32/win32gui.c 2006-06-07 17:44:16.000000000 +0200
+@@ -2261,7 +2261,7 @@ static BOOL CALLBACK MiscDlgProc (HWND h
+           }
+           break;
+       case IDC_RESETAMIGA:
+-          uae_reset();
++          uae_reset(0);
+           break;
+       case IDC_QUITEMU:
+           uae_quit();
+diff -pruN uae-0.8.25___orig/src/sdlgfx.c uae-0.8.25/src/sdlgfx.c
+--- uae-0.8.25___orig/src/sdlgfx.c     2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/sdlgfx.c    2006-06-07 17:42:57.000000000 +0200
+@@ -875,7 +875,7 @@ void handle_events (void)
+     /* Handle UAE reset */
+     if ((keystate[AK_CTRL] || keystate[AK_RCTRL]) && keystate[AK_LAMI] && keystate[AK_RAMI])
+-      uae_reset ();
++      uae_reset (0);
+ }
+ int check_prefs_changed_gfx (void)
+diff -pruN uae-0.8.25___orig/src/svga.c uae-0.8.25/src/svga.c
+--- uae-0.8.25___orig/src/svga.c       2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/svga.c      2006-06-07 17:43:17.000000000 +0200
+@@ -439,7 +439,7 @@ static void my_kbd_handler (int scancode
+     /* "Affengriff" */
+     if ((keystate[AK_CTRL] || keystate[AK_RCTRL]) && keystate[AK_LAMI] && keystate[AK_RAMI])
+-      uae_reset ();
++      uae_reset (0);
+ }
+ static void leave_graphics_mode (void)
+diff -pruN uae-0.8.25___orig/src/tui.c uae-0.8.25/src/tui.c
+--- uae-0.8.25___orig/src/tui.c        2006-06-07 17:41:49.000000000 +0200
++++ uae-0.8.25/src/tui.c       2006-06-07 17:43:32.000000000 +0200
+@@ -684,7 +684,7 @@ static int do_gui (int mode)
+            case 0: DiskOptions (); break;
+            case 1: OtherOptions (); break;
+            case 2: save_settings (); break;
+-           case 3: uae_reset (); break;
++           case 3: uae_reset (0); break;
+            case 4: uae_quit (); break;
+           }
+       }
diff --git a/app-emulation/uae/uae-0.8.25-r1.ebuild b/app-emulation/uae/uae-0.8.25-r1.ebuild
new file mode 100644 (file)
index 0000000..31b25d5
--- /dev/null
@@ -0,0 +1,75 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/uae/uae-0.8.25-r1.ebuild,v 1.1 2007/02/16 15:50:01 pva Exp $
+
+inherit eutils
+
+DESCRIPTION="The Umiquious Amiga Emulator"
+HOMEPAGE="http://www.freiburg.linux.de/~uae/"
+SRC_URI="ftp://ftp.freiburg.linux.de/pub/uae/sources/develop/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~x86 ~ppc ~amd64"
+IUSE="X dga svga ncurses alsa sdl-sound scsi gtk"
+
+DEPEND="X? ( x11-libs/libXext
+                       x11-libs/libXxf86vm
+                       dga? ( x11-libs/libXxf86dga ) )
+               !X? ( svga? ( media-libs/svgalib )
+                         !svga? ( sys-libs/ncurses ) )
+       alsa? ( media-libs/alsa-lib )
+       scsi? ( app-cdr/cdrtools )
+       gtk? ( x11-libs/gtk+ )"
+
+pkg_setup() {
+       if use X ; then
+               elog "Enabling X11 for video output."
+               my_config="$(use_with X x) $(use_enable X vidmode)"
+               use dga && my_config="${my_config} $(use_enable dga)"
+       elif use svga ; then
+               elog "Enabling svga for video output."
+               my_config="$(use_with svga svgalib)"
+       elif use ncurses ; then
+               elog "Enabling ncurses for video output."
+               my_config="$(use_with ncurses asciiart)"
+       else
+               ewarn "You have not enabled X or svga or ncruses in USE!"
+               ewarn "Video output is not selected. Falling back on ncurses..."
+               my_config="--with-asciiart"
+       fi
+
+       my_config="${my_config} $(use_with alsa)"
+       my_config="${my_config} $(use_enable gtk ui)"
+       my_config="${my_config} $(use_enable scsi scsi-device)"
+       my_config="${my_config} --enable-threads"
+}
+
+src_unpack() {
+       unpack ${A}
+
+       epatch "${FILESDIR}"/${P}-makefile_more_cleaning.diff
+       epatch "${FILESDIR}"/${P}-memory_leaks_in_gui.diff
+       epatch "${FILESDIR}"/${P}-allow_spaces_in_zip_filenames.diff
+       epatch "${FILESDIR}"/${P}-preserve_home_in_writing_optionsfile.diff
+       epatch "${FILESDIR}"/${P}-close_window_hack.diff
+       epatch "${FILESDIR}"/${P}-struct_uae_wrong_fields_name.diff
+       epatch "${FILESDIR}"/${P}-fix_save_config.diff
+       epatch "${FILESDIR}"/${P}-uae_reset_args.diff
+       epatch "${FILESDIR}"/${P}-fix_static_declatarions.diff
+       epatch "${FILESDIR}"/${P}-gtk-ui-cleanup.patch
+}
+
+src_compile() {
+       econf ${my_config} || die "configure failed"
+       emake -j1 || die "emake failed"
+}
+
+src_install() {
+       dobin uae readdisk || die
+       cp docs/unix/README docs/README.unix
+       dodoc docs/*
+
+       insinto /usr/share/uae/amiga-tools
+       doins amiga/{*hack,trans*,uae*}
+}
index 33fc5bc2fa3981839b315287706fecd6eea8b6cf..9daec11ea9238b0a9a44456004ced80cbe3c889d 100644 (file)
@@ -1,6 +1,6 @@
-# Copyright 1999-2006 Gentoo Foundation
+# Copyright 1999-2007 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/uae/uae-0.8.25.ebuild,v 1.1 2006/12/14 17:50:21 pva Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/uae/uae-0.8.25.ebuild,v 1.2 2007/02/16 15:50:01 pva Exp $
 
 inherit eutils
 
@@ -20,8 +20,8 @@ DEPEND="sdl? ( media-libs/libsdl )
                        !X? ( svga? ( media-libs/svgalib )
                                  !svga? ( ncurses? ( sys-libs/ncurses )
                                                   !ncurses? ( media-libs/libsdl ) ) ) )
-       alsa? ( media-libs/libsdl )
-       !alsa? ( sdl-sound? ( media-libs/alsa-lib ) )
+       alsa? ( media-libs/alsa-lib )
+       !alsa? ( sdl-sound? ( media-libs/libsdl ) )
        scsi? ( app-cdr/cdrtools )
        gtk? ( x11-libs/gtk+ )"
 
@@ -32,11 +32,11 @@ pkg_setup() {
        elif use X ; then
                elog "Enabling X11 for video output."
                my_config="$(use_with X x) $(use_enable X vidmode)"
-               use dga? && my_config="${my_config} $(use_enable dga)"
-       elif use svga? ; then
+               use dga && my_config="${my_config} $(use_enable dga)"
+       elif use svga ; then
                elog "Enabling svga for video output."
                my_config="$(use_with svga svgalib)"
-       elif use ncurses? ; then
+       elif use ncurses ; then
                elog "Enabling ncurses for video output."
                my_config="$(use_with ncurses asciiart)"
        else