From 2e5654e583026b95b267b348fadcd4a4a8eabe43 Mon Sep 17 00:00:00 2001 From: kanjitalk755 Date: Fri, 26 Feb 2021 12:21:21 +0900 Subject: [PATCH] SS: can use cxmon --- SheepShaver/src/Unix/configure.ac | 9 +++++---- SheepShaver/src/kpx_cpu/ppc-dis.c | 5 +++++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/SheepShaver/src/Unix/configure.ac b/SheepShaver/src/Unix/configure.ac index 88a08c96..35f3495e 100755 --- a/SheepShaver/src/Unix/configure.ac +++ b/SheepShaver/src/Unix/configure.ac @@ -45,7 +45,7 @@ AC_ARG_WITH(gtk, [ --with-gtk use GTK user interface [d *) WANT_GTK="no";; esac], [WANT_GTK="gtk2 gtk"]) -AC_ARG_WITH(mon, [ --with-mon use mon as debugger [default=yes]], [WANT_MON=$withval], [WANT_MON=yes]) +AC_ARG_WITH(mon, [ --with-mon use mon as debugger [default=yes]], [WANT_MON=$withval], [WANT_MON=no]) AC_ARG_WITH(dgcc, [ --with-dgcc=COMPILER use C++ COMPILER to compile synthetic opcodes or 'precompiled'], [DYNGEN_CC=$withval]) AC_ARG_WITH(bincue, @@ -115,7 +115,7 @@ x/* | x.*) WANT_MON=yes ;; xyes) - mon_srcdir=../../../mon/src + mon_srcdir=../../../cxmon/src ;; esac if [[ "x$WANT_MON" = "xyes" ]]; then @@ -123,7 +123,7 @@ if [[ "x$WANT_MON" = "xyes" ]]; then if grep mon_init $mon_srcdir/mon.h >/dev/null 2>/dev/null; then AC_MSG_RESULT(yes) AC_DEFINE(ENABLE_MON, 1, [Define if using "mon".]) - MONSRCS="$mon_srcdir/mon.cpp $mon_srcdir/mon_6502.cpp $mon_srcdir/mon_z80.cpp $mon_srcdir/mon_cmd.cpp $mon_srcdir/mon_lowmem.cpp $mon_srcdir/mon_disass.cpp $mon_srcdir/mon_ppc.cpp $mon_srcdir/disass/floatformat.c $mon_srcdir/disass/i386-dis.c $mon_srcdir/disass/m68k-dis.c $mon_srcdir/disass/m68k-opc.c $mon_srcdir/disass/mips-dis.c $mon_srcdir/disass/mips-opc.c $mon_srcdir/disass/mips16-opc.c" + MONSRCS="$mon_srcdir/mon.cpp $mon_srcdir/mon_6502.cpp $mon_srcdir/mon_z80.cpp $mon_srcdir/mon_cmd.cpp $mon_srcdir/mon_lowmem.cpp $mon_srcdir/mon_disass.cpp $mon_srcdir/mon_ppc.cpp $mon_srcdir/disass/floatformat.c $mon_srcdir/disass/i386-dis.c $mon_srcdir/disass/m68k-dis.c $mon_srcdir/disass/m68k-opc.c" CXXFLAGS="$CXXFLAGS -I$mon_srcdir -I$mon_srcdir/disass" AC_CHECK_LIB(ncurses, tgetent, , [AC_CHECK_LIB(termcap, tgetent, , @@ -625,6 +625,7 @@ AC_CHECK_FRAMEWORK(CoreAudio, [#include ]) AC_CHECK_FRAMEWORK(AudioUnit, [#include ]) AC_CHECK_FRAMEWORK(AudioToolbox, [#include ]) AC_CHECK_FRAMEWORK(AppKit, []) +AC_CHECK_FRAMEWORK(Metal, []) dnl Select system-dependant sources. SERIALSRC=serial_unix.cpp @@ -1447,7 +1448,7 @@ gcc_AC_C_FLOAT_FORMAT dnl Platform specific binary postprocessor AC_PATH_PROG(BLESS, "true") if [[ "x$ac_cv_pagezero_hack" = "xyes" ]]; then - BLESS=Darwin/lowmem +# BLESS=Darwin/lowmem LDFLAGS="$LDFLAGS -pagezero_size 0x3000" fi diff --git a/SheepShaver/src/kpx_cpu/ppc-dis.c b/SheepShaver/src/kpx_cpu/ppc-dis.c index a2478e63..3c1fc9e3 100644 --- a/SheepShaver/src/kpx_cpu/ppc-dis.c +++ b/SheepShaver/src/kpx_cpu/ppc-dis.c @@ -23,6 +23,7 @@ see . */ #include #include "dis-asm.h" +#include "config.h" #define BFD_DEFAULT_TARGET_SIZE 64 @@ -5263,6 +5264,8 @@ bfd_vma bfd_getb32 (const bfd_byte *addr) return (bfd_vma) v; } +#if !ENABLE_MON + /* Get LENGTH bytes from info's buffer, at target address memaddr. Transfer them to myaddr. */ int @@ -5313,6 +5316,8 @@ generic_symbol_at_address (bfd_vma addr, struct disassemble_info *info) return 1; } +#endif // !ENABLE_MON + /* Print a PowerPC or POWER instruction. */ static int