forked from len0rd/rockbox
Accept FS#7264 'Build with -Os switch for coldfire targets'.
Introduces MEM_FUNCTION_WRAPPERS(api) macro which adds wrappers functions to a plugin to make plugins link correctly when gcc calls mem* functions directly. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13625 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
f50bd1151a
commit
c7f9ca4067
21 changed files with 105 additions and 29 deletions
|
@ -17,6 +17,7 @@
|
|||
*
|
||||
****************************************************************************/
|
||||
#include "plugin.h"
|
||||
#include "mem_function_wrappers.h"
|
||||
|
||||
PLUGIN_HEADER
|
||||
|
||||
|
@ -153,6 +154,7 @@ PLUGIN_HEADER
|
|||
it's nice not to have to pass the api pointer in all function calls
|
||||
in the plugin */
|
||||
static struct plugin_api* rb;
|
||||
MEM_FUNCTION_WRAPPERS(rb);
|
||||
#define MAX_PLAYERS 10
|
||||
|
||||
static struct {
|
||||
|
@ -192,7 +194,6 @@ enum plugin_status plugin_start(struct plugin_api* api, void* parameter)
|
|||
|
||||
(void)parameter;
|
||||
rb=api;
|
||||
|
||||
rb->memset(&settings, 0, sizeof(settings));
|
||||
|
||||
/* now go ahead and have fun! */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue