From: Frode Solheim Date: Tue, 29 Jul 2014 19:52:07 +0000 (+0200) Subject: a2065: compilation fix X-Git-Tag: 3000~102^2 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=35e759888bcedc61d74edc0c05136313cbee999b;p=francis%2Fwinuae.git a2065: compilation fix --- diff --git a/a2065.cpp b/a2065.cpp index 156e7449..d554e308 100644 --- a/a2065.cpp +++ b/a2065.cpp @@ -828,7 +828,14 @@ static void REGPARAM2 a2065_lput (uaecptr addr, uae_u32 l) a2065_wput (addr + 2, l); } -extern addrbank a2065_bank; +DECLARE_MEMORY_FUNCTIONS(a2065); + +static addrbank a2065_bank = { + a2065_lget, a2065_wget, a2065_bget, + a2065_lput, a2065_wput, a2065_bput, + default_xlate, default_check, NULL, _T("A2065 Z2 Ethernet"), + a2065_lgeti, a2065_wgeti, ABFLAG_IO +}; static void REGPARAM2 a2065_bput (uaecptr addr, uae_u32 b) { @@ -877,13 +884,6 @@ static uae_u32 REGPARAM2 a2065_lgeti (uaecptr addr) return v; } -static addrbank a2065_bank = { - a2065_lget, a2065_wget, a2065_bget, - a2065_lput, a2065_wput, a2065_bput, - default_xlate, default_check, NULL, _T("A2065 Z2 Ethernet"), - a2065_lgeti, a2065_wgeti, ABFLAG_IO -}; - static addrbank *a2065_config (void) { memset (config, 0xff, sizeof config); diff --git a/include/memory.h b/include/memory.h index efb1b4b0..08d5fdc5 100644 --- a/include/memory.h +++ b/include/memory.h @@ -89,7 +89,7 @@ typedef struct { ourselves. This holds the memory address where the start of memory is for this particular bank. */ uae_u8 *baseaddr; - TCHAR *name; + const TCHAR *name; /* for instruction opcode/operand fetches */ mem_get_func lgeti, wgeti; int flags; @@ -262,7 +262,9 @@ static uae_u8 *REGPARAM2 name ## _xlate (uaecptr addr) \ #define DECLARE_MEMORY_FUNCTIONS(name) \ static uae_u32 REGPARAM3 name ## _lget (uaecptr) REGPARAM; \ + static uae_u32 REGPARAM3 name ## _lgeti (uaecptr) REGPARAM; \ static uae_u32 REGPARAM3 name ## _wget (uaecptr) REGPARAM; \ + static uae_u32 REGPARAM3 name ## _wgeti (uaecptr) REGPARAM; \ static uae_u32 REGPARAM3 name ## _bget (uaecptr) REGPARAM; \ static void REGPARAM3 name ## _lput (uaecptr, uae_u32) REGPARAM; \ static void REGPARAM3 name ## _wput (uaecptr, uae_u32) REGPARAM; \