From ee0afec78730f256021a70f8699009d41842201a Mon Sep 17 00:00:00 2001 From: Dwedit Date: Fri, 6 Apr 2018 20:08:18 -0500 Subject: [PATCH 1/2] Fix build errors on machines without HAVE_DYNAMIC --- runahead/run_ahead.c | 7 ++++++- runahead/secondary_core.c | 5 ++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/runahead/run_ahead.c b/runahead/run_ahead.c index a3a1cf5a87..2e039b24f6 100644 --- a/runahead/run_ahead.c +++ b/runahead/run_ahead.c @@ -203,6 +203,11 @@ void run_ahead(int runAheadCount, bool useSecondary) bool okay; bool lastFrame; bool suspendedFrame; +#if defined(HAVE_DYNAMIC) && HAVE_DYNAMIC + const bool haveDynamic = true; +#else + const bool haveDynamic = false; +#endif if (runAheadCount <= 0 || !runahead_available) { @@ -224,7 +229,7 @@ void run_ahead(int runAheadCount, bool useSecondary) runahead_check_for_gui(); - if (!useSecondary || !HAVE_DYNAMIC || !runahead_secondary_core_available) + if (!useSecondary || !haveDynamic || !runahead_secondary_core_available) { /* TODO: multiple savestates for higher performance when not using secondary core */ for (frameNumber = 0; frameNumber <= runAheadCount; frameNumber++) diff --git a/runahead/secondary_core.c b/runahead/secondary_core.c index 65e04b2bf9..efdd338463 100644 --- a/runahead/secondary_core.c +++ b/runahead/secondary_core.c @@ -379,6 +379,9 @@ void secondary_core_set_variable_update(void) { /* do nothing */ } - +void clear_controller_port_map(void) +{ + /* do nothing */ +} #endif From cb74af60c9efccc90a3cbf1e4ee1e490e90903f2 Mon Sep 17 00:00:00 2001 From: Dwedit Date: Fri, 6 Apr 2018 20:14:29 -0500 Subject: [PATCH 2/2] one line typo --- runahead/run_ahead.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runahead/run_ahead.c b/runahead/run_ahead.c index 2e039b24f6..e03eb23571 100644 --- a/runahead/run_ahead.c +++ b/runahead/run_ahead.c @@ -203,7 +203,7 @@ void run_ahead(int runAheadCount, bool useSecondary) bool okay; bool lastFrame; bool suspendedFrame; -#if defined(HAVE_DYNAMIC) && HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) || defined(HAVE_DYLIB) const bool haveDynamic = true; #else const bool haveDynamic = false;