- updated override-ask example
- fixed path in user plugin example
This commit is contained in:
parent
b433f4072b
commit
679f980b39
@ -9,54 +9,57 @@ This patch shows how to create your own siminterface callback function.
|
||||
It is not intended to be checked in anytime, only to serve as an example
|
||||
of how to use the siminterface.
|
||||
|
||||
Patch updated for current CVS. (Volker Ruppert, Oct 16, 2005)
|
||||
Patch updated for current SVN. (Volker Ruppert, Apr 15, 2012)
|
||||
|
||||
Patch was created with:
|
||||
diff -u
|
||||
Apply patch to what version:
|
||||
cvs checked out on DATE
|
||||
svn checked out on DATE
|
||||
Instructions:
|
||||
To patch, go to main bochs directory.
|
||||
Type "patch -p1 < THIS_PATCH_FILE".
|
||||
Type "patch -p0 < THIS_PATCH_FILE".
|
||||
----------------------------------------------------------------------
|
||||
--- bochs/config.h.in 2005-10-13 20:40:50.131262080 +0200
|
||||
+++ bochs-overrideask/config.h.in 2005-10-13 20:44:40.841188840 +0200
|
||||
@@ -949,6 +949,9 @@
|
||||
// External Debugger
|
||||
#define BX_EXTERNAL_DEBUGGER 0
|
||||
diff -urN ../bochs/config.h.in ./config.h.in
|
||||
--- ../bochs/config.h.in 2012-01-26 17:34:41.603286662 +0100
|
||||
+++ ./config.h.in 2012-04-15 14:29:36.529504219 +0200
|
||||
@@ -858,6 +858,9 @@
|
||||
// I/O Interface to debugger
|
||||
#define BX_SUPPORT_IODEBUG 0
|
||||
|
||||
+// Override ask dialog (demo)
|
||||
+#define BX_OVERRIDE_ASK_EXAMPLE 1
|
||||
+
|
||||
// Magic breakpoints
|
||||
#define BX_MAGIC_BREAKPOINT 1
|
||||
|
||||
--- bochs/gui/textconfig.cc 2005-06-06 22:14:50.000000000 +0200
|
||||
+++ bochs-overrideask/gui/textconfig.cc 2005-10-13 20:12:16.090835832 +0200
|
||||
@@ -996,6 +996,10 @@
|
||||
#ifdef WIN32
|
||||
#define BX_FLOPPY0_NAME "Floppy Disk A:"
|
||||
#define BX_FLOPPY1_NAME "Floppy Disk B:"
|
||||
diff -urN ../bochs/gui/textconfig.cc ./gui/textconfig.cc
|
||||
--- ../bochs/gui/textconfig.cc 2012-04-06 15:15:28.094038820 +0200
|
||||
+++ ./gui/textconfig.cc 2012-04-15 14:31:30.538122593 +0200
|
||||
@@ -1075,6 +1075,10 @@
|
||||
{
|
||||
case CI_START:
|
||||
//fprintf (stderr, "textconfig.cc: start\n");
|
||||
bx_config_interface_init ();
|
||||
bx_config_interface_init();
|
||||
+#if BX_OVERRIDE_ASK_EXAMPLE
|
||||
+ extern void override_ask_init();
|
||||
+ override_ask_init ();
|
||||
+ override_ask_init();
|
||||
+#endif
|
||||
if (SIM->get_param_enum(BXP_BOCHS_START)->get () == BX_QUICK_START)
|
||||
bx_config_interface (BX_CI_START_SIMULATION);
|
||||
if (SIM->get_param_enum(BXPN_BOCHS_START)->get() == BX_QUICK_START)
|
||||
bx_config_interface(BX_CI_START_SIMULATION);
|
||||
else {
|
||||
diff -urN bochs/Makefile.in bochs-overrideask/Makefile.in
|
||||
--- bochs/Makefile.in 2005-07-30 17:02:40.000000000 +0200
|
||||
+++ bochs-overrideask/Makefile.in 2005-10-13 20:04:06.137320088 +0200
|
||||
@@ -146,6 +146,7 @@
|
||||
pc_system.o \
|
||||
diff -urN ../bochs/Makefile.in ./Makefile.in
|
||||
--- ../bochs/Makefile.in 2012-04-11 18:52:41.715215121 +0200
|
||||
+++ ./Makefile.in 2012-04-15 14:29:36.530504215 +0200
|
||||
@@ -141,6 +141,7 @@
|
||||
osdep.o \
|
||||
plugin.o \
|
||||
crc.o \
|
||||
+ overrideask.o \
|
||||
@EXTRA_BX_OBJS@
|
||||
|
||||
EXTERN_ENVIRONMENT_OBJS = \
|
||||
--- bochs/overrideask.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ bochs-overrideask/overrideask.cc 2005-10-13 20:15:25.713008880 +0200
|
||||
diff -urN ../bochs/overrideask.cc ./overrideask.cc
|
||||
--- ../bochs/overrideask.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ ./overrideask.cc 2012-04-15 14:29:36.531504211 +0200
|
||||
@@ -0,0 +1,52 @@
|
||||
+#include <stdio.h>
|
||||
+#include <assert.h>
|
||||
|
@ -30,8 +30,8 @@ Instructions:
|
||||
make
|
||||
make install
|
||||
----------------------------------------------------------------------
|
||||
diff -urN ../bochs/bochs/configure.in ./configure.in
|
||||
--- ../bochs/bochs/configure.in 2012-04-11 18:53:04.078087998 +0200
|
||||
diff -urN ../bochs/configure.in ./configure.in
|
||||
--- ../bochs/configure.in 2012-04-11 18:53:04.078087998 +0200
|
||||
+++ ./configure.in 2012-04-14 16:18:03.046503743 +0200
|
||||
@@ -2787,4 +2787,4 @@
|
||||
doc/docbook/Makefile build/linux/bochs-dlx \
|
||||
@ -39,8 +39,8 @@ diff -urN ../bochs/bochs/configure.in ./configure.in
|
||||
build/win32/nsis/Makefile build/win32/nsis/bochs.nsi \
|
||||
- host/linux/pcidev/Makefile)
|
||||
+ host/linux/pcidev/Makefile user-plugin/Makefile)
|
||||
diff -urN ../bochs/bochs/user-plugin/Makefile.in ./user-plugin/Makefile.in
|
||||
--- ../bochs/bochs/user-plugin/Makefile.in 1970-01-01 01:00:00.000000000 +0100
|
||||
diff -urN ../bochs/user-plugin/Makefile.in ./user-plugin/Makefile.in
|
||||
--- ../bochs/user-plugin/Makefile.in 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ ./user-plugin/Makefile.in 2012-04-14 16:18:03.046503743 +0200
|
||||
@@ -0,0 +1,108 @@
|
||||
+# Copyright (C) 2009-2012 Volker Ruppert
|
||||
@ -151,8 +151,8 @@ diff -urN ../bochs/bochs/user-plugin/Makefile.in ./user-plugin/Makefile.in
|
||||
+ ../gui/siminterface.h ../memory/memory.h ../pc_system.h ../plugin.h \
|
||||
+ ../extplugin.h ../ltdl.h ../gui/gui.h ../gui/textconfig.h \
|
||||
+ ../gui/keymap.h ../instrument/stubs/instrument.h testdev.h
|
||||
diff -urN ../bochs/bochs/user-plugin/testdev.cc ./user-plugin/testdev.cc
|
||||
--- ../bochs/bochs/user-plugin/testdev.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
diff -urN ../bochs/user-plugin/testdev.cc ./user-plugin/testdev.cc
|
||||
--- ../bochs/user-plugin/testdev.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ ./user-plugin/testdev.cc 2012-04-14 16:30:28.849027414 +0200
|
||||
@@ -0,0 +1,118 @@
|
||||
+// Copyright (C) 2009-2012 Volker Ruppert
|
||||
@ -273,8 +273,8 @@ diff -urN ../bochs/bochs/user-plugin/testdev.cc ./user-plugin/testdev.cc
|
||||
+
|
||||
+ BX_USER_THIS s.reg0 = value;
|
||||
+}
|
||||
diff -urN ../bochs/bochs/user-plugin/testdev.h ./user-plugin/testdev.h
|
||||
--- ../bochs/bochs/user-plugin/testdev.h 1970-01-01 01:00:00.000000000 +0100
|
||||
diff -urN ../bochs/user-plugin/testdev.h ./user-plugin/testdev.h
|
||||
--- ../bochs/user-plugin/testdev.h 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ ./user-plugin/testdev.h 2012-04-14 16:19:30.538406315 +0200
|
||||
@@ -0,0 +1,40 @@
|
||||
+// Copyright (C) 2009-2012 Volker Ruppert
|
||||
|
Loading…
x
Reference in New Issue
Block a user