1.1 --- a/src/main.c Mon Dec 26 03:54:55 2005 +0000
1.2 +++ b/src/main.c Tue Jan 10 13:57:54 2006 +0000
1.5 - * $Id: main.c,v 1.9 2005-12-26 03:54:52 nkeynes Exp $
1.6 + * $Id: main.c,v 1.10 2006-01-10 13:57:54 nkeynes Exp $
1.8 * Main program, initializes dreamcast and gui, then passes control off to
1.9 * the gtk main loop (currently).
1.11 # include <config.h>
1.14 +#include <unistd.h>
1.16 #include "gui/gui.h"
1.18 #include "dreamcast.h"
1.20 +char *option_list = "a:A:V:p";
1.21 +char *aica_program = NULL;
1.22 +gboolean start_immediately = FALSE;
1.24 int main (int argc, char *argv[])
1.28 - bindtextdomain (PACKAGE, PACKAGE_LOCALE_DIR);
1.29 - textdomain (PACKAGE);
1.30 + bindtextdomain (PACKAGE, PACKAGE_LOCALE_DIR);
1.31 + textdomain (PACKAGE);
1.35 + while( (opt = getopt( argc, argv, option_list )) != -1 ) {
1.37 + case 'a': /* AICA only mode - argument is an AICA program */
1.38 + aica_program = optarg;
1.40 + case 'A': /* Audio driver */
1.42 + case 'V': /* Video driver */
1.44 + case 'p': /* Start immediately */
1.45 + start_immediately = TRUE;
1.49 - gnome_init ("dreamon", VERSION, argc, argv);
1.51 - dreamcast_register_module( >k_gui_module );
1.53 - INFO( "DreamOn! ready..." );
1.54 + if( aica_program == NULL ) {
1.56 + gnome_init ("dreamon", VERSION, argc, argv);
1.58 + dreamcast_register_module( >k_gui_module );
1.60 + dreamcast_configure_aica_only();
1.61 + mem_load_block( aica_program, 0x00800000, 2048*1024 );
1.62 + gnome_init ("dreamon", VERSION, argc, argv);
1.63 + dreamcast_register_module( >k_gui_module );
1.64 + set_disassembly_cpu( main_debug, "ARM7" );
1.69 + INFO( "DreamOn! ready..." );
1.70 + if( start_immediately )