Search
lxdream.org :: lxdream/src/main.c :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/main.c
changeset 1024:c67f2d61ab97
prev1015:ad448bedc48a
next1027:4e527bc96109
author nkeynes
date Sat Jun 13 00:50:48 2009 +0000 (12 years ago)
permissions -rw-r--r--
last change Build drivers with library dependencies as shared objects (ie plugins)
file annotate diff log raw
1.1 --- a/src/main.c Tue Jun 02 23:16:26 2009 +0000
1.2 +++ b/src/main.c Sat Jun 13 00:50:48 2009 +0000
1.3 @@ -36,6 +36,7 @@
1.4 #include "sh4/sh4.h"
1.5 #include "aica/armdasm.h"
1.6 #include "hotkeys.h"
1.7 +#include "plugin.h"
1.8
1.9 char *option_list = "a:A:c:dfg:G:hHl:m:npt:T:uvV:x?";
1.10 struct option longopts[] = {
1.11 @@ -128,11 +129,6 @@
1.12 break;
1.13 case 'A': /* Audio driver */
1.14 audio_driver_name = optarg;
1.15 - if( strcmp(audio_driver_name, "?") == 0 ) {
1.16 - print_version();
1.17 - print_audio_drivers(stdout);
1.18 - exit(0);
1.19 - }
1.20 break;
1.21 case 'c': /* Config file */
1.22 lxdream_set_config_filename(optarg);
1.23 @@ -194,11 +190,6 @@
1.24 break;
1.25 case 'V': /* Video driver */
1.26 display_driver_name = optarg;
1.27 - if( strcmp(display_driver_name,"?") == 0 ) {
1.28 - print_version();
1.29 - print_display_drivers(stdout);
1.30 - exit(0);
1.31 - }
1.32 break;
1.33 case 'x': /* Disable translator */
1.34 use_xlat = FALSE;
1.35 @@ -206,7 +197,24 @@
1.36 }
1.37 }
1.38
1.39 +#ifdef ENABLE_SHARED
1.40 + plugin_init(get_plugin_path());
1.41 +#endif
1.42 +
1.43 lxdream_load_config( );
1.44 +
1.45 + if( audio_driver_name != NULL && strcmp(audio_driver_name, "?") == 0 ) {
1.46 + print_version();
1.47 + print_audio_drivers(stdout);
1.48 + exit(0);
1.49 + }
1.50 +
1.51 + if( display_driver_name != NULL && strcmp(display_driver_name,"?") == 0 ) {
1.52 + print_version();
1.53 + print_display_drivers(stdout);
1.54 + exit(0);
1.55 + }
1.56 +
1.57 gdrom_list_init();
1.58
1.59 if( aica_program == NULL ) {
.