diff --git a/Makefile.in b/Makefile.in index d83741a..903d123 100644 --- a/Makefile.in +++ b/Makefile.in @@ -89,8 +89,7 @@ build_triplet = @build@ host_triplet = @host@ subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/allegro.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ @@ -202,7 +201,6 @@ am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ -ALLEGRO_CONFIG = @ALLEGRO_CONFIG@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AUTOCONF = @AUTOCONF@ @@ -273,8 +271,6 @@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ -allegro_CFLAGS = @allegro_CFLAGS@ -allegro_LIBS = @allegro_LIBS@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ diff --git a/aclocal.m4 b/aclocal.m4 index 53df7ec..925cb54 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -2721,4 +2721,3 @@ AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR -m4_include([allegro.m4]) diff --git a/allegro.m4 b/allegro.m4 deleted file mode 100644 index 364cbac..0000000 --- a/allegro.m4 +++ /dev/null @@ -1,192 +0,0 @@ -# Configure paths for Allegro -# Shamelessly stolen from libxml.a4 -# Jon Rafkind 2004-06-06 -# Adapted from: -# Configure paths for libXML -# Toshio Kuratomi 2001-04-21 -# Adapted from: -# Configure paths for GLIB -# Owen Taylor 97-11-3 - -dnl AM_PATH_allegro([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) -dnl Test for allegro, and define allegro_CFLAGS and allegro_LIBS -dnl -AC_DEFUN([AM_PATH_ALLEGRO],[ -AC_ARG_WITH(allegro-prefix, - [ --with-allegro-prefix=PFX Prefix where liballegro is installed (optional)], - ALLEGRO_CONFIG_prefix="$withval", ALLEGRO_CONFIG_prefix="") -AC_ARG_WITH(allegro-exec-prefix, - [ --with-allegro-exec-prefix=PFX Exec prefix where liballegro is installed (optional)], - ALLEGRO_CONFIG_exec_prefix="$withval", ALLEGRO_CONFIG_exec_prefix="") -AC_ARG_ENABLE(allegrotest, - [ --disable-allegrotest Do not try to compile and run a test LIBallegro program],, - enable_allegrotest=yes) - - if test x$ALLEGRO_CONFIG_exec_prefix != x ; then - ALLEGRO_CONFIG_args="$ALLEGRO_CONFIG_args --exec-prefix=$ALLEGRO_CONFIG_exec_prefix" - if test x${ALLEGRO_CONFIG+set} != xset ; then - ALLEGRO_CONFIG=$ALLEGRO_CONFIG_exec_prefix/bin/allegro-config - fi - fi - if test x$ALLEGRO_CONFIG_prefix != x ; then - ALLEGRO_CONFIG_args="$ALLEGRO_CONFIG_args --prefix=$ALLEGRO_CONFIG_prefix" - if test x${ALLEGRO_CONFIG+set} != xset ; then - ALLEGRO_CONFIG=$ALLEGRO_CONFIG_prefix/bin/allegro-config - fi - fi - - AC_PATH_PROG(ALLEGRO_CONFIG, allegro-config, no) - min_allegro_version=ifelse([$1], ,4.0.0,[$1]) - AC_MSG_CHECKING(for Allegro - version >= $min_allegro_version) - no_allegro="" - if test "$ALLEGRO_CONFIG" = "no" ; then - no_allegro=yes - else - allegro_CFLAGS=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --cflags` - allegro_LIBS=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --libs` - ALLEGRO_CONFIG_major_version=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - ALLEGRO_CONFIG_minor_version=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` - ALLEGRO_CONFIG_micro_version=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` - if test "x$enable_allegrotest" = "xyes" ; then - ac_save_CFLAGS="$CFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $allegro_CFLAGS" - LIBS="$allegro_LIBS $LIBS" -dnl -dnl Now check if the installed liballegro is sufficiently new. -dnl (Also sanity checks the results of allegro-config to some extent) -dnl - rm -f conf.allegrotest - AC_TRY_RUN([ -#include -#include -#include -#include - -int -main() -{ - int allegro_major_version, allegro_minor_version, allegro_micro_version; - int major, minor, micro; - char *tmp_version; - int tmp_int_version; - - system("touch conf.allegrotest"); - - /* Capture allegro-config output via autoconf/configure variables */ - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = (char *)strdup("$min_allegro_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string from allegro-config\n", "$min_allegro_version"); - free(tmp_version); - exit(1); - } - free(tmp_version); - - /* Capture the version information from the header files */ - allegro_major_version = ALLEGRO_VERSION; - allegro_minor_version = ALLEGRO_SUB_VERSION; - allegro_micro_version = ALLEGRO_WIP_VERSION; - - /* Compare allegro-config output to the Allegro headers */ - if ((allegro_major_version != $ALLEGRO_CONFIG_major_version) || - (allegro_minor_version != $ALLEGRO_CONFIG_minor_version)) - - { - printf("*** Allegro header files (version %d.%d.%d) do not match\n", - allegro_major_version, allegro_minor_version, allegro_micro_version); - printf("*** allegro-config (version %d.%d.%d)\n", - $ALLEGRO_CONFIG_major_version, $ALLEGRO_CONFIG_minor_version, $ALLEGRO_CONFIG_micro_version); - return 1; - } -/* Compare the headers to the library to make sure we match */ - /* Less than ideal -- doesn't provide us with return value feedback, - * only exits if there's a serious mismatch between header and library. - */ - /* TODO: - * This doesnt work! - */ - /* ALLEGRO_TEST_VERSION; */ - - /* Test that the library is greater than our minimum version */ - if (($ALLEGRO_CONFIG_major_version > major) || - (($ALLEGRO_CONFIG_major_version == major) && ($ALLEGRO_CONFIG_minor_version > minor)) || - (($ALLEGRO_CONFIG_major_version == major) && ($ALLEGRO_CONFIG_minor_version == minor) && - ($ALLEGRO_CONFIG_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** An old version of Allegro (%d.%d.%d) was found.\n", - allegro_major_version, allegro_minor_version, allegro_micro_version); - printf("*** You need a version of Allegro newer than %d.%d.%d. The latest version of\n", - major, minor, micro); - printf("*** Allegro is always available from http://alleg.sf.net.\n"); - printf("***\n"); - printf("*** If you have already installed a sufficiently new version, this error\n"); - printf("*** probably means that the wrong copy of the allegro-config shell script is\n"); - printf("*** being found. The easiest way to fix this is to remove the old version\n"); - printf("*** of Allegro, but you can also set the ALLEGRO_CONFIG environment to point to the\n"); - printf("*** correct copy of allegro-config. (In this case, you will have to\n"); - printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); - printf("*** so that the correct libraries are found at run-time))\n"); - } - return 1; -} END_OF_MAIN() -],, no_allegro=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - if test "x$no_allegro" = x ; then - AC_MSG_RESULT(yes (version $ALLEGRO_CONFIG_major_version.$ALLEGRO_CONFIG_minor_version.$ALLEGRO_CONFIG_micro_version)) - ifelse([$2], , :, [$2]) - else - AC_MSG_RESULT(no) - if test "$ALLEGRO_CONFIG" = "no" ; then - echo "*** The allegro-config script installed by Allegro could not be found" - echo "*** If Allegro was installed in PREFIX, make sure PREFIX/bin is in" - echo "*** your path, or set the ALLEGRO_CONFIG environment variable to the" - echo "*** full path to allegro-config." - else - if test -f conf.allegrotest ; then - : - else - echo "*** Could not run Allegro test program, checking why..." - CFLAGS="$CFLAGS $allegro_CFLAGS" - LIBS="$LIBS $allegro_LIBS" - AC_TRY_LINK([ -#include -#include -], [ allegro_error; return 0;], - [ echo "*** The test program compiled, but did not run. This usually means" - echo "*** that the run-time linker is not finding Allegro or finding the wrong" - echo "*** version of Allegro. If it is not finding Allegro, you'll need to set your" - echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" - echo "*** to the installed location Also, make sure you have run ldconfig if that" - echo "*** is required on your system" - echo "***" - echo "*** If you have an old version installed, it is best to remove it, although" - echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], - [ echo "*** The test program failed to compile or link. See the file config.log for the" - echo "*** exact error that occured. This usually means Allegro was incorrectly installed" - echo "*** or that you have moved Allegro since it was installed. In the latter case, you" - echo "*** may want to edit the allegro-config script: $ALLEGRO_CONFIG" ]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - allegro_CFLAGS="" - allegro_LIBS="" - ifelse([$3], , :, [$3]) - fi - AC_SUBST(allegro_CFLAGS) - AC_SUBST(allegro_LIBS) - rm -f conf.allegrotest -]) diff --git a/configure b/configure index b5acc65..375d8c7 100755 --- a/configure +++ b/configure @@ -608,9 +608,6 @@ PKG_CONFIG_LIBDIR PKG_CONFIG_PATH PKG_CONFIG SDL2_FRAMEWORK -allegro_LIBS -allegro_CFLAGS -ALLEGRO_CONFIG USE_ALSA_FALSE USE_ALSA_TRUE USE_NETWORKING_FALSE @@ -728,12 +725,8 @@ enable_option_checking enable_silent_rules enable_dependency_tracking enable_debug -enable_wx enable_networking enable_alsa -with_allegro_prefix -with_allegro_exec_prefix -enable_allegrotest with_sdl_prefix with_sdl_exec_prefix enable_sdltest @@ -1396,18 +1389,14 @@ Optional Features: --disable-dependency-tracking speeds up one-time build --enable-debug build debug executable - --enable-wx use wxWidgets GUI --enable-networking enable networking --enable-alsa use ALSA for MIDI - --disable-allegrotest Do not try to compile and run a test LIBallegro program --disable-sdltest Do not try to compile and run a test SDL program --disable-sdlframework Do not search for SDL2.framework Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-allegro-prefix=PFX Prefix where liballegro is installed (optional) - --with-allegro-exec-prefix=PFX Exec prefix where liballegro is installed (optional) --with-sdl-prefix=PFX Prefix where SDL is installed (optional) --with-sdl-exec-prefix=PFX Exec prefix where SDL is installed (optional) --with-wxdir=PATH Use uninstalled version of wxWidgets in PATH @@ -4157,21 +4146,6 @@ else $as_echo "no" >&6; } fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use the wxWidgets-based GUI" >&5 -$as_echo_n "checking whether to use the wxWidgets-based GUI... " >&6; } -# Check whether --enable-wx was given. -if test "${enable_wx+set}" = set; then : - enableval=$enable_wx; -fi - -if test "$enable_wx" = "yes"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable networking" >&5 $as_echo_n "checking whether to enable networking... " >&6; } # Check whether --enable-networking was given. @@ -4282,280 +4256,7 @@ else fi -if test "$enable_wx" != "yes"; then - # Do not run test for Allegro with Win32/MinGW version, as binary builds have - # `allegro-config' missing. - # NOTE: For the following Autoconf macro to be supported, you need to extract - # allegro.m4 from the DOS/Windows Allegro sources (the file is contained - # in `misc') and copy it to this directory or MSYS's `/share/aclocal'. - if test "$OS" != "win"; then - - - - -# Check whether --with-allegro-prefix was given. -if test "${with_allegro_prefix+set}" = set; then : - withval=$with_allegro_prefix; ALLEGRO_CONFIG_prefix="$withval" -else - ALLEGRO_CONFIG_prefix="" -fi - - -# Check whether --with-allegro-exec-prefix was given. -if test "${with_allegro_exec_prefix+set}" = set; then : - withval=$with_allegro_exec_prefix; ALLEGRO_CONFIG_exec_prefix="$withval" -else - ALLEGRO_CONFIG_exec_prefix="" -fi - -# Check whether --enable-allegrotest was given. -if test "${enable_allegrotest+set}" = set; then : - enableval=$enable_allegrotest; -else - enable_allegrotest=yes -fi - - - if test x$ALLEGRO_CONFIG_exec_prefix != x ; then - ALLEGRO_CONFIG_args="$ALLEGRO_CONFIG_args --exec-prefix=$ALLEGRO_CONFIG_exec_prefix" - if test x${ALLEGRO_CONFIG+set} != xset ; then - ALLEGRO_CONFIG=$ALLEGRO_CONFIG_exec_prefix/bin/allegro-config - fi - fi - if test x$ALLEGRO_CONFIG_prefix != x ; then - ALLEGRO_CONFIG_args="$ALLEGRO_CONFIG_args --prefix=$ALLEGRO_CONFIG_prefix" - if test x${ALLEGRO_CONFIG+set} != xset ; then - ALLEGRO_CONFIG=$ALLEGRO_CONFIG_prefix/bin/allegro-config - fi - fi - - # Extract the first word of "allegro-config", so it can be a program name with args. -set dummy allegro-config; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_path_ALLEGRO_CONFIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $ALLEGRO_CONFIG in - [\\/]* | ?:[\\/]*) - ac_cv_path_ALLEGRO_CONFIG="$ALLEGRO_CONFIG" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_path_ALLEGRO_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - - test -z "$ac_cv_path_ALLEGRO_CONFIG" && ac_cv_path_ALLEGRO_CONFIG="no" - ;; -esac -fi -ALLEGRO_CONFIG=$ac_cv_path_ALLEGRO_CONFIG -if test -n "$ALLEGRO_CONFIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALLEGRO_CONFIG" >&5 -$as_echo "$ALLEGRO_CONFIG" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - min_allegro_version=4.0.0 - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Allegro - version >= $min_allegro_version" >&5 -$as_echo_n "checking for Allegro - version >= $min_allegro_version... " >&6; } - no_allegro="" - if test "$ALLEGRO_CONFIG" = "no" ; then - no_allegro=yes - else - allegro_CFLAGS=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --cflags` - allegro_LIBS=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --libs` - ALLEGRO_CONFIG_major_version=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --version | \ - sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` - ALLEGRO_CONFIG_minor_version=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --version | \ - sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` - ALLEGRO_CONFIG_micro_version=`$ALLEGRO_CONFIG $ALLEGRO_CONFIG_args --version | \ - sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` - if test "x$enable_allegrotest" = "xyes" ; then - ac_save_CFLAGS="$CFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $allegro_CFLAGS" - LIBS="$allegro_LIBS $LIBS" - rm -f conf.allegrotest - if test "$cross_compiling" = yes; then : - echo $ac_n "cross compiling; assumed OK... $ac_c" -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include -#include -#include -#include - -int -main() -{ - int allegro_major_version, allegro_minor_version, allegro_micro_version; - int major, minor, micro; - char *tmp_version; - int tmp_int_version; - - system("touch conf.allegrotest"); - - /* Capture allegro-config output via autoconf/configure variables */ - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = (char *)strdup("$min_allegro_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string from allegro-config\n", "$min_allegro_version"); - free(tmp_version); - exit(1); - } - free(tmp_version); - - /* Capture the version information from the header files */ - allegro_major_version = ALLEGRO_VERSION; - allegro_minor_version = ALLEGRO_SUB_VERSION; - allegro_micro_version = ALLEGRO_WIP_VERSION; - - /* Compare allegro-config output to the Allegro headers */ - if ((allegro_major_version != $ALLEGRO_CONFIG_major_version) || - (allegro_minor_version != $ALLEGRO_CONFIG_minor_version)) - - { - printf("*** Allegro header files (version %d.%d.%d) do not match\n", - allegro_major_version, allegro_minor_version, allegro_micro_version); - printf("*** allegro-config (version %d.%d.%d)\n", - $ALLEGRO_CONFIG_major_version, $ALLEGRO_CONFIG_minor_version, $ALLEGRO_CONFIG_micro_version); - return 1; - } -/* Compare the headers to the library to make sure we match */ - /* Less than ideal -- doesn't provide us with return value feedback, - * only exits if there's a serious mismatch between header and library. - */ - /* TODO: - * This doesnt work! - */ - /* ALLEGRO_TEST_VERSION; */ - - /* Test that the library is greater than our minimum version */ - if (($ALLEGRO_CONFIG_major_version > major) || - (($ALLEGRO_CONFIG_major_version == major) && ($ALLEGRO_CONFIG_minor_version > minor)) || - (($ALLEGRO_CONFIG_major_version == major) && ($ALLEGRO_CONFIG_minor_version == minor) && - ($ALLEGRO_CONFIG_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** An old version of Allegro (%d.%d.%d) was found.\n", - allegro_major_version, allegro_minor_version, allegro_micro_version); - printf("*** You need a version of Allegro newer than %d.%d.%d. The latest version of\n", - major, minor, micro); - printf("*** Allegro is always available from http://alleg.sf.net.\n"); - printf("***\n"); - printf("*** If you have already installed a sufficiently new version, this error\n"); - printf("*** probably means that the wrong copy of the allegro-config shell script is\n"); - printf("*** being found. The easiest way to fix this is to remove the old version\n"); - printf("*** of Allegro, but you can also set the ALLEGRO_CONFIG environment to point to the\n"); - printf("*** correct copy of allegro-config. (In this case, you will have to\n"); - printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); - printf("*** so that the correct libraries are found at run-time))\n"); - } - return 1; -} END_OF_MAIN() - -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - no_allegro=yes -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - if test "x$no_allegro" = x ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (version $ALLEGRO_CONFIG_major_version.$ALLEGRO_CONFIG_minor_version.$ALLEGRO_CONFIG_micro_version)" >&5 -$as_echo "yes (version $ALLEGRO_CONFIG_major_version.$ALLEGRO_CONFIG_minor_version.$ALLEGRO_CONFIG_micro_version)" >&6; } - : - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - if test "$ALLEGRO_CONFIG" = "no" ; then - echo "*** The allegro-config script installed by Allegro could not be found" - echo "*** If Allegro was installed in PREFIX, make sure PREFIX/bin is in" - echo "*** your path, or set the ALLEGRO_CONFIG environment variable to the" - echo "*** full path to allegro-config." - else - if test -f conf.allegrotest ; then - : - else - echo "*** Could not run Allegro test program, checking why..." - CFLAGS="$CFLAGS $allegro_CFLAGS" - LIBS="$LIBS $allegro_LIBS" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include -#include - -int -main () -{ - allegro_error; return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - echo "*** The test program compiled, but did not run. This usually means" - echo "*** that the run-time linker is not finding Allegro or finding the wrong" - echo "*** version of Allegro. If it is not finding Allegro, you'll need to set your" - echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" - echo "*** to the installed location Also, make sure you have run ldconfig if that" - echo "*** is required on your system" - echo "***" - echo "*** If you have an old version installed, it is best to remove it, although" - echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" -else - echo "*** The test program failed to compile or link. See the file config.log for the" - echo "*** exact error that occured. This usually means Allegro was incorrectly installed" - echo "*** or that you have moved Allegro since it was installed. In the latter case, you" - echo "*** may want to edit the allegro-config script: $ALLEGRO_CONFIG" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - allegro_CFLAGS="" - allegro_LIBS="" - as_fn_error $? "building PCem requires Allegro to be installed" "$LINENO" 5 - fi - - - rm -f conf.allegrotest - - fi -else - SDL_VERSION=2.0.1 +SDL_VERSION=2.0.1 @@ -4677,6 +4378,7 @@ $as_echo "no" >&6; } fi fi + # Check whether --with-sdl-prefix was given. if test "${with_sdl_prefix+set}" = set; then : withval=$with_sdl_prefix; sdl_prefix="$withval" @@ -5055,6 +4757,7 @@ rm -f core conftest.err conftest.$ac_objext \ + # Check whether --with-wxdir was given. if test "${with_wxdir+set}" = set; then : withval=$with_wxdir; wx_config_name="$withval/wx-config" @@ -5084,7 +4787,7 @@ else fi - reqwx=3.0.0 +reqwx=3.0.0 if test x${WX_CONFIG_NAME+set} != xset ; then @@ -5350,18 +5053,19 @@ $as_echo "no (version $WX_VERSION is not new enough)" >&6; } - if test "$wxWin" != 1; then - as_fn_error $? " - wxWidgets must be installed on your system. +if test "$wxWin" != 1; then + as_fn_error $? " + wxWidgets must be installed on your system. - Please check that wx-config is in path, the directory - where wxWidgets libraries are installed (returned by - 'wx-config --libs' or 'wx-config --static --libs' command) - is in LD_LIBRARY_PATH or equivalent variable and - wxWidgets version is $reqwx or above. - " "$LINENO" 5 - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for glGetError in -lGL" >&5 + Please check that wx-config is in path, the directory + where wxWidgets libraries are installed (returned by + 'wx-config --libs' or 'wx-config --static --libs' command) + is in LD_LIBRARY_PATH or equivalent variable and + wxWidgets version is $reqwx or above. + " "$LINENO" 5 +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for glGetError in -lGL" >&5 $as_echo_n "checking for glGetError in -lGL... " >&6; } if ${ac_cv_lib_GL_glGetError+:} false; then : $as_echo_n "(cached) " >&6 @@ -5406,12 +5110,11 @@ _ACEOF else \ - echo "You need to install the OpenGL library." - exit -1 + echo "You need to install the OpenGL library." + exit -1 fi - LIBS="$LIBS $WX_LIBS $SDL_LIBS" -fi +LIBS="$LIBS $WX_LIBS $SDL_LIBS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alGetError in -lopenal" >&5 $as_echo_n "checking for alGetError in -lopenal... " >&6; } diff --git a/configure.ac b/configure.ac index 93b22a6..b7b3422 100644 --- a/configure.ac +++ b/configure.ac @@ -24,15 +24,6 @@ else AC_MSG_RESULT([no]) fi -AC_MSG_CHECKING([whether to use the wxWidgets-based GUI]) -AC_ARG_ENABLE(wx, - AC_HELP_STRING([--enable-wx], [use wxWidgets GUI])) -if test "$enable_wx" = "yes"; then - AC_MSG_RESULT([yes]) -else - AC_MSG_RESULT([no]) -fi - AC_MSG_CHECKING([whether to enable networking]) AC_ARG_ENABLE(networking, AC_HELP_STRING([--enable-networking], [enable networking])) @@ -79,42 +70,32 @@ AM_CONDITIONAL(USE_WX, test "$enable_wx" = "yes") AM_CONDITIONAL(USE_NETWORKING, test "$enable_networking" = "yes") AM_CONDITIONAL(USE_ALSA, test "$enable_alsa" = "yes") -if test "$enable_wx" != "yes"; then - # Do not run test for Allegro with Win32/MinGW version, as binary builds have - # `allegro-config' missing. - # NOTE: For the following Autoconf macro to be supported, you need to extract - # allegro.m4 from the DOS/Windows Allegro sources (the file is contained - # in `misc') and copy it to this directory or MSYS's `/share/aclocal'. - if test "$OS" != "win"; then - AC_CONFIG_MACRO_DIR([./]) - AM_PATH_ALLEGRO(, , AC_MSG_ERROR(building PCem requires Allegro to be installed)) - fi -else - SDL_VERSION=2.0.1 - AM_PATH_SDL2($SDL_VERSION, - :, - AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!]) - ) - AM_OPTIONS_WXCONFIG - reqwx=3.0.0 - AM_PATH_WXCONFIG($reqwx, wxWin=1) - if test "$wxWin" != 1; then - AC_MSG_ERROR([ - wxWidgets must be installed on your system. +SDL_VERSION=2.0.1 +AM_PATH_SDL2($SDL_VERSION, + :, + AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!]) +) + +AM_OPTIONS_WXCONFIG +reqwx=3.0.0 +AM_PATH_WXCONFIG($reqwx, wxWin=1) +if test "$wxWin" != 1; then + AC_MSG_ERROR([ + wxWidgets must be installed on your system. - Please check that wx-config is in path, the directory - where wxWidgets libraries are installed (returned by - 'wx-config --libs' or 'wx-config --static --libs' command) - is in LD_LIBRARY_PATH or equivalent variable and - wxWidgets version is $reqwx or above. - ]) - fi - AC_CHECK_LIB([GL], [glGetError], [], \ - [echo "You need to install the OpenGL library." - exit -1]) - LIBS="$LIBS $WX_LIBS $SDL_LIBS" + Please check that wx-config is in path, the directory + where wxWidgets libraries are installed (returned by + 'wx-config --libs' or 'wx-config --static --libs' command) + is in LD_LIBRARY_PATH or equivalent variable and + wxWidgets version is $reqwx or above. + ]) fi +AC_CHECK_LIB([GL], [glGetError], [], \ + [echo "You need to install the OpenGL library." + exit -1]) +LIBS="$LIBS $WX_LIBS $SDL_LIBS" + AC_CHECK_LIB([openal], [alGetError], [], \ [echo "You need to install the OpenAL library." exit -1]) diff --git a/src/Makefile.am b/src/Makefile.am index ddd8cc9..59e544c 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -38,7 +38,6 @@ resid-fp/wave6581_P_T.cc resid-fp/wave6581__ST.cc resid-fp/wave8580_PS_.cc \ resid-fp/wave8580_PST.cc resid-fp/wave8580_P_T.cc resid-fp/wave8580__ST.cc \ resid-fp/wave.cc -if USE_WX pcem_CFLAGS = $(shell wx-config --cxxflags) $(shell sdl2-config --cflags) pcem_CXXFLAGS = $(shell wx-config --cxxflags) $(shell sdl2-config --cflags) pcem_LDADD = @LIBS@ @@ -53,15 +52,6 @@ pcem_SOURCES += midi_alsa.c else pcem_SOURCES += wx-sdl2-midi.c endif -else -pcem_CFLAGS = $(allegro_CFLAGS) -DPCEM_ALLEGRO -pcem_CXXFLAGS = -pcem_LDADD = $(allegro_LIBS) -lopenal -pcem_SOURCES += allegro-gui.c allegro-gui-config-sel.c allegro-gui-configure.c \ - allegro-gui-deviceconfig.c allegro-gui-hdconf.c allegro-joystick.c \ - allegro-keyboard.c allegro-main.c allegro-midi.c allegro-mouse.c allegro-video.c \ - thread-pthread.c -endif if CPU_I386 pcem_SOURCES += codegen_x86.c diff --git a/src/Makefile.in b/src/Makefile.in index 89d0d0a..3d6303b 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -92,31 +92,19 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ bin_PROGRAMS = pcem$(EXEEXT) -@USE_WX_TRUE@am__append_1 = wx-main.cc wx-config_sel.c wx-dialogbox.cc wx-utils.cc wx-app.cc \ -@USE_WX_TRUE@ wx-sdl2-joystick.c wx-sdl2-mouse.c wx-sdl2-keyboard.c wx-sdl2-video.c \ -@USE_WX_TRUE@ wx-sdl2.c wx-config.c wx-deviceconfig.cc wx-status.cc wx-sdl2-status.c \ -@USE_WX_TRUE@ wx-resources.cpp wx-thread.c wx-common.c wx-sdl2-display.c wx-sdl2-video-renderer.c wx-sdl2-video-gl3.c \ -@USE_WX_TRUE@ wx-glslp-parser.c wx-shader_man.c wx-shaderconfig.cc wx-joystickconfig.cc - -@USE_ALSA_TRUE@@USE_WX_TRUE@am__append_2 = -lasound -@USE_ALSA_TRUE@@USE_WX_TRUE@am__append_3 = midi_alsa.c -@USE_ALSA_FALSE@@USE_WX_TRUE@am__append_4 = wx-sdl2-midi.c -@USE_WX_FALSE@am__append_5 = allegro-gui.c allegro-gui-config-sel.c allegro-gui-configure.c \ -@USE_WX_FALSE@ allegro-gui-deviceconfig.c allegro-gui-hdconf.c allegro-joystick.c \ -@USE_WX_FALSE@ allegro-keyboard.c allegro-main.c allegro-midi.c allegro-mouse.c allegro-video.c \ -@USE_WX_FALSE@ thread-pthread.c - -@CPU_I386_TRUE@am__append_6 = codegen_x86.c -@CPU_I386_TRUE@am__append_7 = -msse2 -@CPU_X86_64_TRUE@am__append_8 = codegen_x86-64.c -@USE_NETWORKING_TRUE@am__append_9 = -DUSE_NETWORKING -@USE_NETWORKING_TRUE@am__append_10 = -DUSE_NETWORKING -@USE_NETWORKING_TRUE@am__append_11 = ne2000.c nethandler.c wx-hostconfig.c -@USE_NETWORKING_TRUE@am__append_12 = slirp/libslirp.a +@USE_ALSA_TRUE@am__append_1 = -lasound +@USE_ALSA_TRUE@am__append_2 = midi_alsa.c +@USE_ALSA_FALSE@am__append_3 = wx-sdl2-midi.c +@CPU_I386_TRUE@am__append_4 = codegen_x86.c +@CPU_I386_TRUE@am__append_5 = -msse2 +@CPU_X86_64_TRUE@am__append_6 = codegen_x86-64.c +@USE_NETWORKING_TRUE@am__append_7 = -DUSE_NETWORKING +@USE_NETWORKING_TRUE@am__append_8 = -DUSE_NETWORKING +@USE_NETWORKING_TRUE@am__append_9 = ne2000.c nethandler.c wx-hostconfig.c +@USE_NETWORKING_TRUE@am__append_10 = slirp/libslirp.a subdir = src ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/allegro.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) @@ -145,84 +133,46 @@ am__pcem_SOURCES_DIST = 386.c 386_dynarec.c 386_dynarec_ops.c 808x.c \ piix.c pit.c ppi.c ps1.c ps2.c ps2_mca.c ps2_nvr.c rom.c rtc.c \ scat.c scsi.c scsi_53c400.c scsi_aha1540.c scsi_cd.c scsi_hd.c \ serial.c sio.c sis496.c sound.c sound_ad1848.c sound_adlib.c \ - sound_adlibgold.c sound_cms.c sound_emu8k.c sound_gus.c \ - sound_mpu401_uart.c sound_opl.c sound_pas16.c sound_ps1.c \ - sound_pssj.c sound_sb.c sound_sb_dsp.c sound_sn76489.c \ - sound_speaker.c sound_ssi2001.c sound_wss.c sound_ym7128.c \ - soundopenal.c tandy_eeprom.c tandy_rom.c timer.c um8669f.c \ - um8881f.c vid_ati_eeprom.c vid_ati_mach64.c vid_ati18800.c \ - vid_ati28800.c vid_ati68860_ramdac.c vid_cga.c vid_cl5429.c \ - vid_colorplus.c vid_ega.c vid_et4000.c vid_et4000w32.c \ - vid_genius.c vid_hercules.c vid_icd2061.c vid_ics2595.c \ - vid_incolor.c vid_mda.c vid_olivetti_m24.c vid_oti067.c \ - vid_paradise.c vid_pc200.c vid_pc1512.c vid_pc1640.c \ - vid_pcjr.c vid_ps1_svga.c vid_s3.c vid_s3_virge.c \ - vid_sdac_ramdac.c vid_stg_ramdac.c vid_svga.c \ - vid_svga_render.c vid_tandy.c vid_tandysl.c vid_tgui9440.c \ - vid_tkd8001_ramdac.c vid_tvga.c vid_unk_ramdac.c vid_vga.c \ - vid_voodoo.c video.c wd76c10.c vid_wy700.c x86seg.c x87.c \ - xtide.c sound_dbopl.cc sound_resid.cc dosbox/cdrom_image.cpp \ - dosbox/dbopl.cpp dosbox/nukedopl.cpp dosbox/vid_cga_comp.c \ - resid-fp/convolve.cc resid-fp/convolve-sse.cc \ - resid-fp/envelope.cc resid-fp/extfilt.cc resid-fp/filter.cc \ - resid-fp/pot.cc resid-fp/sid.cc resid-fp/voice.cc \ - resid-fp/wave6581_PS_.cc resid-fp/wave6581_PST.cc \ - resid-fp/wave6581_P_T.cc resid-fp/wave6581__ST.cc \ - resid-fp/wave8580_PS_.cc resid-fp/wave8580_PST.cc \ - resid-fp/wave8580_P_T.cc resid-fp/wave8580__ST.cc \ - resid-fp/wave.cc wx-main.cc wx-config_sel.c wx-dialogbox.cc \ - wx-utils.cc wx-app.cc wx-sdl2-joystick.c wx-sdl2-mouse.c \ - wx-sdl2-keyboard.c wx-sdl2-video.c wx-sdl2.c wx-config.c \ - wx-deviceconfig.cc wx-status.cc wx-sdl2-status.c \ - wx-resources.cpp wx-thread.c wx-common.c wx-sdl2-display.c \ - wx-sdl2-video-renderer.c wx-sdl2-video-gl3.c wx-glslp-parser.c \ - wx-shader_man.c wx-shaderconfig.cc wx-joystickconfig.cc \ - midi_alsa.c wx-sdl2-midi.c allegro-gui.c \ - allegro-gui-config-sel.c allegro-gui-configure.c \ - allegro-gui-deviceconfig.c allegro-gui-hdconf.c \ - allegro-joystick.c allegro-keyboard.c allegro-main.c \ - allegro-midi.c allegro-mouse.c allegro-video.c \ - thread-pthread.c codegen_x86.c codegen_x86-64.c ne2000.c \ + sound_adlibgold.c sound_audiopci.c sound_cms.c sound_emu8k.c \ + sound_gus.c sound_mpu401_uart.c sound_opl.c sound_pas16.c \ + sound_ps1.c sound_pssj.c sound_sb.c sound_sb_dsp.c \ + sound_sn76489.c sound_speaker.c sound_ssi2001.c sound_wss.c \ + sound_ym7128.c soundopenal.c tandy_eeprom.c tandy_rom.c \ + t3100e.c timer.c um8669f.c um8881f.c vid_ati_eeprom.c \ + vid_ati_mach64.c vid_ati18800.c vid_ati28800.c \ + vid_ati68860_ramdac.c vid_cga.c vid_cl5429.c vid_colorplus.c \ + vid_ega.c vid_et4000.c vid_et4000w32.c vid_genius.c \ + vid_hercules.c vid_icd2061.c vid_ics2595.c vid_incolor.c \ + vid_mda.c vid_olivetti_m24.c vid_oti067.c vid_paradise.c \ + vid_pc200.c vid_pc1512.c vid_pc1640.c vid_pcjr.c \ + vid_ps1_svga.c vid_s3.c vid_s3_virge.c vid_sdac_ramdac.c \ + vid_stg_ramdac.c vid_svga.c vid_svga_render.c vid_t3100e.c \ + vid_tandy.c vid_tandysl.c vid_tgui9440.c vid_tkd8001_ramdac.c \ + vid_tvga.c vid_unk_ramdac.c vid_vga.c vid_voodoo.c video.c \ + wd76c10.c vid_wy700.c x86seg.c x87.c xtide.c sound_dbopl.cc \ + sound_resid.cc dosbox/cdrom_image.cpp dosbox/dbopl.cpp \ + dosbox/nukedopl.cpp dosbox/vid_cga_comp.c resid-fp/convolve.cc \ + resid-fp/convolve-sse.cc resid-fp/envelope.cc \ + resid-fp/extfilt.cc resid-fp/filter.cc resid-fp/pot.cc \ + resid-fp/sid.cc resid-fp/voice.cc resid-fp/wave6581_PS_.cc \ + resid-fp/wave6581_PST.cc resid-fp/wave6581_P_T.cc \ + resid-fp/wave6581__ST.cc resid-fp/wave8580_PS_.cc \ + resid-fp/wave8580_PST.cc resid-fp/wave8580_P_T.cc \ + resid-fp/wave8580__ST.cc resid-fp/wave.cc wx-main.cc \ + wx-config_sel.c wx-dialogbox.cc wx-utils.cc wx-app.cc \ + wx-sdl2-joystick.c wx-sdl2-mouse.c wx-sdl2-keyboard.c \ + wx-sdl2-video.c wx-sdl2.c wx-config.c wx-deviceconfig.cc \ + wx-status.cc wx-sdl2-status.c wx-resources.cpp wx-thread.c \ + wx-common.c wx-sdl2-display.c wx-sdl2-video-renderer.c \ + wx-sdl2-video-gl3.c wx-glslp-parser.c wx-shader_man.c \ + wx-shaderconfig.cc wx-joystickconfig.cc midi_alsa.c \ + wx-sdl2-midi.c codegen_x86.c codegen_x86-64.c ne2000.c \ nethandler.c wx-hostconfig.c -@USE_WX_TRUE@am__objects_1 = pcem-wx-main.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-config_sel.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-dialogbox.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-utils.$(OBJEXT) pcem-wx-app.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-joystick.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-mouse.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-keyboard.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-video.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2.$(OBJEXT) pcem-wx-config.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-deviceconfig.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-status.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-status.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-resources.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-thread.$(OBJEXT) pcem-wx-common.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-display.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-video-renderer.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-sdl2-video-gl3.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-glslp-parser.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-shader_man.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-shaderconfig.$(OBJEXT) \ -@USE_WX_TRUE@ pcem-wx-joystickconfig.$(OBJEXT) -@USE_ALSA_TRUE@@USE_WX_TRUE@am__objects_2 = pcem-midi_alsa.$(OBJEXT) -@USE_ALSA_FALSE@@USE_WX_TRUE@am__objects_3 = \ -@USE_ALSA_FALSE@@USE_WX_TRUE@ pcem-wx-sdl2-midi.$(OBJEXT) -@USE_WX_FALSE@am__objects_4 = pcem-allegro-gui.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-gui-config-sel.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-gui-configure.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-gui-deviceconfig.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-gui-hdconf.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-joystick.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-keyboard.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-main.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-midi.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-mouse.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-allegro-video.$(OBJEXT) \ -@USE_WX_FALSE@ pcem-thread-pthread.$(OBJEXT) -@CPU_I386_TRUE@am__objects_5 = pcem-codegen_x86.$(OBJEXT) -@CPU_X86_64_TRUE@am__objects_6 = pcem-codegen_x86-64.$(OBJEXT) -@USE_NETWORKING_TRUE@am__objects_7 = pcem-ne2000.$(OBJEXT) \ +@USE_ALSA_TRUE@am__objects_1 = pcem-midi_alsa.$(OBJEXT) +@USE_ALSA_FALSE@am__objects_2 = pcem-wx-sdl2-midi.$(OBJEXT) +@CPU_I386_TRUE@am__objects_3 = pcem-codegen_x86.$(OBJEXT) +@CPU_X86_64_TRUE@am__objects_4 = pcem-codegen_x86-64.$(OBJEXT) +@USE_NETWORKING_TRUE@am__objects_5 = pcem-ne2000.$(OBJEXT) \ @USE_NETWORKING_TRUE@ pcem-nethandler.$(OBJEXT) \ @USE_NETWORKING_TRUE@ pcem-wx-hostconfig.$(OBJEXT) am_pcem_OBJECTS = pcem-386.$(OBJEXT) pcem-386_dynarec.$(OBJEXT) \ @@ -273,16 +223,17 @@ am_pcem_OBJECTS = pcem-386.$(OBJEXT) pcem-386_dynarec.$(OBJEXT) \ pcem-scsi_hd.$(OBJEXT) pcem-serial.$(OBJEXT) \ pcem-sio.$(OBJEXT) pcem-sis496.$(OBJEXT) pcem-sound.$(OBJEXT) \ pcem-sound_ad1848.$(OBJEXT) pcem-sound_adlib.$(OBJEXT) \ - pcem-sound_adlibgold.$(OBJEXT) pcem-sound_cms.$(OBJEXT) \ - pcem-sound_emu8k.$(OBJEXT) pcem-sound_gus.$(OBJEXT) \ - pcem-sound_mpu401_uart.$(OBJEXT) pcem-sound_opl.$(OBJEXT) \ - pcem-sound_pas16.$(OBJEXT) pcem-sound_ps1.$(OBJEXT) \ - pcem-sound_pssj.$(OBJEXT) pcem-sound_sb.$(OBJEXT) \ - pcem-sound_sb_dsp.$(OBJEXT) pcem-sound_sn76489.$(OBJEXT) \ - pcem-sound_speaker.$(OBJEXT) pcem-sound_ssi2001.$(OBJEXT) \ - pcem-sound_wss.$(OBJEXT) pcem-sound_ym7128.$(OBJEXT) \ - pcem-soundopenal.$(OBJEXT) pcem-tandy_eeprom.$(OBJEXT) \ - pcem-tandy_rom.$(OBJEXT) pcem-timer.$(OBJEXT) \ + pcem-sound_adlibgold.$(OBJEXT) pcem-sound_audiopci.$(OBJEXT) \ + pcem-sound_cms.$(OBJEXT) pcem-sound_emu8k.$(OBJEXT) \ + pcem-sound_gus.$(OBJEXT) pcem-sound_mpu401_uart.$(OBJEXT) \ + pcem-sound_opl.$(OBJEXT) pcem-sound_pas16.$(OBJEXT) \ + pcem-sound_ps1.$(OBJEXT) pcem-sound_pssj.$(OBJEXT) \ + pcem-sound_sb.$(OBJEXT) pcem-sound_sb_dsp.$(OBJEXT) \ + pcem-sound_sn76489.$(OBJEXT) pcem-sound_speaker.$(OBJEXT) \ + pcem-sound_ssi2001.$(OBJEXT) pcem-sound_wss.$(OBJEXT) \ + pcem-sound_ym7128.$(OBJEXT) pcem-soundopenal.$(OBJEXT) \ + pcem-tandy_eeprom.$(OBJEXT) pcem-tandy_rom.$(OBJEXT) \ + pcem-t3100e.$(OBJEXT) pcem-timer.$(OBJEXT) \ pcem-um8669f.$(OBJEXT) pcem-um8881f.$(OBJEXT) \ pcem-vid_ati_eeprom.$(OBJEXT) pcem-vid_ati_mach64.$(OBJEXT) \ pcem-vid_ati18800.$(OBJEXT) pcem-vid_ati28800.$(OBJEXT) \ @@ -299,13 +250,14 @@ am_pcem_OBJECTS = pcem-386.$(OBJEXT) pcem-386_dynarec.$(OBJEXT) \ pcem-vid_ps1_svga.$(OBJEXT) pcem-vid_s3.$(OBJEXT) \ pcem-vid_s3_virge.$(OBJEXT) pcem-vid_sdac_ramdac.$(OBJEXT) \ pcem-vid_stg_ramdac.$(OBJEXT) pcem-vid_svga.$(OBJEXT) \ - pcem-vid_svga_render.$(OBJEXT) pcem-vid_tandy.$(OBJEXT) \ - pcem-vid_tandysl.$(OBJEXT) pcem-vid_tgui9440.$(OBJEXT) \ - pcem-vid_tkd8001_ramdac.$(OBJEXT) pcem-vid_tvga.$(OBJEXT) \ - pcem-vid_unk_ramdac.$(OBJEXT) pcem-vid_vga.$(OBJEXT) \ - pcem-vid_voodoo.$(OBJEXT) pcem-video.$(OBJEXT) \ - pcem-wd76c10.$(OBJEXT) pcem-vid_wy700.$(OBJEXT) \ - pcem-x86seg.$(OBJEXT) pcem-x87.$(OBJEXT) pcem-xtide.$(OBJEXT) \ + pcem-vid_svga_render.$(OBJEXT) pcem-vid_t3100e.$(OBJEXT) \ + pcem-vid_tandy.$(OBJEXT) pcem-vid_tandysl.$(OBJEXT) \ + pcem-vid_tgui9440.$(OBJEXT) pcem-vid_tkd8001_ramdac.$(OBJEXT) \ + pcem-vid_tvga.$(OBJEXT) pcem-vid_unk_ramdac.$(OBJEXT) \ + pcem-vid_vga.$(OBJEXT) pcem-vid_voodoo.$(OBJEXT) \ + pcem-video.$(OBJEXT) pcem-wd76c10.$(OBJEXT) \ + pcem-vid_wy700.$(OBJEXT) pcem-x86seg.$(OBJEXT) \ + pcem-x87.$(OBJEXT) pcem-xtide.$(OBJEXT) \ pcem-sound_dbopl.$(OBJEXT) pcem-sound_resid.$(OBJEXT) \ pcem-cdrom_image.$(OBJEXT) pcem-dbopl.$(OBJEXT) \ pcem-nukedopl.$(OBJEXT) pcem-vid_cga_comp.$(OBJEXT) \ @@ -317,15 +269,25 @@ am_pcem_OBJECTS = pcem-386.$(OBJEXT) pcem-386_dynarec.$(OBJEXT) \ pcem-wave6581__ST.$(OBJEXT) pcem-wave8580_PS_.$(OBJEXT) \ pcem-wave8580_PST.$(OBJEXT) pcem-wave8580_P_T.$(OBJEXT) \ pcem-wave8580__ST.$(OBJEXT) pcem-wave.$(OBJEXT) \ - $(am__objects_1) $(am__objects_2) $(am__objects_3) \ - $(am__objects_4) $(am__objects_5) $(am__objects_6) \ - $(am__objects_7) + pcem-wx-main.$(OBJEXT) pcem-wx-config_sel.$(OBJEXT) \ + pcem-wx-dialogbox.$(OBJEXT) pcem-wx-utils.$(OBJEXT) \ + pcem-wx-app.$(OBJEXT) pcem-wx-sdl2-joystick.$(OBJEXT) \ + pcem-wx-sdl2-mouse.$(OBJEXT) pcem-wx-sdl2-keyboard.$(OBJEXT) \ + pcem-wx-sdl2-video.$(OBJEXT) pcem-wx-sdl2.$(OBJEXT) \ + pcem-wx-config.$(OBJEXT) pcem-wx-deviceconfig.$(OBJEXT) \ + pcem-wx-status.$(OBJEXT) pcem-wx-sdl2-status.$(OBJEXT) \ + pcem-wx-resources.$(OBJEXT) pcem-wx-thread.$(OBJEXT) \ + pcem-wx-common.$(OBJEXT) pcem-wx-sdl2-display.$(OBJEXT) \ + pcem-wx-sdl2-video-renderer.$(OBJEXT) \ + pcem-wx-sdl2-video-gl3.$(OBJEXT) \ + pcem-wx-glslp-parser.$(OBJEXT) pcem-wx-shader_man.$(OBJEXT) \ + pcem-wx-shaderconfig.$(OBJEXT) \ + pcem-wx-joystickconfig.$(OBJEXT) $(am__objects_1) \ + $(am__objects_2) $(am__objects_3) $(am__objects_4) \ + $(am__objects_5) pcem_OBJECTS = $(am_pcem_OBJECTS) am__DEPENDENCIES_1 = -@USE_WX_FALSE@pcem_DEPENDENCIES = $(am__DEPENDENCIES_1) \ -@USE_WX_FALSE@ $(am__append_12) -@USE_WX_TRUE@pcem_DEPENDENCIES = $(am__DEPENDENCIES_1) \ -@USE_WX_TRUE@ $(am__append_12) +pcem_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__append_10) pcem_LINK = $(CXXLD) $(pcem_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) \ $(LDFLAGS) -o $@ SCRIPTS = $(noinst_SCRIPTS) @@ -403,7 +365,6 @@ CTAGS = ctags am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ -ALLEGRO_CONFIG = @ALLEGRO_CONFIG@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AUTOCONF = @AUTOCONF@ @@ -474,8 +435,6 @@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ -allegro_CFLAGS = @allegro_CFLAGS@ -allegro_LIBS = @allegro_LIBS@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -544,44 +503,46 @@ pcem_SOURCES = 386.c 386_dynarec.c 386_dynarec_ops.c 808x.c \ piix.c pit.c ppi.c ps1.c ps2.c ps2_mca.c ps2_nvr.c rom.c rtc.c \ scat.c scsi.c scsi_53c400.c scsi_aha1540.c scsi_cd.c scsi_hd.c \ serial.c sio.c sis496.c sound.c sound_ad1848.c sound_adlib.c \ - sound_adlibgold.c sound_cms.c sound_emu8k.c sound_gus.c \ - sound_mpu401_uart.c sound_opl.c sound_pas16.c sound_ps1.c \ - sound_pssj.c sound_sb.c sound_sb_dsp.c sound_sn76489.c \ - sound_speaker.c sound_ssi2001.c sound_wss.c sound_ym7128.c \ - soundopenal.c tandy_eeprom.c tandy_rom.c timer.c um8669f.c \ - um8881f.c vid_ati_eeprom.c vid_ati_mach64.c vid_ati18800.c \ - vid_ati28800.c vid_ati68860_ramdac.c vid_cga.c vid_cl5429.c \ - vid_colorplus.c vid_ega.c vid_et4000.c vid_et4000w32.c \ - vid_genius.c vid_hercules.c vid_icd2061.c vid_ics2595.c \ - vid_incolor.c vid_mda.c vid_olivetti_m24.c vid_oti067.c \ - vid_paradise.c vid_pc200.c vid_pc1512.c vid_pc1640.c \ - vid_pcjr.c vid_ps1_svga.c vid_s3.c vid_s3_virge.c \ - vid_sdac_ramdac.c vid_stg_ramdac.c vid_svga.c \ - vid_svga_render.c vid_tandy.c vid_tandysl.c vid_tgui9440.c \ - vid_tkd8001_ramdac.c vid_tvga.c vid_unk_ramdac.c vid_vga.c \ - vid_voodoo.c video.c wd76c10.c vid_wy700.c x86seg.c x87.c \ - xtide.c sound_dbopl.cc sound_resid.cc dosbox/cdrom_image.cpp \ - dosbox/dbopl.cpp dosbox/nukedopl.cpp dosbox/vid_cga_comp.c \ - resid-fp/convolve.cc resid-fp/convolve-sse.cc \ - resid-fp/envelope.cc resid-fp/extfilt.cc resid-fp/filter.cc \ - resid-fp/pot.cc resid-fp/sid.cc resid-fp/voice.cc \ - resid-fp/wave6581_PS_.cc resid-fp/wave6581_PST.cc \ - resid-fp/wave6581_P_T.cc resid-fp/wave6581__ST.cc \ - resid-fp/wave8580_PS_.cc resid-fp/wave8580_PST.cc \ - resid-fp/wave8580_P_T.cc resid-fp/wave8580__ST.cc \ - resid-fp/wave.cc $(am__append_1) $(am__append_3) \ - $(am__append_4) $(am__append_5) $(am__append_6) \ - $(am__append_8) $(am__append_11) -@USE_WX_FALSE@pcem_CFLAGS = $(allegro_CFLAGS) -DPCEM_ALLEGRO \ -@USE_WX_FALSE@ $(am__append_7) $(am__append_9) -@USE_WX_TRUE@pcem_CFLAGS = $(shell wx-config --cxxflags) $(shell \ -@USE_WX_TRUE@ sdl2-config --cflags) $(am__append_7) \ -@USE_WX_TRUE@ $(am__append_9) -@USE_WX_FALSE@pcem_CXXFLAGS = $(am__append_10) -@USE_WX_TRUE@pcem_CXXFLAGS = $(shell wx-config --cxxflags) $(shell \ -@USE_WX_TRUE@ sdl2-config --cflags) $(am__append_10) -@USE_WX_FALSE@pcem_LDADD = $(allegro_LIBS) -lopenal $(am__append_12) -@USE_WX_TRUE@pcem_LDADD = @LIBS@ $(am__append_2) $(am__append_12) + sound_adlibgold.c sound_audiopci.c sound_cms.c sound_emu8k.c \ + sound_gus.c sound_mpu401_uart.c sound_opl.c sound_pas16.c \ + sound_ps1.c sound_pssj.c sound_sb.c sound_sb_dsp.c \ + sound_sn76489.c sound_speaker.c sound_ssi2001.c sound_wss.c \ + sound_ym7128.c soundopenal.c tandy_eeprom.c tandy_rom.c \ + t3100e.c timer.c um8669f.c um8881f.c vid_ati_eeprom.c \ + vid_ati_mach64.c vid_ati18800.c vid_ati28800.c \ + vid_ati68860_ramdac.c vid_cga.c vid_cl5429.c vid_colorplus.c \ + vid_ega.c vid_et4000.c vid_et4000w32.c vid_genius.c \ + vid_hercules.c vid_icd2061.c vid_ics2595.c vid_incolor.c \ + vid_mda.c vid_olivetti_m24.c vid_oti067.c vid_paradise.c \ + vid_pc200.c vid_pc1512.c vid_pc1640.c vid_pcjr.c \ + vid_ps1_svga.c vid_s3.c vid_s3_virge.c vid_sdac_ramdac.c \ + vid_stg_ramdac.c vid_svga.c vid_svga_render.c vid_t3100e.c \ + vid_tandy.c vid_tandysl.c vid_tgui9440.c vid_tkd8001_ramdac.c \ + vid_tvga.c vid_unk_ramdac.c vid_vga.c vid_voodoo.c video.c \ + wd76c10.c vid_wy700.c x86seg.c x87.c xtide.c sound_dbopl.cc \ + sound_resid.cc dosbox/cdrom_image.cpp dosbox/dbopl.cpp \ + dosbox/nukedopl.cpp dosbox/vid_cga_comp.c resid-fp/convolve.cc \ + resid-fp/convolve-sse.cc resid-fp/envelope.cc \ + resid-fp/extfilt.cc resid-fp/filter.cc resid-fp/pot.cc \ + resid-fp/sid.cc resid-fp/voice.cc resid-fp/wave6581_PS_.cc \ + resid-fp/wave6581_PST.cc resid-fp/wave6581_P_T.cc \ + resid-fp/wave6581__ST.cc resid-fp/wave8580_PS_.cc \ + resid-fp/wave8580_PST.cc resid-fp/wave8580_P_T.cc \ + resid-fp/wave8580__ST.cc resid-fp/wave.cc wx-main.cc \ + wx-config_sel.c wx-dialogbox.cc wx-utils.cc wx-app.cc \ + wx-sdl2-joystick.c wx-sdl2-mouse.c wx-sdl2-keyboard.c \ + wx-sdl2-video.c wx-sdl2.c wx-config.c wx-deviceconfig.cc \ + wx-status.cc wx-sdl2-status.c wx-resources.cpp wx-thread.c \ + wx-common.c wx-sdl2-display.c wx-sdl2-video-renderer.c \ + wx-sdl2-video-gl3.c wx-glslp-parser.c wx-shader_man.c \ + wx-shaderconfig.cc wx-joystickconfig.cc $(am__append_2) \ + $(am__append_3) $(am__append_4) $(am__append_6) \ + $(am__append_9) +pcem_CFLAGS = $(shell wx-config --cxxflags) $(shell sdl2-config \ + --cflags) $(am__append_5) $(am__append_7) +pcem_CXXFLAGS = $(shell wx-config --cxxflags) $(shell sdl2-config \ + --cflags) $(am__append_8) +pcem_LDADD = @LIBS@ $(am__append_1) $(am__append_10) all: all-am .SUFFIXES: @@ -674,17 +635,6 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-808x.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-acer386sx.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-ali1429.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-gui-config-sel.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-gui-configure.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-gui-deviceconfig.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-gui-hdconf.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-gui.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-joystick.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-keyboard.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-main.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-midi.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-mouse.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-allegro-video.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-amstrad.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-cbm_io.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-cdrom-image.Po@am__quote@ @@ -795,6 +745,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_ad1848.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_adlib.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_adlibgold.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_audiopci.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_cms.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_dbopl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_emu8k.Po@am__quote@ @@ -813,9 +764,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_wss.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-sound_ym7128.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-soundopenal.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-t3100e.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-tandy_eeprom.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-tandy_rom.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-thread-pthread.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-timer.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-um8669f.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-um8881f.Po@am__quote@ @@ -851,6 +802,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-vid_stg_ramdac.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-vid_svga.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-vid_svga_render.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-vid_t3100e.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-vid_tandy.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-vid_tandysl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pcem-vid_tgui9440.Po@am__quote@ @@ -2316,6 +2268,20 @@ pcem-sound_adlibgold.obj: sound_adlibgold.c @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-sound_adlibgold.obj `if test -f 'sound_adlibgold.c'; then $(CYGPATH_W) 'sound_adlibgold.c'; else $(CYGPATH_W) '$(srcdir)/sound_adlibgold.c'; fi` +pcem-sound_audiopci.o: sound_audiopci.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-sound_audiopci.o -MD -MP -MF $(DEPDIR)/pcem-sound_audiopci.Tpo -c -o pcem-sound_audiopci.o `test -f 'sound_audiopci.c' || echo '$(srcdir)/'`sound_audiopci.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-sound_audiopci.Tpo $(DEPDIR)/pcem-sound_audiopci.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='sound_audiopci.c' object='pcem-sound_audiopci.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-sound_audiopci.o `test -f 'sound_audiopci.c' || echo '$(srcdir)/'`sound_audiopci.c + +pcem-sound_audiopci.obj: sound_audiopci.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-sound_audiopci.obj -MD -MP -MF $(DEPDIR)/pcem-sound_audiopci.Tpo -c -o pcem-sound_audiopci.obj `if test -f 'sound_audiopci.c'; then $(CYGPATH_W) 'sound_audiopci.c'; else $(CYGPATH_W) '$(srcdir)/sound_audiopci.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-sound_audiopci.Tpo $(DEPDIR)/pcem-sound_audiopci.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='sound_audiopci.c' object='pcem-sound_audiopci.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-sound_audiopci.obj `if test -f 'sound_audiopci.c'; then $(CYGPATH_W) 'sound_audiopci.c'; else $(CYGPATH_W) '$(srcdir)/sound_audiopci.c'; fi` + pcem-sound_cms.o: sound_cms.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-sound_cms.o -MD -MP -MF $(DEPDIR)/pcem-sound_cms.Tpo -c -o pcem-sound_cms.o `test -f 'sound_cms.c' || echo '$(srcdir)/'`sound_cms.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-sound_cms.Tpo $(DEPDIR)/pcem-sound_cms.Po @@ -2568,6 +2534,20 @@ pcem-tandy_rom.obj: tandy_rom.c @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-tandy_rom.obj `if test -f 'tandy_rom.c'; then $(CYGPATH_W) 'tandy_rom.c'; else $(CYGPATH_W) '$(srcdir)/tandy_rom.c'; fi` +pcem-t3100e.o: t3100e.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-t3100e.o -MD -MP -MF $(DEPDIR)/pcem-t3100e.Tpo -c -o pcem-t3100e.o `test -f 't3100e.c' || echo '$(srcdir)/'`t3100e.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-t3100e.Tpo $(DEPDIR)/pcem-t3100e.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t3100e.c' object='pcem-t3100e.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-t3100e.o `test -f 't3100e.c' || echo '$(srcdir)/'`t3100e.c + +pcem-t3100e.obj: t3100e.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-t3100e.obj -MD -MP -MF $(DEPDIR)/pcem-t3100e.Tpo -c -o pcem-t3100e.obj `if test -f 't3100e.c'; then $(CYGPATH_W) 't3100e.c'; else $(CYGPATH_W) '$(srcdir)/t3100e.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-t3100e.Tpo $(DEPDIR)/pcem-t3100e.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='t3100e.c' object='pcem-t3100e.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-t3100e.obj `if test -f 't3100e.c'; then $(CYGPATH_W) 't3100e.c'; else $(CYGPATH_W) '$(srcdir)/t3100e.c'; fi` + pcem-timer.o: timer.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-timer.o -MD -MP -MF $(DEPDIR)/pcem-timer.Tpo -c -o pcem-timer.o `test -f 'timer.c' || echo '$(srcdir)/'`timer.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-timer.Tpo $(DEPDIR)/pcem-timer.Po @@ -3044,6 +3024,20 @@ pcem-vid_svga_render.obj: vid_svga_render.c @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-vid_svga_render.obj `if test -f 'vid_svga_render.c'; then $(CYGPATH_W) 'vid_svga_render.c'; else $(CYGPATH_W) '$(srcdir)/vid_svga_render.c'; fi` +pcem-vid_t3100e.o: vid_t3100e.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-vid_t3100e.o -MD -MP -MF $(DEPDIR)/pcem-vid_t3100e.Tpo -c -o pcem-vid_t3100e.o `test -f 'vid_t3100e.c' || echo '$(srcdir)/'`vid_t3100e.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-vid_t3100e.Tpo $(DEPDIR)/pcem-vid_t3100e.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='vid_t3100e.c' object='pcem-vid_t3100e.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-vid_t3100e.o `test -f 'vid_t3100e.c' || echo '$(srcdir)/'`vid_t3100e.c + +pcem-vid_t3100e.obj: vid_t3100e.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-vid_t3100e.obj -MD -MP -MF $(DEPDIR)/pcem-vid_t3100e.Tpo -c -o pcem-vid_t3100e.obj `if test -f 'vid_t3100e.c'; then $(CYGPATH_W) 'vid_t3100e.c'; else $(CYGPATH_W) '$(srcdir)/vid_t3100e.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-vid_t3100e.Tpo $(DEPDIR)/pcem-vid_t3100e.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='vid_t3100e.c' object='pcem-vid_t3100e.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-vid_t3100e.obj `if test -f 'vid_t3100e.c'; then $(CYGPATH_W) 'vid_t3100e.c'; else $(CYGPATH_W) '$(srcdir)/vid_t3100e.c'; fi` + pcem-vid_tandy.o: vid_tandy.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-vid_tandy.o -MD -MP -MF $(DEPDIR)/pcem-vid_tandy.Tpo -c -o pcem-vid_tandy.o `test -f 'vid_tandy.c' || echo '$(srcdir)/'`vid_tandy.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-vid_tandy.Tpo $(DEPDIR)/pcem-vid_tandy.Po @@ -3492,174 +3486,6 @@ pcem-wx-sdl2-midi.obj: wx-sdl2-midi.c @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-wx-sdl2-midi.obj `if test -f 'wx-sdl2-midi.c'; then $(CYGPATH_W) 'wx-sdl2-midi.c'; else $(CYGPATH_W) '$(srcdir)/wx-sdl2-midi.c'; fi` -pcem-allegro-gui.o: allegro-gui.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui.o -MD -MP -MF $(DEPDIR)/pcem-allegro-gui.Tpo -c -o pcem-allegro-gui.o `test -f 'allegro-gui.c' || echo '$(srcdir)/'`allegro-gui.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui.Tpo $(DEPDIR)/pcem-allegro-gui.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui.c' object='pcem-allegro-gui.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui.o `test -f 'allegro-gui.c' || echo '$(srcdir)/'`allegro-gui.c - -pcem-allegro-gui.obj: allegro-gui.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-gui.Tpo -c -o pcem-allegro-gui.obj `if test -f 'allegro-gui.c'; then $(CYGPATH_W) 'allegro-gui.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui.Tpo $(DEPDIR)/pcem-allegro-gui.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui.c' object='pcem-allegro-gui.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui.obj `if test -f 'allegro-gui.c'; then $(CYGPATH_W) 'allegro-gui.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui.c'; fi` - -pcem-allegro-gui-config-sel.o: allegro-gui-config-sel.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-config-sel.o -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-config-sel.Tpo -c -o pcem-allegro-gui-config-sel.o `test -f 'allegro-gui-config-sel.c' || echo '$(srcdir)/'`allegro-gui-config-sel.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-config-sel.Tpo $(DEPDIR)/pcem-allegro-gui-config-sel.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-config-sel.c' object='pcem-allegro-gui-config-sel.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-config-sel.o `test -f 'allegro-gui-config-sel.c' || echo '$(srcdir)/'`allegro-gui-config-sel.c - -pcem-allegro-gui-config-sel.obj: allegro-gui-config-sel.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-config-sel.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-config-sel.Tpo -c -o pcem-allegro-gui-config-sel.obj `if test -f 'allegro-gui-config-sel.c'; then $(CYGPATH_W) 'allegro-gui-config-sel.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-config-sel.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-config-sel.Tpo $(DEPDIR)/pcem-allegro-gui-config-sel.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-config-sel.c' object='pcem-allegro-gui-config-sel.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-config-sel.obj `if test -f 'allegro-gui-config-sel.c'; then $(CYGPATH_W) 'allegro-gui-config-sel.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-config-sel.c'; fi` - -pcem-allegro-gui-configure.o: allegro-gui-configure.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-configure.o -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-configure.Tpo -c -o pcem-allegro-gui-configure.o `test -f 'allegro-gui-configure.c' || echo '$(srcdir)/'`allegro-gui-configure.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-configure.Tpo $(DEPDIR)/pcem-allegro-gui-configure.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-configure.c' object='pcem-allegro-gui-configure.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-configure.o `test -f 'allegro-gui-configure.c' || echo '$(srcdir)/'`allegro-gui-configure.c - -pcem-allegro-gui-configure.obj: allegro-gui-configure.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-configure.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-configure.Tpo -c -o pcem-allegro-gui-configure.obj `if test -f 'allegro-gui-configure.c'; then $(CYGPATH_W) 'allegro-gui-configure.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-configure.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-configure.Tpo $(DEPDIR)/pcem-allegro-gui-configure.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-configure.c' object='pcem-allegro-gui-configure.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-configure.obj `if test -f 'allegro-gui-configure.c'; then $(CYGPATH_W) 'allegro-gui-configure.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-configure.c'; fi` - -pcem-allegro-gui-deviceconfig.o: allegro-gui-deviceconfig.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-deviceconfig.o -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-deviceconfig.Tpo -c -o pcem-allegro-gui-deviceconfig.o `test -f 'allegro-gui-deviceconfig.c' || echo '$(srcdir)/'`allegro-gui-deviceconfig.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-deviceconfig.Tpo $(DEPDIR)/pcem-allegro-gui-deviceconfig.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-deviceconfig.c' object='pcem-allegro-gui-deviceconfig.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-deviceconfig.o `test -f 'allegro-gui-deviceconfig.c' || echo '$(srcdir)/'`allegro-gui-deviceconfig.c - -pcem-allegro-gui-deviceconfig.obj: allegro-gui-deviceconfig.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-deviceconfig.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-deviceconfig.Tpo -c -o pcem-allegro-gui-deviceconfig.obj `if test -f 'allegro-gui-deviceconfig.c'; then $(CYGPATH_W) 'allegro-gui-deviceconfig.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-deviceconfig.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-deviceconfig.Tpo $(DEPDIR)/pcem-allegro-gui-deviceconfig.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-deviceconfig.c' object='pcem-allegro-gui-deviceconfig.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-deviceconfig.obj `if test -f 'allegro-gui-deviceconfig.c'; then $(CYGPATH_W) 'allegro-gui-deviceconfig.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-deviceconfig.c'; fi` - -pcem-allegro-gui-hdconf.o: allegro-gui-hdconf.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-hdconf.o -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-hdconf.Tpo -c -o pcem-allegro-gui-hdconf.o `test -f 'allegro-gui-hdconf.c' || echo '$(srcdir)/'`allegro-gui-hdconf.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-hdconf.Tpo $(DEPDIR)/pcem-allegro-gui-hdconf.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-hdconf.c' object='pcem-allegro-gui-hdconf.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-hdconf.o `test -f 'allegro-gui-hdconf.c' || echo '$(srcdir)/'`allegro-gui-hdconf.c - -pcem-allegro-gui-hdconf.obj: allegro-gui-hdconf.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-gui-hdconf.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-gui-hdconf.Tpo -c -o pcem-allegro-gui-hdconf.obj `if test -f 'allegro-gui-hdconf.c'; then $(CYGPATH_W) 'allegro-gui-hdconf.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-hdconf.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-gui-hdconf.Tpo $(DEPDIR)/pcem-allegro-gui-hdconf.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-gui-hdconf.c' object='pcem-allegro-gui-hdconf.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-gui-hdconf.obj `if test -f 'allegro-gui-hdconf.c'; then $(CYGPATH_W) 'allegro-gui-hdconf.c'; else $(CYGPATH_W) '$(srcdir)/allegro-gui-hdconf.c'; fi` - -pcem-allegro-joystick.o: allegro-joystick.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-joystick.o -MD -MP -MF $(DEPDIR)/pcem-allegro-joystick.Tpo -c -o pcem-allegro-joystick.o `test -f 'allegro-joystick.c' || echo '$(srcdir)/'`allegro-joystick.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-joystick.Tpo $(DEPDIR)/pcem-allegro-joystick.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-joystick.c' object='pcem-allegro-joystick.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-joystick.o `test -f 'allegro-joystick.c' || echo '$(srcdir)/'`allegro-joystick.c - -pcem-allegro-joystick.obj: allegro-joystick.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-joystick.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-joystick.Tpo -c -o pcem-allegro-joystick.obj `if test -f 'allegro-joystick.c'; then $(CYGPATH_W) 'allegro-joystick.c'; else $(CYGPATH_W) '$(srcdir)/allegro-joystick.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-joystick.Tpo $(DEPDIR)/pcem-allegro-joystick.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-joystick.c' object='pcem-allegro-joystick.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-joystick.obj `if test -f 'allegro-joystick.c'; then $(CYGPATH_W) 'allegro-joystick.c'; else $(CYGPATH_W) '$(srcdir)/allegro-joystick.c'; fi` - -pcem-allegro-keyboard.o: allegro-keyboard.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-keyboard.o -MD -MP -MF $(DEPDIR)/pcem-allegro-keyboard.Tpo -c -o pcem-allegro-keyboard.o `test -f 'allegro-keyboard.c' || echo '$(srcdir)/'`allegro-keyboard.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-keyboard.Tpo $(DEPDIR)/pcem-allegro-keyboard.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-keyboard.c' object='pcem-allegro-keyboard.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-keyboard.o `test -f 'allegro-keyboard.c' || echo '$(srcdir)/'`allegro-keyboard.c - -pcem-allegro-keyboard.obj: allegro-keyboard.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-keyboard.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-keyboard.Tpo -c -o pcem-allegro-keyboard.obj `if test -f 'allegro-keyboard.c'; then $(CYGPATH_W) 'allegro-keyboard.c'; else $(CYGPATH_W) '$(srcdir)/allegro-keyboard.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-keyboard.Tpo $(DEPDIR)/pcem-allegro-keyboard.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-keyboard.c' object='pcem-allegro-keyboard.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-keyboard.obj `if test -f 'allegro-keyboard.c'; then $(CYGPATH_W) 'allegro-keyboard.c'; else $(CYGPATH_W) '$(srcdir)/allegro-keyboard.c'; fi` - -pcem-allegro-main.o: allegro-main.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-main.o -MD -MP -MF $(DEPDIR)/pcem-allegro-main.Tpo -c -o pcem-allegro-main.o `test -f 'allegro-main.c' || echo '$(srcdir)/'`allegro-main.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-main.Tpo $(DEPDIR)/pcem-allegro-main.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-main.c' object='pcem-allegro-main.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-main.o `test -f 'allegro-main.c' || echo '$(srcdir)/'`allegro-main.c - -pcem-allegro-main.obj: allegro-main.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-main.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-main.Tpo -c -o pcem-allegro-main.obj `if test -f 'allegro-main.c'; then $(CYGPATH_W) 'allegro-main.c'; else $(CYGPATH_W) '$(srcdir)/allegro-main.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-main.Tpo $(DEPDIR)/pcem-allegro-main.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-main.c' object='pcem-allegro-main.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-main.obj `if test -f 'allegro-main.c'; then $(CYGPATH_W) 'allegro-main.c'; else $(CYGPATH_W) '$(srcdir)/allegro-main.c'; fi` - -pcem-allegro-midi.o: allegro-midi.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-midi.o -MD -MP -MF $(DEPDIR)/pcem-allegro-midi.Tpo -c -o pcem-allegro-midi.o `test -f 'allegro-midi.c' || echo '$(srcdir)/'`allegro-midi.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-midi.Tpo $(DEPDIR)/pcem-allegro-midi.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-midi.c' object='pcem-allegro-midi.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-midi.o `test -f 'allegro-midi.c' || echo '$(srcdir)/'`allegro-midi.c - -pcem-allegro-midi.obj: allegro-midi.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-midi.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-midi.Tpo -c -o pcem-allegro-midi.obj `if test -f 'allegro-midi.c'; then $(CYGPATH_W) 'allegro-midi.c'; else $(CYGPATH_W) '$(srcdir)/allegro-midi.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-midi.Tpo $(DEPDIR)/pcem-allegro-midi.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-midi.c' object='pcem-allegro-midi.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-midi.obj `if test -f 'allegro-midi.c'; then $(CYGPATH_W) 'allegro-midi.c'; else $(CYGPATH_W) '$(srcdir)/allegro-midi.c'; fi` - -pcem-allegro-mouse.o: allegro-mouse.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-mouse.o -MD -MP -MF $(DEPDIR)/pcem-allegro-mouse.Tpo -c -o pcem-allegro-mouse.o `test -f 'allegro-mouse.c' || echo '$(srcdir)/'`allegro-mouse.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-mouse.Tpo $(DEPDIR)/pcem-allegro-mouse.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-mouse.c' object='pcem-allegro-mouse.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-mouse.o `test -f 'allegro-mouse.c' || echo '$(srcdir)/'`allegro-mouse.c - -pcem-allegro-mouse.obj: allegro-mouse.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-mouse.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-mouse.Tpo -c -o pcem-allegro-mouse.obj `if test -f 'allegro-mouse.c'; then $(CYGPATH_W) 'allegro-mouse.c'; else $(CYGPATH_W) '$(srcdir)/allegro-mouse.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-mouse.Tpo $(DEPDIR)/pcem-allegro-mouse.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-mouse.c' object='pcem-allegro-mouse.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-mouse.obj `if test -f 'allegro-mouse.c'; then $(CYGPATH_W) 'allegro-mouse.c'; else $(CYGPATH_W) '$(srcdir)/allegro-mouse.c'; fi` - -pcem-allegro-video.o: allegro-video.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-video.o -MD -MP -MF $(DEPDIR)/pcem-allegro-video.Tpo -c -o pcem-allegro-video.o `test -f 'allegro-video.c' || echo '$(srcdir)/'`allegro-video.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-video.Tpo $(DEPDIR)/pcem-allegro-video.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-video.c' object='pcem-allegro-video.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-video.o `test -f 'allegro-video.c' || echo '$(srcdir)/'`allegro-video.c - -pcem-allegro-video.obj: allegro-video.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-allegro-video.obj -MD -MP -MF $(DEPDIR)/pcem-allegro-video.Tpo -c -o pcem-allegro-video.obj `if test -f 'allegro-video.c'; then $(CYGPATH_W) 'allegro-video.c'; else $(CYGPATH_W) '$(srcdir)/allegro-video.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-allegro-video.Tpo $(DEPDIR)/pcem-allegro-video.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='allegro-video.c' object='pcem-allegro-video.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-allegro-video.obj `if test -f 'allegro-video.c'; then $(CYGPATH_W) 'allegro-video.c'; else $(CYGPATH_W) '$(srcdir)/allegro-video.c'; fi` - -pcem-thread-pthread.o: thread-pthread.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-thread-pthread.o -MD -MP -MF $(DEPDIR)/pcem-thread-pthread.Tpo -c -o pcem-thread-pthread.o `test -f 'thread-pthread.c' || echo '$(srcdir)/'`thread-pthread.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-thread-pthread.Tpo $(DEPDIR)/pcem-thread-pthread.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='thread-pthread.c' object='pcem-thread-pthread.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-thread-pthread.o `test -f 'thread-pthread.c' || echo '$(srcdir)/'`thread-pthread.c - -pcem-thread-pthread.obj: thread-pthread.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-thread-pthread.obj -MD -MP -MF $(DEPDIR)/pcem-thread-pthread.Tpo -c -o pcem-thread-pthread.obj `if test -f 'thread-pthread.c'; then $(CYGPATH_W) 'thread-pthread.c'; else $(CYGPATH_W) '$(srcdir)/thread-pthread.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-thread-pthread.Tpo $(DEPDIR)/pcem-thread-pthread.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='thread-pthread.c' object='pcem-thread-pthread.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -c -o pcem-thread-pthread.obj `if test -f 'thread-pthread.c'; then $(CYGPATH_W) 'thread-pthread.c'; else $(CYGPATH_W) '$(srcdir)/thread-pthread.c'; fi` - pcem-codegen_x86.o: codegen_x86.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pcem_CFLAGS) $(CFLAGS) -MT pcem-codegen_x86.o -MD -MP -MF $(DEPDIR)/pcem-codegen_x86.Tpo -c -o pcem-codegen_x86.o `test -f 'codegen_x86.c' || echo '$(srcdir)/'`codegen_x86.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pcem-codegen_x86.Tpo $(DEPDIR)/pcem-codegen_x86.Po diff --git a/src/Makefile.linux32 b/src/Makefile.linux32 deleted file mode 100644 index 8b31bae..0000000 --- a/src/Makefile.linux32 +++ /dev/null @@ -1,47 +0,0 @@ -VPATH = . dosbox resid-fp -CPP = g++ -CC = gcc -CFLAGS = -DPCEM_ALLEGRO -O3 -fomit-frame-pointer -msse2 -m32 -LDFLAGS = -m32 -OBJ = 386.o 386_dynarec.o 386_dynarec_ops.o 808x.o acer386sx.o ali1429.o allegro-gui.o \ -allegro-gui-configure.o allegro-gui-config-sel.o allegro-gui-deviceconfig.o allegro-gui-hdconf.o allegro-joystick.o allegro-keyboard.o allegro-main.o \ -allegro-midi.o allegro-mouse.o allegro-video.o amstrad.o cbm_io.o cdrom-ioctl-linux.o cdrom-image.o cdrom-null.o \ -codegen.o codegen_ops.o codegen_timing_486.o codegen_timing_686.o codegen_timing_common.o codegen_timing_pentium.o codegen_timing_winchip.o codegen_x86.c compaq.o config.o cpu.o \ -dells200.o device.o disc.o disc_fdi.o disc_img.o disc_sector.o dma.o esdi_at.o fdc.o fdc37c665.o fdd.o fdi2raw.o gameport.o \ -hdd.o hdd_esdi.o hdd_file.o headland.o i430lx.o i430fx.o i430vx.o ide.o intel.o intel_flash.o io.o jim.o joystick_ch_flightstick_pro.o joystick_standard.o joystick_sw_pad.o \ -joystick_tm_fcs.o keyboard.o keyboard_amstrad.o keyboard_at.o keyboard_olim24.o keyboard_pcjr.o keyboard_xt.o \ -laserxt.o lpt.o lpt_dac.o lpt_dss.o mca.o mcr.o mem.o mfm_at.o mfm_xebec.o model.o mouse.o mouse_msystems.o mouse_ps2.o mouse_serial.o neat.o nmi.o nvr.o olivetti_m24.o \ -opti495.o paths.o pc.o pci.o pic.o piix.o pit.o ppi.o ps1.o ps2.o ps2_mca.o ps2_nvr.o rom.o rtc.o scat.o scsi.o scsi_53c400.o scsi_aha1540.o scsi_cd.o scsi_hd.o \ -serial.o sio.o sis496.o sound.o sound_ad1848.o sound_adlib.o sound_adlibgold.o sound_audiopci.o sound_cms.o sound_emu8k.o sound_gus.o \ -sound_mpu401_uart.o sound_opl.o sound_pas16.o sound_ps1.o sound_pssj.o sound_sb.o sound_sb_dsp.o sound_sn76489.o \ -sound_speaker.o sound_ssi2001.o sound_wss.o sound_ym7128.o soundopenal.o t3100e.o tandy_eeprom.o tandy_rom.o thread-pthread.o \ -timer.o um8669f.o um8881f.o vid_ati_eeprom.o vid_ati_mach64.o vid_ati18800.o vid_ati28800.o \ -vid_ati68860_ramdac.o vid_cga.o vid_cl5429.o vid_colorplus.o vid_ega.o vid_et4000.o vid_et4000w32.o vid_genius.o vid_hercules.o \ -vid_icd2061.o vid_ics2595.o vid_incolor.o vid_mda.o vid_olivetti_m24.o vid_oti067.o vid_paradise.o vid_pc200.o \ -vid_pc1512.o vid_pc1640.o vid_pcjr.o vid_ps1_svga.o vid_s3.o vid_s3_virge.o vid_sdac_ramdac.o \ -vid_stg_ramdac.o vid_svga.o vid_svga_render.o vid_t3100e.o vid_tandy.o vid_tandysl.o vid_tgui9440.o \ -vid_tkd8001_ramdac.o vid_tvga.o vid_unk_ramdac.o vid_vga.o vid_wy700.o vid_voodoo.o video.o wd76c10.o \ -x86seg.o x87.o xtide.o sound_dbopl.o sound_resid.o -DBOBJ = cdrom_image.o dbopl.o nukedopl.o vid_cga_comp.o -SIDOBJ = convolve.o convolve-sse.o envelope.o extfilt.o filter.o pot.o sid.o voice.o wave6581__ST.o wave6581_P_T.o wave6581_PS_.o wave6581_PST.o wave8580__ST.o wave8580_P_T.o wave8580_PS_.o wave8580_PST.o wave.o - - -LIBS = -lopenal -lstdc++ -lalleg -lpthread -lm - -PCem: $(OBJ) $(DBOBJ) $(SIDOBJ) - $(CC) $(LDFLAGS) $(OBJ) $(DBOBJ) $(SIDOBJ) -o "PCem" $(LIBS) - -all : PCem - -clean : - rm *.o - rm PCem - -%.o : %.c - $(CC) $(CFLAGS) -c $< - -%.o : %.cc - $(CPP) $(CFLAGS) -c $< - -%.o : %.cpp - $(CPP) $(CFLAGS) -c $< diff --git a/src/Makefile.linux64 b/src/Makefile.linux64 deleted file mode 100644 index 030f711..0000000 --- a/src/Makefile.linux64 +++ /dev/null @@ -1,46 +0,0 @@ -VPATH = . dosbox resid-fp -CPP = g++ -CC = gcc -CFLAGS = -DPCEM_ALLEGRO -O3 -fomit-frame-pointer -msse2 -m64 -OBJ = 386.o 386_dynarec.o 386_dynarec_ops.o 808x.o acer386sx.o ali1429.o allegro-gui.o \ -allegro-gui-configure.o allegro-gui-config-sel.o allegro-gui-deviceconfig.o allegro-gui-hdconf.o allegro-joystick.o allegro-keyboard.o allegro-main.o \ -allegro-midi.o allegro-mouse.o allegro-video.o amstrad.o cbm_io.o cdrom-ioctl-linux.o cdrom-image.o cdrom-null.o \ -codegen.o codegen_ops.o codegen_timing_486.o codegen_timing_686.o codegen_timing_common.o codegen_timing_pentium.o codegen_timing_winchip.o codegen_x86-64.c compaq.o config.o cpu.o \ -dells200.o device.o disc.o disc_fdi.o disc_img.o disc_sector.o dma.o esdi_at.o fdc.o fdc37c665.o fdd.o fdi2raw.o gameport.o \ -hdd.o hdd_esdi.o hdd_file.o headland.o i430lx.o i430fx.o i430vx.o ide.o intel.o intel_flash.o io.o jim.o joystick_ch_flightstick_pro.o joystick_standard.o joystick_sw_pad.o \ -joystick_tm_fcs.o keyboard.o keyboard_amstrad.o keyboard_at.o keyboard_olim24.o keyboard_pcjr.o keyboard_xt.o \ -laserxt.o lpt.o lpt_dac.o lpt_dss.o mca.o mcr.o mem.o mfm_at.o mfm_xebec.o model.o mouse.o mouse_msystems.o mouse_ps2.o mouse_serial.o neat.o nmi.o nvr.o olivetti_m24.o \ -opti495.o paths.o pc.o pci.o pic.o piix.o pit.o ppi.o ps1.o ps2.o ps2_mca.o ps2_nvr.o rom.o rtc.o scat.o scsi.o scsi_53c400.o scsi_aha1540.o scsi_cd.o scsi_hd.o \ -serial.o sio.o sis496.o sound.o sound_ad1848.o sound_adlib.o sound_adlibgold.o sound_audiopci.o sound_cms.o sound_emu8k.o sound_gus.o \ -sound_mpu401_uart.o sound_opl.o sound_pas16.o sound_ps1.o sound_pssj.o sound_sb.o sound_sb_dsp.o sound_sn76489.o \ -sound_speaker.o sound_ssi2001.o sound_wss.o sound_ym7128.o soundopenal.o t3100e.o tandy_eeprom.o tandy_rom.o thread-pthread.o \ -timer.o um8669f.o um8881f.o vid_ati_eeprom.o vid_ati_mach64.o vid_ati18800.o vid_ati28800.o \ -vid_ati68860_ramdac.o vid_cga.o vid_cl5429.o vid_colorplus.o vid_ega.o vid_et4000.o vid_et4000w32.o vid_genius.o vid_hercules.o \ -vid_icd2061.o vid_ics2595.o vid_incolor.o vid_mda.o vid_olivetti_m24.o vid_oti067.o vid_paradise.o vid_pc200.o \ -vid_pc1512.o vid_pc1640.o vid_pcjr.o vid_ps1_svga.o vid_s3.o vid_s3_virge.o vid_sdac_ramdac.o \ -vid_stg_ramdac.o vid_svga.o vid_svga_render.o vid_t3100e.o vid_tandy.o vid_tandysl.o vid_tgui9440.o \ -vid_tkd8001_ramdac.o vid_tvga.o vid_unk_ramdac.o vid_vga.o vid_voodoo.o vid_wy700.o video.o wd76c10.o \ -x86seg.o x87.o xtide.o sound_dbopl.o sound_resid.o -DBOBJ = cdrom_image.o dbopl.o nukedopl.o vid_cga_comp.o -SIDOBJ = convolve.o convolve-sse.o envelope.o extfilt.o filter.o pot.o sid.o voice.o wave6581__ST.o wave6581_P_T.o wave6581_PS_.o wave6581_PST.o wave8580__ST.o wave8580_P_T.o wave8580_PS_.o wave8580_PST.o wave.o - - -LIBS = -lopenal -lstdc++ -lalleg -lpthread -lm - -PCem64: $(OBJ) $(DBOBJ) $(SIDOBJ) - $(CC) $(OBJ) $(DBOBJ) $(SIDOBJ) -o "PCem64" $(LIBS) - -all : PCem64 - -clean : - rm *.o - rm PCem64 - -%.o : %.c - $(CC) $(CFLAGS) -c $< - -%.o : %.cc - $(CPP) $(CFLAGS) -c $< - -%.o : %.cpp - $(CPP) $(CFLAGS) -c $< diff --git a/src/allegro-gui-config-sel.c b/src/allegro-gui-config-sel.c deleted file mode 100644 index 708889b..0000000 --- a/src/allegro-gui-config-sel.c +++ /dev/null @@ -1,266 +0,0 @@ -#include "ibm.h" -#include "device.h" -#include "allegro-main.h" -#include "allegro-gui.h" -#include "config.h" -#include "paths.h" -#undef printf -typedef struct config_t -{ - char name[512]; - struct config_t *next; -} config_t; - -static config_t *config_head; - -static char *get_config(int nr); -static int get_config_nr(); -static void free_configs(); -static void populate_configs(); - -static char *list_proc_joystick(int index, int *list_size) -{ - int c = 0; - config_t *config = config_head; - - if (index < 0) - { - while (config) - { - c++; - config = config->next; - } - - *list_size = c; - return NULL; - } - - for (; c < index; c++) - { - if (!config) - return NULL; - config = config->next; - } - - if (!config) - return NULL; - - return config->name; -// return joystick_list[index].name; -} - -static char config_name[256]; - -static DIALOG new_config_dialog[] = -{ - {d_shadow_box_proc, 0, 0, 480,80,0,0xffffff,0,0, 0,0,0,0,0}, // 0 - - {d_button_proc, 240-148, 56, 144, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "OK", 0, 0}, // 1 - {d_button_proc, 240+4, 56, 144, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Cancel", 0, 0}, // 2 - - {d_edit_proc, 8, 32, 464, 16, 0, 0xffffff, 0, 0, 255, 0, config_name, 0, 0}, // 3 - - {d_text_proc, 240-29*4, 16, 29*8, 16, 0, 0xffffff, 0, 0, 255, 0, "Please type new config name :", 0, 0}, - - {0,0,0,0,0,0,0,0,0,0,0,NULL,NULL,NULL} -}; - -static int new_proc(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_CLOSE) - { - int c; - - config_name[0] = 0; - new_config_dialog[3].d2 = 0; - - position_dialog(new_config_dialog, SCREEN_W/2 - new_config_dialog[0].w/2, SCREEN_H/2 - new_config_dialog[0].h/2); - - c = popup_dialog(new_config_dialog, 1); - - position_dialog(new_config_dialog, -(SCREEN_W/2 - new_config_dialog[0].w/2), -(SCREEN_H/2 - new_config_dialog[0].h/2)); - - if (c == 1) - { - sprintf(config_file_default, "%s%s.cfg", configs_path, config_name); - c = settings_configure(); - free_configs(); - populate_configs(); - return c; - } - - return D_O_K; - } - - return ret; -} - -static int config_proc(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_CLOSE) - { - char *name = get_config(get_config_nr()); - - if (name) - { - sprintf(config_file_default, "%s%s.cfg", configs_path, name); - loadconfig(NULL); - return settings_configure(); - } - - return D_O_K; - } - - return ret; -} - -static int hdd_proc(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_CLOSE) - { - char *name = get_config(get_config_nr()); - - if (name) - { - sprintf(config_file_default, "%s%s.cfg", configs_path, name); - loadconfig(NULL); - return disc_hdconf(); - } - - return D_O_K; - } - - return ret; -} - -static DIALOG config_sel_dialog[] = -{ - {d_shadow_box_proc, 0, 0, 568,372,0,0xffffff,0,0, 0,0,0,0,0}, // 0 - - {d_button_proc, 416, 8, 144, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Load", 0, 0}, // 1 - {d_button_proc, 416, 348, 144, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Quit", 0, 0}, // 2 - - {new_proc, 416, 56, 144, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "New...", 0, 0}, // 3 - {config_proc, 416, 80, 144, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Configure...", 0, 0}, // 4 - {hdd_proc, 416, 104, 144, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "HDD...", 0, 0}, // 5 - - {d_list_proc, 8, 8, 400, 356, 0, 0xffffff, 0, 0, 0, 0, list_proc_joystick, 0, 0}, // 6 - - {0,0,0,0,0,0,0,0,0,0,0,NULL,NULL,NULL} -}; - -static int get_config_nr() -{ - return config_sel_dialog[6].d1; -} - -static void populate_configs() -{ - struct al_ffblk info; - char cfg[512]; - config_t *config = NULL; - - strcpy(cfg, configs_path); - strcat(cfg, "*.cfg"); - printf("cfg %s\n", cfg); - if (al_findfirst(cfg, &info, FA_ALL)) - return; - - do - { - config_t *old_config = config; - char *ext; - - config = malloc(sizeof(config_t)); - if (old_config) - old_config->next = config; - else - config_head = config; - config->next = 0; - strcpy(config->name, info.name); - - ext = get_extension(config->name); - if (ext && ext[0]) - { - ext--; - *ext = 0; - } - - printf("Found %s\n", info.name); - } while (al_findnext(&info) == 0); - - al_findclose(&info); -} - -static char *get_config(int nr) -{ - config_t *config = config_head; - int c; - - for (c = 0; c < nr; c++) - { - if (!config) - return NULL; - config = config->next; - } - if (!config) - return NULL; - - return config->name; -} - -static void free_configs() -{ - config_t *config = config_head; - - while (config) - { - config_t *old_config = config; - - config = config->next; - free(old_config); - } -} - -int config_sel() -{ - populate_configs(); - set_gfx_mode(GFX_AUTODETECT_WINDOWED, 640, 480, 0, 0); - while (1) - { - int c; - - position_dialog(config_sel_dialog, SCREEN_W/2 - config_sel_dialog[0].w/2, SCREEN_H/2 - config_sel_dialog[0].h/2); - - c = popup_dialog(config_sel_dialog, 1); - - position_dialog(config_sel_dialog, -(SCREEN_W/2 - config_sel_dialog[0].w/2), -(SCREEN_H/2 - config_sel_dialog[0].h/2)); - - if (c == 1) - { - char *name = get_config(config_sel_dialog[6].d1); - - if (name) - { - sprintf(config_file_default, "%s%s.cfg", configs_path, name); - pclog("config_file_default=%s\n", config_file_default); - free_configs(); - return 0; - } - } - - if (c == 2) - return 1; - } - - free_configs(); - - return 1; -} - diff --git a/src/allegro-gui-configure.c b/src/allegro-gui-configure.c deleted file mode 100644 index 349ed91..0000000 --- a/src/allegro-gui-configure.c +++ /dev/null @@ -1,837 +0,0 @@ -#include "ibm.h" -#include "device.h" -#include "allegro-main.h" -#include "allegro-gui.h" -#include "cpu.h" -#include "fdd.h" -#include "gameport.h" -#include "hdd.h" -#include "mem.h" -#include "model.h" -#include "mouse.h" -#include "sound.h" -#include "video.h" -#include "vid_voodoo.h" - -static int romstolist[ROM_MAX]; -static int settings_mouse_to_list[20], settings_list_to_mouse[20]; - -typedef struct allegro_list_t -{ - char name[256]; - int num; -} allegro_list_t; - -typedef struct allegro_list_str_t -{ - char name[256]; - char *internal_name; -} allegro_list_str_t; - -static allegro_list_t model_list[ROM_MAX+1]; -static allegro_list_t video_list[GFX_MAX+1]; -static allegro_list_t sound_list[GFX_MAX+1]; -static allegro_list_t cpumanu_list[4]; -static allegro_list_t cpu_list[32]; -static allegro_list_t joystick_list[32]; -static allegro_list_t mouse_list[32]; -static allegro_list_str_t hdd_list[32]; - -static char mem_size_str[10], mem_size_units[3]; - -static allegro_list_t vidspeed_list[] = -{ - {"8-bit", 0}, - {"Slow 16-bit", 1}, - {"Fast 16-bit", 2}, - {"Slow VLB/PCI", 3}, - {"Mid VLB/PCI", 4}, - {"Fast VLB/PCI", 5}, - {"", -1} -}; - -static allegro_list_t fdd_list[] = -{ - {"None", 0}, - {"5.25\" 360k", 1}, - {"5.25\" 1.2M", 2}, - {"5.25\" 1.2M Dual RPM", 3}, - {"3.5\" 720k", 4}, - {"3.5\" 1.44M", 5}, - {"3.5\" 1.44M 3-Mode", 6}, - {"3.5\" 2.88M", 7}, - {"", -1} -}; - -static allegro_list_t waitstate_list[] = -{ - {"System default", 0}, - {"0 W/S", 1}, - {"1 W/S", 2}, - {"2 W/S", 3}, - {"3 W/S", 4}, - {"4 W/S", 5}, - {"5 W/S", 6}, - {"6 W/S", 7}, - {"7 W/S", 8}, - {"", -1} -}; - - -static void reset_list(); - -static char *list_proc_model(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (model_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return model_list[index].name; -} - -static char *list_proc_video(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (video_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return video_list[index].name; -} - -static char *list_proc_vidspeed(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (vidspeed_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return vidspeed_list[index].name; -} - -static char *list_proc_sound(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (sound_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return sound_list[index].name; -} - -static char *list_proc_cpumanu(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (cpumanu_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return cpumanu_list[index].name; -} - -static char *list_proc_cpu(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (cpu_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return cpu_list[index].name; -} - -static char *list_proc_hdd(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (hdd_list[c].internal_name) - c++; - - *list_size = c; - return NULL; - } - - return hdd_list[index].name; -} - -static char *list_proc_fdd(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (fdd_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return fdd_list[index].name; -} - -static char *list_proc_joystick(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (joystick_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return joystick_list[index].name; -} - -static char *list_proc_mouse(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (mouse_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return mouse_list[index].name; -} - -static char *list_proc_ws(int index, int *list_size) -{ - if (index < 0) - { - int c = 0; - - while (waitstate_list[c].name[0]) - c++; - - *list_size = c; - return NULL; - } - - return waitstate_list[index].name; -} - -static int voodoo_config_proc(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_CLOSE) - { - deviceconfig_open(&voodoo_device); - return D_O_K; - } - - return ret; -} - -static int model_config_proc(int msg, DIALOG *d, int c); -static int video_config_proc(int msg, DIALOG *d, int c); -static int sound_config_proc(int msg, DIALOG *d, int c); -static int list_proc(int msg, DIALOG *d, int c); - -static DIALOG configure_dialog[] = -{ - {d_shadow_box_proc, 0, 0, 568,372,0,0xffffff,0,0, 0,0,0,0,0}, // 0 - - {d_button_proc, 226, 348, 50, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "OK", 0, 0}, // 1 - {d_button_proc, 296, 348, 50, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Cancel", 0, 0}, // 2 - - {list_proc, 70*2, 12, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_model, 0, 0}, - - {list_proc, 70*2, 32, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_video, 0, 0}, - - {list_proc, 70*2, 52, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_cpumanu, 0, 0}, //5 - {list_proc, 70*2, 72, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_cpu, 0, 0}, - {d_list_proc, 70*2, 132, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_vidspeed, 0, 0}, //7 - {list_proc, 70*2, 152, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_sound, 0, 0}, //8 - - {d_edit_proc, 70*2, 276, 48, 14, 0, 0xffffff, 0, 0, 5, 0, mem_size_str, 0, 0}, - - {d_text_proc, 98*2, 276, 40, 10, 0, 0xffffff, 0, 0, 0, 0, mem_size_units, 0, 0}, - - {d_check_proc, 14*2, 292, 118*2, 10, 0, 0xffffff, 0, 0, 0, 0, "CMS / Game Blaster", 0, 0}, - {d_check_proc, 14*2, 308, 118*2, 10, 0, 0xffffff, 0, 0, 0, 0, "Gravis Ultrasound", 0, 0}, - {d_check_proc, 14*2, 324, 118*2, 10, 0, 0xffffff, 0, 0, 0, 0, "Innovation SSI-2001", 0, 0}, - {d_check_proc, 14*2, 336, 118*2, 10, 0, 0xffffff, 0, 0, 0, 0, "Voodoo Graphics", 0, 0}, //14 - - {d_text_proc, 16*2, 16, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Machine :", 0, 0}, - {d_text_proc, 16*2, 36, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Video :", 0, 0}, - {d_text_proc, 16*2, 56, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "CPU type :", 0, 0}, - {d_text_proc, 16*2, 76, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "CPU :", 0, 0}, - {d_text_proc, 16*2, 136, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Video speed :", 0, 0}, - {d_text_proc, 16*2, 156, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Soundcard :", 0, 0}, - {d_text_proc, 16*2, 276, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Memory :", 0, 0}, - - {d_check_proc, 14*2, 92, 118*2, 10, 0, 0xffffff, 0, 0, 0, 0, "Dynamic Recompiler", 0, 0}, - - {d_text_proc, 16*2, 196, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Drive A: :", 0, 0}, - {d_text_proc, 16*2, 216, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Drive B: :", 0, 0}, - {d_list_proc, 70*2, 192, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_fdd, 0, 0}, //25 - {d_list_proc, 70*2, 212, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_fdd, 0, 0}, - - {video_config_proc, 452, 36, 100, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "Configure...", 0, 0}, //27 - {sound_config_proc, 452, 156, 100, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "Configure...", 0, 0}, - {voodoo_config_proc, 452, 336, 100, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "Configure...", 0, 0}, - - {d_text_proc, 16*2, 236, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Joystick :", 0, 0}, - {d_list_proc, 70*2, 232, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_joystick, 0, 0}, //31 - - {d_text_proc, 16*2, 256, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Mouse :", 0, 0}, - {d_list_proc, 70*2, 252, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_mouse, 0, 0}, //33 - - {model_config_proc, 452, 12, 100, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "Configure...", 0, 0}, - - {d_text_proc, 16*2, 116, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "Waitstates :", 0, 0}, - {d_list_proc, 70*2, 112, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_ws, 0, 0}, //36 - - {d_text_proc, 16*2, 176, 40, 10, 0, 0xffffff, 0, 0, 0, 0, "HDD :", 0, 0}, - {d_list_proc, 70*2, 172, 152*2, 20, 0, 0xffffff, 0, 0, 0, 0, list_proc_hdd, 0, 0}, //38 - - {0,0,0,0,0,0,0,0,0,0,0,NULL,NULL,NULL} -}; - -static void update_hdd_list(int model, int use_selected_hdd) -{ - memset(hdd_list, 0, sizeof(hdd_list)); - - if (models[model].flags & MODEL_HAS_IDE) - { - strcpy(hdd_list[0].name, "Internal IDE"); - hdd_list[0].internal_name = "internal_ide"; - } - else - { - int c = 0, d = 0; - char old_name[16]; - - if (use_selected_hdd) - { - c = configure_dialog[38].d1; - - if (c != -1 && hdd_list[c].internal_name) - strncpy(old_name, hdd_list[c].internal_name, sizeof(old_name)-1); - else - strcpy(old_name, "none"); - } - else - strncpy(old_name, hdd_controller_name, sizeof(old_name)-1); - - configure_dialog[38].d1 = 0; - pclog("HDD list %i\n", model); - c = 0; - while (1) - { - char *s = hdd_controller_get_name(c); - - if (s[0] == 0) - break; - - if ((((hdd_controller_get_flags(c) & DEVICE_AT) && !(models[model].flags & MODEL_AT)) || - (hdd_controller_get_flags(c) & DEVICE_MCA) != (models[model].flags & MODEL_MCA)) && c) - { - pclog("Skip %i 1 %s\n", c, s); - c++; - continue; - } - if (!hdd_controller_available(c)) - { - pclog("Skip %i 2 %s\n", c, s); - c++; - continue; - } - - strcpy(hdd_list[d].name, s); - hdd_list[d].internal_name = hdd_controller_get_internal_name(c); - - if (!strcmp(old_name, hdd_list[d].internal_name)) - configure_dialog[38].d1 = d; - - c++; - d++; - } - } -} - -static int mouse_valid(int type, int model) -{ - if ((type & MOUSE_TYPE_IF_MASK) == MOUSE_TYPE_PS2 && !(models[model].flags & MODEL_PS2)) - return 0; - if ((type & MOUSE_TYPE_IF_MASK) == MOUSE_TYPE_AMSTRAD && !(models[model].flags & MODEL_AMSTRAD)) - return 0; - if ((type & MOUSE_TYPE_IF_MASK) == MOUSE_TYPE_OLIM24 && !(models[model].flags & MODEL_OLIM24)) - return 0; - return 1; -} - -static void update_mouse_list() -{ - int sel_model = model_list[configure_dialog[3].d1].num; - int c = 0, d = 0; - int new_mouse = settings_list_to_mouse[configure_dialog[33].d1]; - - while (mouse_get_name(c)) - { - int type = mouse_get_type(c); - - settings_mouse_to_list[c] = d; - - if (mouse_valid(type, sel_model)) - { - strcpy(mouse_list[d].name, mouse_get_name(c)); - settings_list_to_mouse[d] = c; - d++; - } - - c++; - } - mouse_list[d].name[0] = 0; - - if (mouse_valid(mouse_get_type(new_mouse), sel_model)) - configure_dialog[33].d1 = settings_mouse_to_list[new_mouse]; - else - configure_dialog[33].d1 = 0; -} - -static int list_proc(int msg, DIALOG *d, int c) -{ - int old = d->d1; - int ret = d_list_proc(msg, d, c); - - if (d->d1 != old) - { - int new_model = model_list[configure_dialog[3].d1].num; - int new_cpu_m = configure_dialog[5].d1; - int new_cpu = configure_dialog[6].d1; - int new_dynarec = configure_dialog[22].flags & D_SELECTED; - int new_gfxcard = video_old_to_new(video_list[configure_dialog[4].d1].num); - int new_mem_size; - int cpu_flags, cpu_type; - - reset_list(); - - if (models[new_model].fixed_gfxcard) - configure_dialog[4].flags |= D_DISABLED; - else - configure_dialog[4].flags &= ~D_DISABLED; - - cpu_flags = models[new_model].cpu[new_cpu_m].cpus[new_cpu].cpu_flags; - configure_dialog[22].flags = (((cpu_flags & CPU_SUPPORTS_DYNAREC) && new_dynarec) || (cpu_flags & CPU_REQUIRES_DYNAREC)) ? D_SELECTED : 0; - if (!(cpu_flags & CPU_SUPPORTS_DYNAREC) || (cpu_flags & CPU_REQUIRES_DYNAREC)) - configure_dialog[22].flags |= D_DISABLED; - - sscanf(mem_size_str, "%i", &new_mem_size); - new_mem_size &= ~(models[new_model].ram_granularity - 1); - if (new_mem_size < models[new_model].min_ram) - new_mem_size = models[new_model].min_ram; - else if (new_mem_size > models[new_model].max_ram) - new_mem_size = models[new_model].max_ram; - sprintf(mem_size_str, "%i", new_mem_size); - - if ((models[new_model].flags & MODEL_AT) && models[new_model].ram_granularity < 128) - sprintf(mem_size_units, "MB"); - else - sprintf(mem_size_units, "kB"); - - if (!video_card_has_config(new_gfxcard)) - configure_dialog[27].flags |= D_DISABLED; - else - configure_dialog[27].flags &= ~D_DISABLED; - - if (!sound_card_has_config(configure_dialog[9].d1)) - configure_dialog[28].flags |= D_DISABLED; - else - configure_dialog[28].flags &= ~D_DISABLED; - - update_mouse_list(); - - if (!model_getdevice(new_model)) - configure_dialog[34].flags |= D_DISABLED; - else - configure_dialog[34].flags &= ~D_DISABLED; - - cpu_type = models[new_model].cpu[new_cpu_m].cpus[new_cpu].cpu_type; - if (cpu_type < CPU_286 || cpu_type > CPU_386DX) - configure_dialog[36].flags |= D_DISABLED; - else - configure_dialog[36].flags &= ~D_DISABLED; - - update_hdd_list(new_model, 1); - - return D_REDRAW; - } - - return ret; -} - -static int video_config_proc(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_CLOSE) - { - int new_gfxcard = video_old_to_new(video_list[configure_dialog[4].d1].num); - - deviceconfig_open(video_card_getdevice(new_gfxcard)); - return D_O_K; - } - - return ret; -} -static int sound_config_proc(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_CLOSE) - { - int new_sndcard = sound_list[configure_dialog[8].d1].num; - - deviceconfig_open(sound_card_getdevice(new_sndcard)); - return D_O_K; - } - - return ret; -} -static int model_config_proc(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_CLOSE) - { - int model = model_list[configure_dialog[3].d1].num; - - deviceconfig_open(model_getdevice(model)); - return D_O_K; - } - - return ret; -} - - -static void reset_list() -{ - int model = model_list[configure_dialog[3].d1].num; - int cpumanu = configure_dialog[5].d1; - int cpu = configure_dialog[6].d1; - int c; - - memset(cpumanu_list, 0, sizeof(cpumanu_list)); - memset(cpu_list, 0, sizeof(cpu_list)); - - c = 0; - while (models[model].cpu[c].cpus != NULL && c < 3) - { - strcpy(cpumanu_list[c].name, models[model].cpu[c].name); - cpumanu_list[c].num = c; - c++; - } - - if (cpumanu >= c) - cpumanu = configure_dialog[6].d1 = c-1; - - c = 0; - while (models[model].cpu[cpumanu].cpus[c].cpu_type != -1) - { - strcpy(cpu_list[c].name, models[model].cpu[cpumanu].cpus[c].name); - cpu_list[c].num = c; - c++; - } - - if (cpu >= c) - cpu = configure_dialog[7].d1 = c-1; -} - -int settings_configure() -{ - int c, d; - int cpu_flags; - - memset(model_list, 0, sizeof(model_list)); - memset(video_list, 0, sizeof(video_list)); - memset(sound_list, 0, sizeof(sound_list)); - - for (c = 0; c < ROM_MAX; c++) - romstolist[c] = 0; - c = d = 0; - while (models[c].id != -1) - { - pclog("INITDIALOG : %i %i %i\n",c,models[c].id,romspresent[models[c].id]); - if (romspresent[models[c].id]) - { - strcpy(model_list[d].name, models[c].name); - model_list[d].num = c; - if (c == model) - configure_dialog[3].d1 = d; - d++; - } - c++; - } - - if (models[model].fixed_gfxcard) - configure_dialog[4].flags |= D_DISABLED; - else - configure_dialog[4].flags &= ~D_DISABLED; - - c = d = 0; - while (1) - { - char *s = video_card_getname(c); - - if (!s[0]) - break; -pclog("video_card_available : %i\n", c); - if (video_card_available(c)) - { - strcpy(video_list[d].name, video_card_getname(c)); - video_list[d].num = video_new_to_old(c); - if (video_new_to_old(c) == gfxcard) - configure_dialog[4].d1 = d; - d++; - } - - c++; - } - - if (!video_card_has_config(video_old_to_new(gfxcard))) - configure_dialog[27].flags |= D_DISABLED; - else - configure_dialog[27].flags &= ~D_DISABLED; - - c = d = 0; - while (1) - { - char *s = sound_card_getname(c); - - if (!s[0]) - break; - - if (sound_card_available(c)) - { - strcpy(sound_list[d].name, sound_card_getname(c)); - sound_list[d].num = c; - if (c == sound_card_current) - configure_dialog[8].d1 = d; - d++; - } - - c++; - } - - c = 0; - while (joystick_get_name(c)) - { - strcpy(joystick_list[c].name, joystick_get_name(c)); - if (c == joystick_type) - configure_dialog[31].d1 = c; - - c++; - } - - configure_dialog[33].d1 = 0; - update_mouse_list(); - configure_dialog[33].d1 = settings_mouse_to_list[mouse_type]; - - update_hdd_list(model, 0); - - if (!sound_card_has_config(configure_dialog[8].d1)) - configure_dialog[28].flags |= D_DISABLED; - else - configure_dialog[28].flags &= ~D_DISABLED; - - configure_dialog[5].d1 = cpu_manufacturer; - configure_dialog[6].d1 = cpu; - configure_dialog[7].d1 = video_speed; - configure_dialog[36].d1 = cpu_waitstates; - reset_list(); -// strcpy(cpumanu_str, models[romstomodel[romset]].cpu[cpu_manufacturer].name); -// strcpy(cpu_str, models[romstomodel[romset]].cpu[cpu_manufacturer].cpus[cpu].name); -// strcpy(cache_str, cache_str_list[cache]); -// strcpy(vidspeed_str, vidspeed_str_list[video_speed]); - -// strcpy(soundcard_str, sound_card_getname(sound_card_current)); - - if (GAMEBLASTER) - configure_dialog[11].flags |= D_SELECTED; - else - configure_dialog[11].flags &= ~D_SELECTED; - - if (GUS) - configure_dialog[12].flags |= D_SELECTED; - else - configure_dialog[12].flags &= ~D_SELECTED; - - if (SSI2001) - configure_dialog[13].flags |= D_SELECTED; - else - configure_dialog[13].flags &= ~D_SELECTED; - - if (voodoo_enabled) - configure_dialog[14].flags |= D_SELECTED; - else - configure_dialog[14].flags &= ~D_SELECTED; - - if ((models[model].flags & MODEL_AT) && models[model].ram_granularity < 128) - sprintf(mem_size_str, "%i", mem_size / 1024); - else - sprintf(mem_size_str, "%i", mem_size); - - if ((models[model].flags & MODEL_AT) && models[model].ram_granularity < 128) - sprintf(mem_size_units, "MB"); - else - sprintf(mem_size_units, "kB"); - - if (!model_getdevice(model)) - configure_dialog[34].flags |= D_DISABLED; - else - configure_dialog[34].flags &= ~D_DISABLED; - - cpu_flags = models[model].cpu[cpu_manufacturer].cpus[cpu].cpu_flags; - configure_dialog[22].flags = (((cpu_flags & CPU_SUPPORTS_DYNAREC) && cpu_use_dynarec) || (cpu_flags & CPU_REQUIRES_DYNAREC)) ? D_SELECTED : 0; - if (!(cpu_flags & CPU_SUPPORTS_DYNAREC) || (cpu_flags & CPU_REQUIRES_DYNAREC)) - configure_dialog[22].flags |= D_DISABLED; - - configure_dialog[25].d1 = fdd_get_type(0); - configure_dialog[26].d1 = fdd_get_type(1); - - while (1) - { - position_dialog(configure_dialog, SCREEN_W/2 - configure_dialog[0].w/2, SCREEN_H/2 - configure_dialog[0].h/2); - - c = popup_dialog(configure_dialog, 1); - - position_dialog(configure_dialog, -(SCREEN_W/2 - configure_dialog[0].w/2), -(SCREEN_H/2 - configure_dialog[0].h/2)); - - if (c == 1) - { - int new_model = model_list[configure_dialog[3].d1].num; - int new_gfxcard = video_list[configure_dialog[4].d1].num; - int new_sndcard = sound_list[configure_dialog[8].d1].num; - int new_cpu_m = configure_dialog[5].d1; - int new_cpu = configure_dialog[6].d1; - int new_mem_size; - int new_has_fpu = (models[new_model].cpu[new_cpu_m].cpus[new_cpu].cpu_type >= CPU_i486DX) ? 1 : 0; - int new_GAMEBLASTER = (configure_dialog[11].flags & D_SELECTED) ? 1 : 0; - int new_GUS = (configure_dialog[12].flags & D_SELECTED) ? 1 : 0; - int new_SSI2001 = (configure_dialog[13].flags & D_SELECTED) ? 1 : 0; - int new_voodoo = (configure_dialog[14].flags & D_SELECTED) ? 1 : 0; - int new_dynarec = (configure_dialog[22].flags & D_SELECTED) ? 1 : 0; - int new_fda = configure_dialog[25].d1; - int new_fdb = configure_dialog[26].d1; - int new_mouse = settings_list_to_mouse[configure_dialog[33].d1]; - int new_hdd = configure_dialog[38].d1; - - sscanf(mem_size_str, "%i", &new_mem_size); - new_mem_size &= ~(models[new_model].ram_granularity - 1); - if (new_mem_size < models[new_model].min_ram) - new_mem_size = models[new_model].min_ram; - else if (new_mem_size > models[new_model].max_ram) - new_mem_size = models[new_model].max_ram; - if ((models[new_model].flags & MODEL_AT) && models[new_model].ram_granularity < 128) - new_mem_size *= 1024; - - if (new_model != model || new_gfxcard != gfxcard || new_mem_size != mem_size || - new_has_fpu != hasfpu || new_GAMEBLASTER != GAMEBLASTER || new_GUS != GUS || - new_SSI2001 != SSI2001 || new_sndcard != sound_card_current || new_voodoo != voodoo_enabled || - new_dynarec != cpu_use_dynarec || new_fda != fdd_get_type(0) || new_fdb != fdd_get_type(1) || - new_mouse != mouse_type || strncmp(hdd_list[new_hdd].internal_name, hdd_controller_name, sizeof(hdd_controller_name)-1)) - { - if (has_been_inited && alert("This will reset PCem!", "Okay to continue?", NULL, "OK", "Cancel", 0, 0) != 1) - continue; - - model = new_model; - romset = model_getromset(); - gfxcard = new_gfxcard; - mem_size = new_mem_size; - cpu_manufacturer = new_cpu_m; - cpu = new_cpu; - GAMEBLASTER = new_GAMEBLASTER; - GUS = new_GUS; - SSI2001 = new_SSI2001; - sound_card_current = new_sndcard; - voodoo_enabled = new_voodoo; - cpu_use_dynarec = new_dynarec; - mouse_type = new_mouse; - - if (hdd_list[new_hdd].internal_name) - strncpy(hdd_controller_name, hdd_list[new_hdd].internal_name, sizeof(hdd_controller_name)-1); - else - strcpy(hdd_controller_name, "none"); - - mem_resize(); - loadbios(); - resetpchard(); - - fdd_set_type(0, new_fda); - fdd_set_type(1, new_fdb); - } - - video_speed = configure_dialog[7].d1; - - cpu_manufacturer = new_cpu_m; - cpu = new_cpu; - cpu_set(); - - cpu_waitstates = configure_dialog[36].d1; - cpu_update_waitstates(); - - joystick_type = configure_dialog[31].d1; - gameport_update_joystick_type(); - - saveconfig(NULL); - - speedchanged(); - - return D_O_K; - } - - if (c == 2) - return D_O_K; - } - - return D_O_K; -} - diff --git a/src/allegro-gui-deviceconfig.c b/src/allegro-gui-deviceconfig.c deleted file mode 100644 index 3899ce9..0000000 --- a/src/allegro-gui-deviceconfig.c +++ /dev/null @@ -1,303 +0,0 @@ -#include "ibm.h" -#include "device.h" -#include "allegro-main.h" -#include "allegro-gui.h" -#include "config.h" - -static device_t *config_device; - -#define MAX_CONFIG_SIZE 64 -#define MAX_CONFIG_SELECTIONS 8 - -static device_config_selection_t *config_selections[MAX_CONFIG_SELECTIONS]; - -#define list_proc_device_func(i) \ - static char *list_proc_device_ ## i(int index, int *list_size) \ - { \ - device_config_selection_t *config = config_selections[i]; \ - \ - if (index < 0) \ - { \ - int c = 0; \ - \ - while (config[c].description[0]) \ - c++; \ - \ - *list_size = c; \ - return NULL; \ - } \ - \ - return config[index].description; \ - } - -list_proc_device_func(0) -list_proc_device_func(1) -list_proc_device_func(2) -list_proc_device_func(3) -list_proc_device_func(4) -list_proc_device_func(5) -list_proc_device_func(6) -list_proc_device_func(7) - -static DIALOG deviceconfig_dialog[MAX_CONFIG_SIZE] = -{ - {d_shadow_box_proc, 0, 0, 568,332,0,0xffffff,0,0, 0,0,0,0,0} // 0 -}; - -void deviceconfig_open(device_t *device) -{ - DIALOG *d; - device_config_t *config = device->config; - int y = 10; - int dialog_pos = 1; - int list_pos = 0; - int c; - int id_ok, id_cancel; - - memset((void *)((uintptr_t)deviceconfig_dialog) + sizeof(DIALOG), 0, sizeof(deviceconfig_dialog) - sizeof(DIALOG)); - deviceconfig_dialog[0].x = deviceconfig_dialog[0].y = 0; - - while (config->type != -1) - { - d = &deviceconfig_dialog[dialog_pos]; - - switch (config->type) - { - case CONFIG_BINARY: - d->x = 32; - d->y = y; - - d->w = 118*2; - d->h = 15; - - d->dp = config->description; - d->proc = d_check_proc; - - d->flags = config_get_int(CFG_MACHINE, device->name, config->name, config->default_int) ? D_SELECTED : 0; - d->bg = 0xffffff; - d->fg = 0; - - dialog_pos++; - - y += 20; - break; - - case CONFIG_SELECTION: - if (list_pos >= MAX_CONFIG_SELECTIONS) - break; - - d->x = 32; - d->y = y; - - d->w = 80; - d->h = 15; - - d->dp = config->description; - d->proc = d_text_proc; - - d->flags = 0; - d->bg = 0xffffff; - d->fg = 0; - - d++; - - d->x = 250; - d->y = y; - - d->w = 304; - d->h = 20; - - switch (list_pos) - { - case 0 : d->dp = list_proc_device_0; break; - case 1 : d->dp = list_proc_device_1; break; - case 2 : d->dp = list_proc_device_2; break; - case 3 : d->dp = list_proc_device_3; break; - case 4 : d->dp = list_proc_device_4; break; - case 5 : d->dp = list_proc_device_5; break; - case 6 : d->dp = list_proc_device_6; break; - case 7 : d->dp = list_proc_device_7; break; - } - d->proc = d_list_proc; - - d->flags = 0; - d->bg = 0xffffff; - d->fg = 0; - - config_selections[list_pos++] = config->selection; - - c = 0; - while (config->selection[c].description[0]) - { - if (config_get_int(CFG_MACHINE, device->name, config->name, config->default_int) == config->selection[c].value) - d->d1 = c; - c++; - } - - dialog_pos += 2; - - y += 20; - break; - - case CONFIG_MIDI: - break; - } - - config++; - - if (dialog_pos >= MAX_CONFIG_SIZE-3) - break; - } - - d = &deviceconfig_dialog[dialog_pos]; - - id_ok = dialog_pos; - id_cancel = dialog_pos + 1; - - d->x = 226; - d->y = y+8; - - d->w = 50; - d->h = 16; - - d->dp = "OK"; - d->proc = d_button_proc; - - d->flags = D_EXIT; - d->bg = 0xffffff; - d->fg = 0; - - d++; - - d->x = 296; - d->y = y+8; - - d->w = 50; - d->h = 16; - - d->dp = "Cancel"; - d->proc = d_button_proc; - - d->flags = D_EXIT; - d->bg = 0xffffff; - d->fg = 0; - - deviceconfig_dialog[0].h = y + 28; - - config_device = device; - - while (1) - { - position_dialog(deviceconfig_dialog, SCREEN_W/2 - deviceconfig_dialog[0].w/2, SCREEN_H/2 - deviceconfig_dialog[0].h/2); - - c = popup_dialog(deviceconfig_dialog, 1); - - position_dialog(deviceconfig_dialog, -(SCREEN_W/2 - deviceconfig_dialog[0].w/2), -(SCREEN_H/2 - deviceconfig_dialog[0].h/2)); - - if (c == id_ok) - { - int changed = 0; - - dialog_pos = 1; - config = device->config; - - while (config->type != -1) - { - int val; - - d = &deviceconfig_dialog[dialog_pos]; - - switch (config->type) - { - case CONFIG_BINARY: - val = (d->flags & D_SELECTED) ? 1 : 0; - - if (val != config_get_int(CFG_MACHINE, device->name, config->name, config->default_int)) - changed = 1; - - dialog_pos++; - break; - - case CONFIG_SELECTION: - if (list_pos >= MAX_CONFIG_SELECTIONS) - break; - - d++; - - val = config->selection[d->d1].value; - - if (val != config_get_int(CFG_MACHINE, device->name, config->name, config->default_int)) - changed = 1; - - dialog_pos += 2; - break; - - case CONFIG_MIDI: - break; - } - - config++; - - if (dialog_pos >= MAX_CONFIG_SIZE-3) - break; - } - - if (!changed) - return; - - if (alert("This will reset PCem!", "Okay to continue?", NULL, "OK", "Cancel", 0, 0) != 1) - continue; - - dialog_pos = 1; - config = device->config; - - while (config->type != -1) - { - int val; - - d = &deviceconfig_dialog[dialog_pos]; - - switch (config->type) - { - case CONFIG_BINARY: - val = (d->flags & D_SELECTED) ? 1 : 0; - - config_set_int(CFG_MACHINE, config_device->name, config->name, val); - - dialog_pos++; - break; - - case CONFIG_SELECTION: - if (list_pos >= MAX_CONFIG_SELECTIONS) - break; - - d++; - - val = config->selection[d->d1].value; - - config_set_int(CFG_MACHINE, config_device->name, config->name, val); - - dialog_pos += 2; - break; - - case CONFIG_MIDI: - break; - } - - config++; - - if (dialog_pos >= MAX_CONFIG_SIZE-3) - break; - } - - saveconfig(NULL); - - resetpchard(); - - return; - } - - if (c == id_cancel) - break; - } -} diff --git a/src/allegro-gui-hdconf.c b/src/allegro-gui-hdconf.c deleted file mode 100644 index 050be68..0000000 --- a/src/allegro-gui-hdconf.c +++ /dev/null @@ -1,537 +0,0 @@ -#define _LARGEFILE_SOURCE -#define _LARGEFILE64_SOURCE -#define _GNU_SOURCE - -#include -#include "ibm.h" -#include "device.h" -#include "ide.h" -#include "allegro-main.h" -#include "allegro-gui.h" - -static char hd_path[4][260]; -static char hd_sectors[4][10]; -static char hd_heads[4][10]; -static char hd_cylinders[4][10]; -static char hd_size[4][20]; - -static char hd_path_new[260]; -static char hd_sectors_new[10]; -static char hd_heads_new[10]; -static char hd_cylinders_new[10]; -static char hd_size_new[20]; - -static int new_cdrom_channel; - -static PcemHDC hdc_new[4]; - -static DIALOG hdparams_dialog[]= -{ - {d_shadow_box_proc, 0, 0, 194*2,86,0,0xffffff,0,0, 0,0,0,0,0}, // 0 - - {d_button_proc, 126, 66, 50, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "OK", 0, 0}, // 1 - {d_button_proc, 196, 66, 50, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Cancel", 0, 0}, // 2 - - {d_text_proc, 7*2, 6, 170, 10, 0, 0xffffff, 0, 0, 0, 0, "Initial settings are based on file size", 0, 0}, - - {d_text_proc, 7*2, 22, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "Sectors:", 0, 0}, - {d_text_proc, 63*2, 22, 29, 8, 0, 0xffffff, 0, 0, 0, 0, "Heads:", 0, 0}, - {d_text_proc, 120*2, 22, 28, 12, 0, 0xffffff, 0, 0, 0, 0, "Cylinders:", 0, 0}, - {d_edit_proc, 44*2, 22, 16*2, 12, 0, 0xffffff, 0, 0, 2, 0, hd_sectors_new, 0, 0}, - {d_edit_proc, 92*2, 22, 16*2, 12, 0, 0xffffff, 0, 0, 3, 0, hd_heads_new, 0, 0}, - {d_edit_proc, 168*2, 22, 24*2, 12, 0, 0xffffff, 0, 0, 5, 0, hd_cylinders_new, 0, 0}, - {d_text_proc, 7*2, 54, 136, 12, 0, 0xffffff, 0, 0, 0, 0, hd_size_new, 0, 0}, - - {0,0,0,0,0,0,0,0,0,0,0,NULL,NULL,NULL} -}; - -static int hdconf_open(int msg, DIALOG *d, int c) -{ - int drv = d->d2; - int ret = d_button_proc(msg, d, c); - - if (ret == D_EXIT) - { - char fn[260]; - int xsize = SCREEN_W - 32, ysize = SCREEN_H - 64; - - strcpy(fn, hd_path[drv]); - ret = file_select_ex("Please choose a disc image", fn, "IMG", 260, xsize, ysize); - if (ret) - { - uint64_t sz; - FILE *f = fopen64(fn, "rb"); - if (!f) - { - return D_REDRAW; - } - fseeko64(f, -1, SEEK_END); - sz = ftello64(f) + 1; - fclose(f); - if ((sz % 17) == 0 && sz <= 142606336) - { - sprintf(hd_sectors_new, "17"); - if (sz <= 26738688) - { - sprintf(hd_heads_new, "4"); - sprintf(hd_cylinders_new, "%i", (int)((sz / 512) / 4) / 17); - } - else if ((sz % 3072) == 0 && sz <= 53477376) - { - sprintf(hd_heads_new, "6"); - sprintf(hd_cylinders_new, "%i", (int)((sz / 512) / 6) / 17); - } - else - { - int i; - for(i=5;i<16;i++) - { - if((sz % (i * 512)) == 0 && sz <= 1024*i*17*512) break; - if (i == 5) i++; - } - sprintf(hd_heads_new, "%i",i); - sprintf(hd_cylinders_new, "%i", (int)((sz / 512) / i) / 17); - } - } - else - { - sprintf(hd_sectors_new, "63"); - sprintf(hd_heads_new, "16"); - sprintf(hd_cylinders_new, "%i", (int)((sz / 512) / 16) / 63); - } - - while (1) - { - position_dialog(hdparams_dialog, SCREEN_W/2 - 186, SCREEN_H/2 - 86/2); - - ret = popup_dialog(hdparams_dialog, 1); - - position_dialog(hdparams_dialog, -(SCREEN_W/2 - 186), -(SCREEN_H/2 - 86/2)); - - if (ret == 1) - { - int spt, hpc, cyl; - sscanf(hd_sectors_new, "%i", &spt); - sscanf(hd_heads_new, "%i", &hpc); - sscanf(hd_cylinders_new, "%i", &cyl); - - if (spt > 63) - { - alert("Drive has too many sectors (maximum is 63)", NULL, NULL, "OK", NULL, 0, 0); - continue; - } - if (hpc > 128) - { - alert("Drive has too many heads (maximum is 128)", NULL, NULL, "OK", NULL, 0, 0); - continue; - } - if (cyl > 16383) - { - alert("Drive has too many cylinders (maximum is 16383)", NULL, NULL, "OK", NULL, 0, 0); - continue; - } - - hdc_new[drv].spt = spt; - hdc_new[drv].hpc = hpc; - hdc_new[drv].tracks = cyl; - - strcpy(hd_path[drv], fn); - sprintf(hd_sectors[drv], "%i", hdc_new[drv].spt); - sprintf(hd_heads[drv], "%i", hdc_new[drv].hpc); - sprintf(hd_cylinders[drv], "%i", hdc_new[drv].tracks); - sprintf(hd_size[drv], "Size : %imb", (((((uint64_t)hdc_new[drv].tracks*(uint64_t)hdc_new[drv].hpc)*(uint64_t)hdc_new[drv].spt)*512)/1024)/1024); - - return D_REDRAW; - } - - if (ret == 2) - break; - } - } - - return D_REDRAW; - } - - return ret; -} - -static int hdconf_new_file(int msg, DIALOG *d, int c) -{ - int ret = d_button_proc(msg, d, c); - - if (ret == D_EXIT) - { - char fn[260]; - int xsize = SCREEN_W - 32, ysize = SCREEN_H - 64; - - strcpy(fn, hd_path_new); - ret = file_select_ex("Please choose a disc image", fn, "IMG", 260, xsize, ysize); - if (ret) - strcpy(hd_path_new, fn); - - return D_REDRAW; - } - - return ret; -} - -static DIALOG hdnew_dialog[]= -{ - {d_shadow_box_proc, 0, 0, 194*2,86,0,0xffffff,0,0, 0,0,0,0,0}, // 0 - - {d_button_proc, 126, 66, 50, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "OK", 0, 0}, // 1 - {d_button_proc, 196, 66, 50, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Cancel", 0, 0}, // 2 - - {d_edit_proc, 7*2, 6, 136*2, 10, 0, 0xffffff, 0, 0, 0, 0, hd_path_new, 0, 0}, - {hdconf_new_file, 143*2, 6, 16*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "...", 0, 0}, - - {d_text_proc, 7*2, 22, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "Sectors:", 0, 0}, - {d_text_proc, 63*2, 22, 29, 8, 0, 0xffffff, 0, 0, 0, 0, "Heads:", 0, 0}, - {d_text_proc, 120*2, 22, 28, 12, 0, 0xffffff, 0, 0, 0, 0, "Cylinders:", 0, 0}, - {d_edit_proc, 44*2, 22, 16*2, 12, 0, 0xffffff, 0, 0, 2, 0, hd_sectors_new, 0, 0}, - {d_edit_proc, 92*2, 22, 16*2, 12, 0, 0xffffff, 0, 0, 3, 0, hd_heads_new, 0, 0}, - {d_edit_proc, 168*2, 22, 24*2, 12, 0, 0xffffff, 0, 0, 5, 0, hd_cylinders_new, 0, 0}, -// {d_text_proc, 7*2, 54, 136, 12, 0, -1, 0, 0, 0, 0, hd_size_new, 0, 0}, - - {0,0,0,0,0,0,0,0,0,0,0,NULL,NULL,NULL} -}; - -static int create_hd(char *fn, int cyl, int hpc, int spt) -{ - int c; - uint8_t buf[512]; - FILE *f = fopen64(hd_path_new, "wb"); - if (!f) - { - alert("Can't open file for write", NULL, NULL, "OK", NULL, 0, 0); - return -1; - } - memset(buf, 0, 512); - for (c = 0; c < (cyl * hpc * spt); c++) - { - fwrite(buf, 512, 1, f); - } - fclose(f); - - return 0; -} - -static int hdconf_new(int msg, DIALOG *d, int c) -{ - int drv = d->d2; - int ret = d_button_proc(msg, d, c); - - if (ret == D_EXIT) - { - sprintf(hd_sectors_new, "63"); - sprintf(hd_heads_new, "16"); - sprintf(hd_cylinders_new, "511"); - strcpy(hd_path_new, ""); - - while (1) - { - position_dialog(hdnew_dialog, SCREEN_W/2 - 186, SCREEN_H/2 - 86/2); - - ret = popup_dialog(hdnew_dialog, 1); - - position_dialog(hdnew_dialog, -(SCREEN_W/2 - 186), -(SCREEN_H/2 - 86/2)); - - if (ret == 1) - { - int spt, hpc, cyl; - - sscanf(hd_sectors_new, "%i", &spt); - sscanf(hd_heads_new, "%i", &hpc); - sscanf(hd_cylinders_new, "%i", &cyl); - - if (spt > 63) - { - alert("Drive has too many sectors (maximum is 63)", NULL, NULL, "OK", NULL, 0, 0); - continue; - } - if (hpc > 128) - { - alert("Drive has too many heads (maximum is 128)", NULL, NULL, "OK", NULL, 0, 0); - continue; - } - if (cyl > 16383) - { - alert("Drive has too many cylinders (maximum is 16383)", NULL, NULL, "OK", NULL, 0, 0); - continue; - } - if (create_hd(hd_path_new, cyl, hpc, spt)) - return D_REDRAW; - - alert("Remember to partition and format the new drive", NULL, NULL, "OK", NULL, 0, 0); - - hdc_new[drv].spt = spt; - hdc_new[drv].hpc = hpc; - hdc_new[drv].tracks = cyl; - - strcpy(hd_path[drv], hd_path_new); - sprintf(hd_sectors[drv], "%i", hdc_new[drv].spt); - sprintf(hd_heads[drv], "%i", hdc_new[drv].hpc); - sprintf(hd_cylinders[drv], "%i", hdc_new[drv].tracks); - sprintf(hd_size[drv], "Size : %imb", (((((uint64_t)hdc_new[drv].tracks*(uint64_t)hdc_new[drv].hpc)*(uint64_t)hdc_new[drv].spt)*512)/1024)/1024); - - return D_REDRAW; - } - - if (ret == 2) - break; - } - - return D_REDRAW; - } - - return ret; -} - -static int hdconf_eject(int msg, DIALOG *d, int c) -{ - int drv = d->d2; - int ret = d_button_proc(msg, d, c); - - if (ret == D_EXIT) - { - hdc_new[drv].spt = 0; - hdc_new[drv].hpc = 0; - hdc_new[drv].tracks = 0; - strcpy(hd_path[drv], ""); - sprintf(hd_sectors[drv], "%i", hdc_new[drv].spt); - sprintf(hd_heads[drv], "%i", hdc_new[drv].hpc); - sprintf(hd_cylinders[drv], "%i", hdc_new[drv].tracks); - sprintf(hd_size[drv], "Size : %imb", (((((uint64_t)hdc_new[drv].tracks*(uint64_t)hdc_new[drv].hpc)*(uint64_t)hdc_new[drv].spt)*512)/1024)/1024); - - return D_REDRAW; - } - - return ret; -} - -static int hdconf_radio_hd(int msg, DIALOG *d, int c); -static int hdconf_radio_cd(int msg, DIALOG *d, int c); - -static DIALOG hdconf_dialog[]= -{ - {d_shadow_box_proc, 0, 0, 210*2,354,0,0xffffff,0,0, 0,0,0,0,0}, // 0 - - {d_button_proc, 150, 334, 50, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "OK", 0, 0}, // 1 - {d_button_proc, 220, 334, 50, 16, 0, 0xffffff, 0, D_EXIT, 0, 0, "Cancel", 0, 0}, // 2 - - {d_text_proc, 7*2, 6, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "C:", 0, 0}, - {hdconf_radio_hd, 7*2, 22, 96, 12, 0, 0xffffff, 0, D_EXIT, 0, 0, "Hard drive", 0, 0}, // 4 - {hdconf_radio_cd, 100*2, 22, 64, 12, 0, 0xffffff, 0, D_EXIT, 0, 0, "CD-ROM", 0, 0}, // 5 - {d_edit_proc, 7*2, 38, 136*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_path[0], 0, 0}, - {hdconf_open, 143*2, 38, 16*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "...", 0, 0}, - {hdconf_new, 159*2, 38, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "New", 0, 0}, - {hdconf_eject, 183*2, 38, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 0, "Eject", 0, 0}, - - {d_text_proc, 7*2, 54, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "Sectors:", 0, 0}, - {d_text_proc, 63*2, 54, 29, 8, 0, 0xffffff, 0, 0, 0, 0, "Heads:", 0, 0}, - {d_text_proc, 120*2, 54, 28, 12, 0, 0xffffff, 0, 0, 0, 0, "Cylinders:", 0, 0}, - {d_edit_proc, 44*2, 54, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_sectors[0], 0, 0}, - {d_edit_proc, 92*2, 54, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_heads[0], 0, 0}, - {d_edit_proc, 168*2, 54, 24*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_cylinders[0], 0, 0}, - {d_text_proc, 7*2, 54, 136, 12, 0, 0xffffff, 0, 0, 0, 0, hd_size[0], 0, 0}, - - {d_text_proc, 7*2, 76, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "D:", 0, 0}, - {hdconf_radio_hd, 7*2, 92, 96, 12, 0, 0xffffff, 0, D_EXIT, 1, 0, "Hard drive", 0, 0}, // 18 - {hdconf_radio_cd, 100*2, 92, 64, 12, 0, 0xffffff, 0, D_EXIT, 1, 0, "CD-ROM", 0, 0}, // 19 - {d_edit_proc, 7*2, 108, 136*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_path[1], 0, 0}, - {hdconf_open, 143*2, 108, 16*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 1, "...", 0, 0}, - {hdconf_new, 159*2, 108, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 1, "New", 0, 0}, - {hdconf_eject, 183*2, 108, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 1, "Eject", 0, 0}, - - {d_edit_proc, 44*2, 124, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_sectors[1], 0, 0}, - {d_edit_proc, 92*2, 124, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_heads[1], 0, 0}, - {d_edit_proc, 168*2, 124, 24*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_cylinders[1], 0, 0}, - {d_text_proc, 7*2, 124, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "Sectors:", 0, 0}, - {d_text_proc, 63*2, 124, 29, 8, 0, 0xffffff, 0, 0, 0, 0, "Heads:", 0, 0}, - {d_text_proc, 120*2, 124, 32, 12, 0, 0xffffff, 0, 0, 0, 0, "Cylinders:", 0, 0}, - {d_text_proc, 7*2, 140, 136, 12, 0, 0xffffff, 0, 0, 0, 0, hd_size[1], 0, 0}, - - {d_text_proc, 7*2, 162, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "E:", 0, 0}, - {hdconf_radio_hd, 7*2, 178, 96, 12, 0, 0xffffff, 0, D_EXIT, 2, 0, "Hard drive", 0, 0}, // 32 - {hdconf_radio_cd, 100*2, 178, 64, 12, 0, 0xffffff, 0, D_EXIT, 2, 0, "CD-ROM", 0, 0}, // 33 - {d_edit_proc, 7*2, 194, 136*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_path[2], 0, 0}, - {hdconf_open, 143*2, 194, 16*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 2, "...", 0, 0}, - {hdconf_new, 159*2, 194, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 2, "New", 0, 0}, - {hdconf_eject, 183*2, 194, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 2, "Eject", 0, 0}, - - {d_edit_proc, 44*2, 210, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_sectors[2], 0, 0}, - {d_edit_proc, 92*2, 210, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_heads[2], 0, 0}, - {d_edit_proc, 168*2, 210, 24*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_cylinders[2], 0, 0}, - {d_text_proc, 7*2, 210, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "Sectors:", 0, 0}, - {d_text_proc, 63*2, 210, 29, 8, 0, 0xffffff, 0, 0, 0, 0, "Heads:", 0, 0}, - {d_text_proc, 120*2, 210, 32, 12, 0, 0xffffff, 0, 0, 0, 0, "Cylinders:", 0, 0}, - {d_text_proc, 7*2, 226, 136, 12, 0, 0xffffff, 0, 0, 0, 0, hd_size[2], 0, 0}, - - {d_text_proc, 7*2, 248, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "F:", 0, 0}, - {hdconf_radio_hd, 7*2, 264, 96, 12, 0, 0xffffff, 0, D_EXIT, 3, 0, "Hard drive", 0, 0}, // 46 - {hdconf_radio_cd, 100*2, 264, 64, 12, 0, 0xffffff, 0, D_EXIT, 3, 0, "CD-ROM", 0, 0}, // 47 - {d_edit_proc, 7*2, 280, 136*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_path[3], 0, 0}, - {hdconf_open, 143*2, 280, 16*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 3, "...", 0, 0}, - {hdconf_new, 159*2, 280, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 3, "New", 0, 0}, - {hdconf_eject, 183*2, 280, 24*2, 14, 0, 0xffffff, 0, D_EXIT, 0, 3, "Eject", 0, 0}, - - {d_edit_proc, 44*2, 296, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_sectors[3], 0, 0}, - {d_edit_proc, 92*2, 296, 16*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_heads[3], 0, 0}, - {d_edit_proc, 168*2, 296, 24*2, 12, 0, 0xffffff, 0, D_DISABLED, 0, 0, hd_cylinders[3], 0, 0}, - {d_text_proc, 7*2, 296, 27, 10, 0, 0xffffff, 0, 0, 0, 0, "Sectors:", 0, 0}, - {d_text_proc, 63*2, 296, 29, 8, 0, 0xffffff, 0, 0, 0, 0, "Heads:", 0, 0}, - {d_text_proc, 120*2, 296, 32, 12, 0, 0xffffff, 0, 0, 0, 0, "Cylinders:", 0, 0}, - {d_text_proc, 7*2, 312, 136, 12, 0, 0xffffff, 0, 0, 0, 0, hd_size[3], 0, 0}, - - {0,0,0,0,0,0,0,0,0,0,0,NULL,NULL,NULL} -}; - -static void update_hdd_cdrom() -{ - if (new_cdrom_channel == 0) - { - hdconf_dialog[4].flags &= ~D_SELECTED; - hdconf_dialog[5].flags |= D_SELECTED; - } - else - { - hdconf_dialog[4].flags |= D_SELECTED; - hdconf_dialog[5].flags &= ~D_SELECTED; - } - if (new_cdrom_channel == 1) - { - hdconf_dialog[18].flags &= ~D_SELECTED; - hdconf_dialog[19].flags |= D_SELECTED; - } - else - { - hdconf_dialog[18].flags |= D_SELECTED; - hdconf_dialog[19].flags &= ~D_SELECTED; - } - if (new_cdrom_channel == 2) - { - hdconf_dialog[32].flags &= ~D_SELECTED; - hdconf_dialog[33].flags |= D_SELECTED; - } - else - { - hdconf_dialog[32].flags |= D_SELECTED; - hdconf_dialog[33].flags &= ~D_SELECTED; - } - if (new_cdrom_channel == 3) - { - hdconf_dialog[46].flags &= ~D_SELECTED; - hdconf_dialog[47].flags |= D_SELECTED; - } - else - { - hdconf_dialog[46].flags |= D_SELECTED; - hdconf_dialog[47].flags &= ~D_SELECTED; - } -} - -static int hdconf_radio_hd(int msg, DIALOG *d, int c) -{ - int ret = d_radio_proc(msg, d, c); - - if (ret == D_CLOSE) - { - if (new_cdrom_channel == d->d1) - { - new_cdrom_channel = -1; - update_hdd_cdrom(); - } - - return D_REDRAW; - } - - return ret; -} -static int hdconf_radio_cd(int msg, DIALOG *d, int c) -{ - int ret = d_radio_proc(msg, d, c); - - if (ret == D_CLOSE) - { - if (new_cdrom_channel != d->d1) - { - new_cdrom_channel = d->d1; - update_hdd_cdrom(); - } - - return D_REDRAW; - } - - return ret; -} - -int disc_hdconf() -{ - int c; - - hdc_new[0] = hdc[0]; - hdc_new[1] = hdc[1]; - hdc_new[2] = hdc[2]; - hdc_new[3] = hdc[3]; - strcpy(hd_path[0], ide_fn[0]); - strcpy(hd_path[1], ide_fn[1]); - strcpy(hd_path[2], ide_fn[2]); - strcpy(hd_path[3], ide_fn[3]); - sprintf(hd_sectors[0], "%i", hdc[0].spt); - sprintf(hd_sectors[1], "%i", hdc[1].spt); - sprintf(hd_sectors[2], "%i", hdc[2].spt); - sprintf(hd_sectors[3], "%i", hdc[3].spt); - sprintf(hd_heads[0], "%i", hdc[0].hpc); - sprintf(hd_heads[1], "%i", hdc[1].hpc); - sprintf(hd_heads[2], "%i", hdc[2].hpc); - sprintf(hd_heads[3], "%i", hdc[3].hpc); - sprintf(hd_cylinders[0], "%i", hdc[0].tracks); - sprintf(hd_cylinders[1], "%i", hdc[1].tracks); - sprintf(hd_cylinders[2], "%i", hdc[2].tracks); - sprintf(hd_cylinders[3], "%i", hdc[3].tracks); - sprintf(hd_size[0], "Size : %imb", (((((uint64_t)hdc[0].tracks*(uint64_t)hdc[0].hpc)*(uint64_t)hdc[0].spt)*512)/1024)/1024); - sprintf(hd_size[1], "Size : %imb", (((((uint64_t)hdc[1].tracks*(uint64_t)hdc[1].hpc)*(uint64_t)hdc[1].spt)*512)/1024)/1024); - sprintf(hd_size[2], "Size : %imb", (((((uint64_t)hdc[2].tracks*(uint64_t)hdc[2].hpc)*(uint64_t)hdc[2].spt)*512)/1024)/1024); - sprintf(hd_size[3], "Size : %imb", (((((uint64_t)hdc[3].tracks*(uint64_t)hdc[3].hpc)*(uint64_t)hdc[3].spt)*512)/1024)/1024); - - new_cdrom_channel = cdrom_channel; - - update_hdd_cdrom(); - - while (1) - { - position_dialog(hdconf_dialog, SCREEN_W/2 - hdconf_dialog[0].w/2, SCREEN_H/2 - hdconf_dialog[0].h/2); - - c = popup_dialog(hdconf_dialog, 1); - - position_dialog(hdconf_dialog, -(SCREEN_W/2 - hdconf_dialog[0].w/2), -(SCREEN_H/2 - hdconf_dialog[0].h/2)); - - if (c == 1) - { - if (!has_been_inited || alert("This will reset PCem!", "Okay to continue?", NULL, "OK", "Cancel", 0, 0) == 1) - { - hdc[0] = hdc_new[0]; - hdc[1] = hdc_new[1]; - hdc[2] = hdc_new[2]; - hdc[3] = hdc_new[3]; - - strcpy(ide_fn[0], hd_path[0]); - strcpy(ide_fn[1], hd_path[1]); - strcpy(ide_fn[2], hd_path[2]); - strcpy(ide_fn[3], hd_path[3]); - - cdrom_channel = new_cdrom_channel; - - saveconfig(NULL); - - resetpchard(); - - return D_O_K; - } - } - if (c == 2) - return D_O_K; - } - - return D_O_K; -} diff --git a/src/allegro-gui.c b/src/allegro-gui.c deleted file mode 100644 index 427c226..0000000 --- a/src/allegro-gui.c +++ /dev/null @@ -1,288 +0,0 @@ -#include "ibm.h" -#include "device.h" -#include "allegro-main.h" -#include "allegro-gui.h" -#include "disc.h" -#include "ide.h" -#include "cdrom-ioctl.h" -#include "cdrom-image.h" -#include "cdrom-null.h" - -void warning(const char *format, ...) -{ - char buf[1024]; - va_list ap; - - va_start(ap, format); - vsprintf(buf, format, ap); - va_end(ap); - - alert("Warning:", buf, NULL, "OK", NULL, 0, 0); -} - - -static int file_return(void) -{ - return D_CLOSE; -} - -static int file_exit(void) -{ - quited = 1; - return D_CLOSE; -} - -static int file_reset(void) -{ - resetpchard(); - return D_CLOSE; -} - -static int file_cad(void) -{ - resetpc_cad(); - return D_CLOSE; -} - - -static MENU file_menu[]= -{ - {"&Return", file_return, NULL, 0, NULL}, - {"&Hard Reset", file_reset, NULL, 0, NULL}, - {"&Ctrl+Alt+Del", file_cad, NULL, 0, NULL}, - {"E&xit", file_exit, NULL, 0, NULL}, - {NULL,NULL,NULL,0,NULL} -}; - -static int disc_load_a() -{ - char fn[260]; - int ret; - int xsize = SCREEN_W - 32, ysize = SCREEN_H - 64; - strcpy(fn, discfns[0]); - ret = file_select_ex("Please choose a disc image", fn, "IMG;IMA;FDI", 260, xsize, ysize); - if (ret) - { - disc_close(0); - disc_load(0, fn); - saveconfig(NULL); - } - return D_O_K; -} - -static int disc_load_b() -{ - char fn[260]; - int ret; - int xsize = SCREEN_W - 32, ysize = SCREEN_H - 64; - strcpy(fn, discfns[1]); - ret = file_select_ex("Please choose a disc image", fn, "IMG;IMA;FDI", 260, xsize, ysize); - if (ret) - { - disc_close(1); - disc_load(1, fn); - saveconfig(NULL); - } - return D_O_K; -} - -static int disc_eject_a() -{ - disc_close(0); - saveconfig(NULL); - - return D_O_K; -} - -static int disc_eject_b() -{ - disc_close(1); - saveconfig(NULL); - - return D_O_K; -} - -static MENU disc_menu[]= -{ - {"Load drive &A:...", disc_load_a, NULL, 0, NULL}, - {"Load drive &B:...", disc_load_b, NULL, 0, NULL}, - {"&Eject drive &A:", disc_eject_a, NULL, 0, NULL}, - {"Eject drive &B:", disc_eject_b, NULL, 0, NULL}, - {"&Configure hard discs...", disc_hdconf, NULL, 0, NULL}, - {NULL,NULL,NULL,0,NULL} -}; - -static MENU cdrom_menu[]; - -static void cdrom_update() -{ - int c; - - for (c = 0; cdrom_menu[c].text; c++) - cdrom_menu[c].flags = 0; - - if (!cdrom_enabled) - cdrom_menu[0].flags = D_SELECTED; - else switch (cdrom_drive) - { - case -1: - cdrom_menu[1].flags = D_SELECTED; - break; - case CDROM_IMAGE: - cdrom_menu[3].flags = D_SELECTED; - break; - default: - cdrom_menu[2].flags = D_SELECTED; - break; - } -} - -static int cdrom_disabled() -{ - if (!cdrom_enabled) - return D_O_K; - - if (alert("This will reset PCem!", "Okay to continue?", NULL, "OK", "Cancel", 0, 0) == 1) - { - atapi->exit(); - cdrom_enabled = 0; - saveconfig(NULL); - resetpchard(); - cdrom_update(); - } - - return D_O_K; -} - -static int cdrom_empty() -{ - if (cdrom_enabled) - { - atapi->exit(); - cdrom_drive = -1; - cdrom_null_open(cdrom_drive); - return D_O_K; - } - - if (alert("This will reset PCem!", "Okay to continue?", NULL, "OK", "Cancel", 0, 0) == 1) - { - cdrom_drive = -1; - cdrom_enabled = 1; - cdrom_null_open(cdrom_drive); - saveconfig(NULL); - resetpchard(); - cdrom_update(); - } - - return D_O_K; -} - -static int cdrom_dev() -{ - if (cdrom_enabled) - { - atapi->exit(); - cdrom_drive = 1; - ioctl_open(cdrom_drive); - return D_O_K; - } - - if (alert("This will reset PCem!", "Okay to continue?", NULL, "OK", "Cancel", 0, 0) == 1) - { - cdrom_drive = 1; - cdrom_enabled = 1; - ioctl_open(cdrom_drive); - saveconfig(NULL); - resetpchard(); - cdrom_update(); - } - - return D_O_K; -} - -static int cdrom_image() -{ - char fn[260]; - int ret; - int xsize = SCREEN_W - 32, ysize = SCREEN_H - 64; - - strcpy(fn, image_path); - ret = file_select_ex("Please choose an image image", fn, "ISO;CUE", 260, xsize, ysize); - if (ret) - { - if (!cdrom_enabled) - { - if (alert("This will reset PCem!", "Okay to continue?", NULL, "OK", "Cancel", 0, 0) != 1) - return D_O_K; - } - else - { - atapi->exit(); - } - - cdrom_drive = CDROM_IMAGE; - image_open(fn); - if (!cdrom_enabled) - { - cdrom_enabled = 1; - resetpchard(); - } - cdrom_update(); - saveconfig(NULL); - } - return D_O_K; -} - -static MENU cdrom_menu[] = -{ - {"&Disabled", cdrom_disabled, NULL, 0, NULL}, - {"&Empty", cdrom_empty, NULL, 0, NULL}, - {"/dev/cdrom", cdrom_dev, NULL, 0, NULL}, - {"&Image...", cdrom_image, NULL, 0, NULL}, - {NULL,NULL,NULL,0,NULL} -}; - -static MENU settings_menu[]= -{ - {"&Configure...", settings_configure, NULL, 0, NULL}, - {"CD-ROM", NULL, cdrom_menu, 0, NULL}, - {NULL,NULL,NULL,0,NULL} -}; - -static MENU main_menu[]= -{ - {"&File", NULL, file_menu, 0, NULL}, - {"&Disc", NULL, disc_menu, 0, NULL}, - {"&Settings", NULL, settings_menu, 0, NULL}, - {NULL,NULL,NULL,0,NULL} -}; - -static DIALOG pcem_gui[]= -{ - {d_menu_proc, 0, 0, 0, 0, 15, 0, 0, 0, 0, 0, main_menu, NULL, NULL}, - {d_yield_proc, 0, 0, 0, 0, 15, 0, 0, 0, 0, 0, NULL, NULL, NULL}, - {0,0,0,0,0,0,0,0,0,0,0,NULL,NULL,NULL} -}; - -void gui_enter() -{ - DIALOG_PLAYER *dp; - int x = 1; - infocus = 0; - - dp = init_dialog(pcem_gui, 0); - show_mouse(screen); - while (x && !(mouse_b & 2) && !key[KEY_ESC]) - { - x = update_dialog(dp); - } - show_mouse(NULL); - shutdown_dialog(dp); - - clear(screen); - clear_keybuf(); - - infocus = 1; - - device_force_redraw(); -} diff --git a/src/allegro-gui.h b/src/allegro-gui.h deleted file mode 100644 index 2c98f82..0000000 --- a/src/allegro-gui.h +++ /dev/null @@ -1,15 +0,0 @@ -void gui_enter(); - -extern int quited; - -extern int romspresent[ROM_MAX]; -extern int gfx_present[GFX_MAX]; - -int disc_hdconf(); - -int settings_configure(); - -void deviceconfig_open(device_t *device); -int config_sel(); - -extern int has_been_inited; diff --git a/src/allegro-joystick.c b/src/allegro-joystick.c deleted file mode 100644 index 953399a..0000000 --- a/src/allegro-joystick.c +++ /dev/null @@ -1,49 +0,0 @@ -#include "allegro-main.h" -#include "plat-joystick.h" -#include "device.h" -#include "gameport.h" - -plat_joystick_t plat_joystick_state[MAX_PLAT_JOYSTICKS]; -joystick_t joystick_state[MAX_JOYSTICKS]; - -int joysticks_present; - -void joystick_init() -{ - install_joystick(JOY_TYPE_AUTODETECT); - joysticks_present = num_joysticks; -} -void joystick_close() -{ -} -void joystick_poll() -{ - int c, d; - - poll_joystick(); - - for (c = 0; c < num_joysticks; c++) - { - plat_joystick_state[c].a[0] = joy[c].stick[0].axis[0].pos * 256; - plat_joystick_state[c].a[1] = joy[c].stick[0].axis[1].pos * 256; - for (d = 0; d < MAX_JOYSTICK_BUTTONS; d++) - plat_joystick_state[c].b[d] = joy[c].button[d].b; - } - for (c = 0; c < joystick_get_max_joysticks(joystick_type); c++) - { - if (c < num_joysticks) - { - for (d = 0; d < joystick_get_axis_count(joystick_type); d++) - joystick_state[c].axis[d] = plat_joystick_state[c].a[d]; - for (d = 0; d < joystick_get_button_count(joystick_type); d++) - joystick_state[c].button[d] = plat_joystick_state[c].b[d]; - } - else - { - for (d = 0; d < joystick_get_axis_count(joystick_type); d++) - joystick_state[c].axis[d] = 0; - for (d = 0; d < joystick_get_button_count(joystick_type); d++) - joystick_state[c].button[d] = 0; - } - } -} diff --git a/src/allegro-keyboard.c b/src/allegro-keyboard.c deleted file mode 100644 index 335f842..0000000 --- a/src/allegro-keyboard.c +++ /dev/null @@ -1,49 +0,0 @@ -#include "allegro-main.h" -#include "plat-keyboard.h" - -int pcem_key[272]; -int rawinputkey[272]; - -static int key_convert[128] = -{ - -1, 0x1e, 0x30, 0x2e, 0x20, 0x12, 0x21, 0x22, /* , A, B, C, D, E, F, G*/ - 0x23, 0x17, 0x24, 0x25, 0x26, 0x32, 0x31, 0x18, /* H, I, J, K, L, M, N, O*/ - 0x19, 0x10, 0x13, 0x1f, 0x14, 0x16, 0x2f, 0x11, /* P, Q, R, S, T, U, V, W*/ - 0x2d, 0x15, 0x2c, 0x0b, 0x02, 0x03, 0x04, 0x05, /* X, Y, Z, 0, 1, 2, 3, 4*/ - 0x06, 0x07, 0x08, 0x09, 0x0a, 0x52, 0x4f, 0x50, /* 5, 6, 7, 8, 9, p0, p1, p2*/ - 0x51, 0x4b, 0x4c, 0x4d, 0x47, 0x48, 0x49, 0x3b, /* p3, p4, p5, p6, p7, p8, p9, F1*/ - 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, /* F2, F3, F4, F5, F6, F7, F8, F9*/ - 0x44, 0x57, 0x58, 0x01, 0x29, 0x0c, 0x0d, 0x0e, /*F10, F11, F12, ESC, `ª, -_, =+, backspace*/ - 0x0f, 0x1a, 0x1b, 0x1c, 0x27, 0x28, 0x2b, 0x56, /*TAB, [{, ]}, ENT, ;:, '@, \|, #~*/ - 0x33, 0x34, 0x35, 0x39, 0xd2, 0xd3, 0xc7, 0xcf, /* ,<, .>, /?, SPC, INS, DEL, HOME, END*/ - 0xc9, 0xd1, 0xcb, 0xcd, 0xc8, 0xd0, 0xb5, 0x37, /*PGU, PGD, LFT, RHT, UP, DN, /, * */ - 0x4a, 0x4e, 0x53, 0x9c, 0xff, -1, -1, -1, /* p-, p+, pDL, pEN, psc, pse, abnt, yen*/ - -1, -1, -1, -1, -1, -1, -1, -1, /*kana, convert, noconvert, at, circumflex, colon2, kanji, pad equals*/ - -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 0x2a, 0x36, 0x1d, 0x9d, 0x38, /*, , lshift, rshift, lctrl, rctrl, alt*/ - 0xb8, 0xdb, 0xdc, 0xdd, 0x46, 0x45, 0x3a, -1 /*altgr, lwin, rwin, menu, scrlock, numlock, capslock*/ -}; - -void keyboard_init() -{ - install_keyboard(); -} - -void keyboard_close() -{ -} - -void keyboard_poll_host() -{ - int c; - - for (c = 0; c < 128; c++) - { - int key_idx = key_convert[c]; - if (key_idx == -1) - continue; - - if (key[c] != pcem_key[key_idx]) - pcem_key[key_idx] = key[c]; - } -} diff --git a/src/allegro-main.c b/src/allegro-main.c deleted file mode 100644 index 2d60650..0000000 --- a/src/allegro-main.c +++ /dev/null @@ -1,280 +0,0 @@ -#include "ibm.h" -#include "device.h" -#include "allegro-gui.h" -#include "allegro-main.h" -#include "allegro-video.h" -#include "config.h" -#include "cpu.h" -#include "mem.h" -#include "model.h" -#include "nvr.h" -#include "plat-joystick.h" -#include "plat-keyboard.h" -#include "plat-midi.h" -#include "plat-mouse.h" -#include "sound.h" -#include "video.h" -#include -#include -#include -#include -#include -#include "paths.h" - - #undef printf - -int has_been_inited = 0; - -int mousecapture = 0; -int quited = 0; -int winsizex = -1, winsizey = -1; - -int romspresent[ROM_MAX]; -int gfx_present[GFX_MAX]; - -void updatewindowsize(int x, int y) -{ - if (x < 128) - x = 128; - if (y < 128) - y = 128; - if (winsizex != x || winsizey != y) - { - winsizex = x; - winsizey = y; - allegro_video_update_size(x, y); - } -} - -void startblit() -{ -} - -void endblit() -{ -} - -static int ticks = 0; -static void timer_rout() -{ - ticks++; -} - -uint64_t timer_freq; -uint64_t timer_read() -{ - return 0; -} - -int dir_exists(char *path) -{ - DIR *dir = opendir(path); - if (dir) - { - closedir(dir); - return 1; - } - return 0; -} - -int create_dir(char *path) -{ - if (!mkdir(path, 0755)) - return 1; - return 0; -} - -void get_pcem_path(char *s, int size) -{ - struct passwd *pw = getpwuid(getuid()); - - strncpy(s, pw->pw_dir, size-10); - append_slash(s, size); - strcat(s, ".pcem/"); - //get_executable_name(s, size); -} - -int main(int argc, char *argv[]) -{ - char s[512]; - int frames = 0; - int c; - FILE *f; - - allegro_init(); - allegro_video_init(); - install_timer(); - install_int_ex(timer_rout, BPS_TO_TIMER(100)); - install_int_ex(onesec, BPS_TO_TIMER(1)); - midi_init(); - - paths_init(); - - /* create directories if they don't exist */ - if (!dir_exists(pcem_path)) { - if (!create_dir(pcem_path)) - return 0; - append_filename(s, pcem_path, "configs", 511); - if (!dir_exists(s) && !create_dir(s)) - return 0; - - append_filename(s, pcem_path, "roms", 511); - if (!dir_exists(s) && !create_dir(s)) - return 0; - - append_filename(s, pcem_path, "nvr", 511); - if (!dir_exists(s) && !create_dir(s)) - return 0; - - append_filename(s, pcem_path, "logs", 511); - if (!dir_exists(s) && !create_dir(s)) - return 0; - } - - /* set up default paths */ - sprintf(s, "%s%s%c%s", pcem_path, "roms/", get_path_separator(), "/usr/share/pcem/roms/"); - set_default_roms_paths(s); - append_filename(s, pcem_path, "nvr/", 511); - set_default_nvr_path(s); - append_filename(s, pcem_path, "configs/", 511); - set_default_configs_path(s); - append_filename(s, pcem_path, "logs/", 511); - set_default_logs_path(s); - - sound_init(); - - initpc(argc, argv); - - /* check if cfg exists, and if not create it */ - append_filename(s, pcem_path, "pcem.cfg", 511); - f = fopen(s, "r"); - if (f) - fclose(f); - else - saveconfig(NULL); - - keyboard_init(); - mouse_init(); - joystick_init(); - - for (c = 0; c < ROM_MAX; c++) - { - romset = c; - romspresent[c] = loadbios(); - pclog("romset %i - %i\n", c, romspresent[c]); - } - - for (c = 0; c < ROM_MAX; c++) - { - if (romspresent[c]) - break; - } - if (c == ROM_MAX) - { - printf("No ROMs present!\nYou must have at least one romset to use PCem."); - return 0; - } - - for (c = 0; c < GFX_MAX; c++) - gfx_present[c] = video_card_available(video_old_to_new(c)); - - while (1) - { - has_been_inited = 0; - if (config_sel()) - return 0; - has_been_inited = 1; - - quited = 0; - - loadconfig(NULL); - - c=loadbios(); - - if (!c) - { - if (romset != -1) - printf("Configured romset not available.\nDefaulting to available romset."); - for (c = 0; c < ROM_MAX; c++) - { - if (romspresent[c]) - { - romset = c; - model = model_getmodel(romset); - saveconfig(NULL); - resetpchard(); - break; - } - } - } - - if (!video_card_available(video_old_to_new(gfxcard))) - { - if (gfxcard) printf("Configured video BIOS not available.\nDefaulting to available romset."); - for (c = GFX_MAX-1; c >= 0; c--) - { - if (gfx_present[c]) - { - gfxcard = c; - saveconfig(NULL); - resetpchard(); - break; - } - } - } - - resetpchard(); - - ticks = 0; - while (!quited) - { - if (ticks) - { - ticks--; - runpc(); - frames++; - if (frames >= 200 && nvr_dosave) - { - frames = 0; - nvr_dosave = 0; - savenvr(); - } - } - else - rest(1); - - if (ticks > 10) - ticks = 0; - - if ((mouse_b & 1) && !mousecapture) - mousecapture = 1; - - if (((key[KEY_LCONTROL] || key[KEY_RCONTROL]) && key[KEY_END]) || (mouse_b & 4)) - mousecapture = 0; - - if ((key[KEY_LCONTROL] || key[KEY_RCONTROL]) && key[KEY_ALT] && key[KEY_PGDN]) - { - int old_winsizex = winsizex, old_winsizey = winsizey; - if (winsizex < 512 || winsizey < 350) - updatewindowsize(512, 350); - gui_enter(); - if (old_winsizex < 512 || old_winsizey < 350) - updatewindowsize(old_winsizex, old_winsizey); - ticks = 0; - } - } - - savenvr(); - } - - closepc(); - - joystick_close(); - mouse_close(); - keyboard_close(); - midi_close(); - - return 0; -} - -END_OF_MAIN(); diff --git a/src/allegro-main.h b/src/allegro-main.h deleted file mode 100644 index ba96a4f..0000000 --- a/src/allegro-main.h +++ /dev/null @@ -1,19 +0,0 @@ -#define getr8 allegro_getr8 -#define setr8 allegro_setr8 -#define get_filename allegro_get_filename -#define append_filename allegro_append_filename -#define put_backslash allegro_put_backslash -#define get_extension allegro_get_extension -#define GFX_VGA allegro_GFX_VGA -#define MAX_JOYSTICKS allegro_MAX_JOYSTICKS - -#include - -#undef MAX_JOYSTICKS -#undef GFX_VGA -#undef getr8 -#undef setr8 -#undef get_filename -#undef append_filename -#undef put_backslash -#undef get_extension diff --git a/src/allegro-midi.c b/src/allegro-midi.c deleted file mode 100644 index b491db1..0000000 --- a/src/allegro-midi.c +++ /dev/null @@ -1,45 +0,0 @@ -#include "allegro-main.h" -#include "ibm.h" -#include "plat-midi.h" - -//#define USE_ALLEGRO_MIDI - -void midi_init() -{ -#ifdef USE_ALLEGRO_MIDI - install_sound(DIGI_NONE, MIDI_AUTODETECT, NULL); -#endif -} - -void midi_close() -{ -#ifdef USE_ALLEGRO_MIDI - remove_sound(); -#endif -} - -static int midi_cmd_pos, midi_len; -static uint8_t midi_command[3]; -static int midi_lengths[8] = {3, 3, 3, 3, 2, 2, 3, 0}; - -void midi_write(uint8_t val) -{ - if (val & 0x80) - { - midi_cmd_pos = 0; - midi_len = midi_lengths[(val >> 4) & 7]; - midi_command[0] = midi_command[1] = midi_command[2] = 0; - } - - if (midi_len && midi_cmd_pos < 3) - { - midi_command[midi_cmd_pos] = val; - - midi_cmd_pos++; - -#ifdef USE_ALLEGRO_MIDI - if (midi_cmd_pos == midi_len) - midi_out(midi_command, midi_len); -#endif - } -} diff --git a/src/allegro-mouse.c b/src/allegro-mouse.c deleted file mode 100644 index 9cceaa9..0000000 --- a/src/allegro-mouse.c +++ /dev/null @@ -1,32 +0,0 @@ -#include "allegro-main.h" -#include "plat-mouse.h" - -int mouse_buttons; - -void mouse_init() -{ - install_mouse(); -} - -void mouse_close() -{ -} - -void mouse_poll_host() -{ - //poll_mouse(); - mouse_buttons = mouse_b; -} - -void mouse_get_mickeys(int *x, int *y, int *z) -{ - if (mousecapture) - { - get_mouse_mickeys(x, y); - *z = 0; -// position_mouse(64, 64); - } - else - *x = *y = *z = 0; -} - diff --git a/src/allegro-video.c b/src/allegro-video.c deleted file mode 100644 index 694f586..0000000 --- a/src/allegro-video.c +++ /dev/null @@ -1,53 +0,0 @@ -#include "allegro-main.h" -#include "ibm.h" -#include "video.h" - -#include "allegro-video.h" - -static void allegro_blit_memtoscreen(int x, int y, int y1, int y2, int w, int h); -static BITMAP *buffer32_vscale; -void allegro_video_init() -{ - set_color_depth(32); - set_gfx_mode(GFX_AUTODETECT_WINDOWED, 640, 480, 0, 0); - video_blit_memtoscreen_func = allegro_blit_memtoscreen; - - buffer32_vscale = create_bitmap(2048, 2048); -} - -void allegro_video_close() -{ - destroy_bitmap(buffer32_vscale); -} - -void allegro_video_update_size(int x, int y) -{ - if (set_gfx_mode(GFX_AUTODETECT_WINDOWED, x, y, 0, 0)) - fatal("Failed to set gfx mode %i,%i : %s\n", x, y, allegro_error); -} - -static void allegro_blit_memtoscreen(int x, int y, int y1, int y2, int w, int h) -{ - if (h < winsizey) - { - int yy; - - for (yy = y+y1; yy < y+y2; yy++) - { - if (yy >= 0) - { - memcpy(&((uint32_t *)buffer32_vscale->line[yy*2])[x], &((uint32_t *)buffer32->line[yy])[x], w*4); - memcpy(&((uint32_t *)buffer32_vscale->line[(yy*2)+1])[x], &((uint32_t *)buffer32->line[yy])[x], w*4); - } - } - - video_blit_complete(); - blit(buffer32_vscale, screen, x, (y+y1)*2, 0, y1, w, (y2-y1)*2); - } - else - { - blit(buffer32, screen, x, y+y1, 0, y1, w, y2-y1); - video_blit_complete(); - } -} - diff --git a/src/allegro-video.h b/src/allegro-video.h deleted file mode 100644 index e82419a..0000000 --- a/src/allegro-video.h +++ /dev/null @@ -1,3 +0,0 @@ -void allegro_video_init(); -void allegro_video_close(); -void allegro_video_update_size(int x, int y); diff --git a/src/pc.c b/src/pc.c index 0afa2da..eb487dd 100644 --- a/src/pc.c +++ b/src/pc.c @@ -233,7 +233,6 @@ void initpc(int argc, char *argv[]) //char *p; // char *config_file = NULL; int c; -// allegro_init(); for (c = 1; c < argc; c++) { diff --git a/src/video.h b/src/video.h index e301dcb..f4ca12a 100644 --- a/src/video.h +++ b/src/video.h @@ -1,11 +1,3 @@ -#ifdef PCEM_ALLEGRO - -#undef MAX_JOYSTICKS -#include "allegro-main.h" -#define MAX_JOYSTICKS 4 - -#else - typedef struct { int w, h; @@ -27,8 +19,6 @@ typedef RGB PALETTE[256]; #define makecol(r, g, b) ((b) | ((g) << 8) | ((r) << 16)) #define makecol32(r, g, b) ((b) | ((g) << 8) | ((r) << 16)) -#endif - extern BITMAP *buffer32; int video_card_available(int card);