diff options
author | Nils Wallménius <nils@rockbox.org> | 2007-06-13 15:35:07 +0000 |
---|---|---|
committer | Nils Wallménius <nils@rockbox.org> | 2007-06-13 15:35:07 +0000 |
commit | c7f9ca4067f26ba3d0471d50ed3f06b047171b50 (patch) | |
tree | 9bfaf2d5019c075ad97540a2beed8d68277ca021 /apps/plugins/metronome.c | |
parent | f50bd1151a65b1aeefaeab545187fba29881b800 (diff) | |
download | rockbox-c7f9ca4067f26ba3d0471d50ed3f06b047171b50.tar.gz rockbox-c7f9ca4067f26ba3d0471d50ed3f06b047171b50.zip |
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
Diffstat (limited to 'apps/plugins/metronome.c')
-rw-r--r-- | apps/plugins/metronome.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/plugins/metronome.c b/apps/plugins/metronome.c index 19a37a580a..daf3294b75 100644 --- a/apps/plugins/metronome.c +++ b/apps/plugins/metronome.c | |||
@@ -18,6 +18,7 @@ | |||
18 | ****************************************************************************/ | 18 | ****************************************************************************/ |
19 | #include "plugin.h" | 19 | #include "plugin.h" |
20 | #include "pluginlib_actions.h" | 20 | #include "pluginlib_actions.h" |
21 | #include "mem_function_wrappers.h" | ||
21 | 22 | ||
22 | PLUGIN_HEADER | 23 | PLUGIN_HEADER |
23 | 24 | ||
@@ -70,6 +71,8 @@ static const struct button_mapping iriver_syncaction[] = | |||
70 | 71 | ||
71 | static struct plugin_api* rb; | 72 | static struct plugin_api* rb; |
72 | 73 | ||
74 | MEM_FUNCTION_WRAPPERS(rb); | ||
75 | |||
73 | static int bpm = 120; | 76 | static int bpm = 120; |
74 | static int period = 0; | 77 | static int period = 0; |
75 | static int minitick = 0; | 78 | static int minitick = 0; |
@@ -159,7 +162,7 @@ static unsigned char sound[] = { | |||
159 | 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, | 162 | 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, |
160 | 85, 85, 85}; | 163 | 85, 85, 85}; |
161 | 164 | ||
162 | void callback(unsigned char** start, int* size){ | 165 | void callback(unsigned char** start, size_t* size){ |
163 | (void)start; /* unused parameter, avoid warning */ | 166 | (void)start; /* unused parameter, avoid warning */ |
164 | *size = NULL; /* end of data */ | 167 | *size = NULL; /* end of data */ |
165 | sound_active = false; | 168 | sound_active = false; |