diff --git a/BasiliskII/src/CrossPlatform/vm_alloc.h b/BasiliskII/src/CrossPlatform/vm_alloc.h index bc5aba97..9f9d28bb 100644 --- a/BasiliskII/src/CrossPlatform/vm_alloc.h +++ b/BasiliskII/src/CrossPlatform/vm_alloc.h @@ -101,6 +101,8 @@ extern void * vm_acquire(size_t size, int options = VM_MAP_DEFAULT); extern void * vm_acquire_reserved(size_t size); +extern int vm_init_reserved(void * host_address); + /* Allocate zero-filled memory at exactly ADDR (which must be page-aligned). Returns 0 if successful, -1 on errors. */ diff --git a/BasiliskII/src/MacOSX/utils_macosx.h b/BasiliskII/src/MacOSX/utils_macosx.h index 0b7bb0c8..e37d687c 100644 --- a/BasiliskII/src/MacOSX/utils_macosx.h +++ b/BasiliskII/src/MacOSX/utils_macosx.h @@ -24,6 +24,17 @@ // Invokes the specified function with an NSAutoReleasePool in place. void NSAutoReleasePool_wrap(void (*fn)(void)); +#ifdef USE_SDL +#if SDL_VERSION_ATLEAST(2,0,0) +void disable_SDL2_macosx_menu_bar_keyboard_shortcuts(); +bool is_fullscreen_osx(SDL_Window * window); +#endif +#endif + +void set_menu_bar_visible_osx(bool visible); + +void set_current_directory(); + bool MetalIsAvailable(); #endif diff --git a/BasiliskII/src/MacOSX/utils_macosx.mm b/BasiliskII/src/MacOSX/utils_macosx.mm index 9dbcff69..3c61bfe8 100644 --- a/BasiliskII/src/MacOSX/utils_macosx.mm +++ b/BasiliskII/src/MacOSX/utils_macosx.mm @@ -20,8 +20,8 @@ #include #include "sysdeps.h" -#include "utils_macosx.h" #include +#include "utils_macosx.h" #if SDL_VERSION_ATLEAST(2,0,0) #include diff --git a/BasiliskII/src/SDL/video_sdl2.cpp b/BasiliskII/src/SDL/video_sdl2.cpp index 27a52e2f..907b9175 100644 --- a/BasiliskII/src/SDL/video_sdl2.cpp +++ b/BasiliskII/src/SDL/video_sdl2.cpp @@ -1718,7 +1718,6 @@ static bool is_fullscreen(SDL_Window * window) // involves fullscreen/windowed toggles via window-manager UI controls). // Until it does, or adds a facility to do so, we'll use a platform-specific // code path to detect fullscreen changes. - extern bool is_fullscreen_osx(SDL_Window * window); return is_fullscreen_osx(sdl_window); #else if (!window) { @@ -2272,7 +2271,6 @@ static int SDLCALL on_sdl_event_generated(void *userdata, SDL_Event * event) // cursor is near the top of the screen, lest the // guest OS' menu bar be obscured. if (is_full) { - extern void set_menu_bar_visible_osx(bool); set_menu_bar_visible_osx(false); } #endif diff --git a/BasiliskII/src/Unix/main_unix.cpp b/BasiliskII/src/Unix/main_unix.cpp index 7f4974fd..3706f7f9 100755 --- a/BasiliskII/src/Unix/main_unix.cpp +++ b/BasiliskII/src/Unix/main_unix.cpp @@ -43,6 +43,10 @@ # include #endif +#if __MACOSX__ +# include "utils_macosx.h" +#endif + #if !EMULATED_68K && defined(__NetBSD__) # include # include @@ -579,7 +583,6 @@ int main(int argc, char **argv) // // HACK: disable these shortcuts, while leaving all other pieces of SDL2's // menu bar in-place. - extern void disable_SDL2_macosx_menu_bar_keyboard_shortcuts(); disable_SDL2_macosx_menu_bar_keyboard_shortcuts(); #endif diff --git a/SheepShaver/src/Unix/main_unix.cpp b/SheepShaver/src/Unix/main_unix.cpp index 35ee28f8..e1e24ae8 100755 --- a/SheepShaver/src/Unix/main_unix.cpp +++ b/SheepShaver/src/Unix/main_unix.cpp @@ -2217,8 +2217,6 @@ rti:; } #endif -extern int vm_init_reserved(void *hostAddress); - /* * Helpers to share 32-bit addressable data with MacOS */