summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2011-04-27 12:52:11 +0000
committerMichael Sevakis <jethead71@rockbox.org>2011-04-27 12:52:11 +0000
commit08bedf83051064c7dc9a7bb903ab9a34afe8d725 (patch)
treeac8606643c781d350b27b6a948579c9e718f8323
parent1a68986bc5d13db4508797700dff99638dccc88c (diff)
downloadrockbox-08bedf83051064c7dc9a7bb903ab9a34afe8d725.tar.gz
rockbox-08bedf83051064c7dc9a7bb903ab9a34afe8d725.zip
Having a default weak codec_main symbol doesn't seem to be working out for compiling the sim under cygwin in at least some cases. Just implement it explicitly in all cases.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29789 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/codecs/asap.c8
-rw-r--r--apps/codecs/atrac3_oma.c8
-rw-r--r--apps/codecs/atrac3_rm.c8
-rw-r--r--apps/codecs/cook.c8
-rw-r--r--apps/codecs/lib/codeclib.c10
-rw-r--r--apps/codecs/speex.c8
6 files changed, 40 insertions, 10 deletions
diff --git a/apps/codecs/asap.c b/apps/codecs/asap.c
index f12dc6a0c5..5d098eda15 100644
--- a/apps/codecs/asap.c
+++ b/apps/codecs/asap.c
@@ -29,6 +29,14 @@ CODEC_HEADER
29static byte samples[CHUNK_SIZE] IBSS_ATTR; /* The sample buffer */ 29static byte samples[CHUNK_SIZE] IBSS_ATTR; /* The sample buffer */
30static ASAP_State asap; /* asap codec state */ 30static ASAP_State asap; /* asap codec state */
31 31
32/* this is the codec entry point */
33enum codec_status codec_main(enum codec_entry_call_reason reason)
34{
35 /* Nothing to do */
36 return CODEC_OK;
37 (void)reason;
38}
39
32/* this is called for each file to process */ 40/* this is called for each file to process */
33enum codec_status codec_run(void) 41enum codec_status codec_run(void)
34{ 42{
diff --git a/apps/codecs/atrac3_oma.c b/apps/codecs/atrac3_oma.c
index ab24783368..50f7c8f163 100644
--- a/apps/codecs/atrac3_oma.c
+++ b/apps/codecs/atrac3_oma.c
@@ -33,6 +33,14 @@ CODEC_HEADER
33 33
34static ATRAC3Context q IBSS_ATTR; 34static ATRAC3Context q IBSS_ATTR;
35 35
36/* this is the codec entry point */
37enum codec_status codec_main(enum codec_entry_call_reason reason)
38{
39 /* Nothing to do */
40 return CODEC_OK;
41 (void)reason;
42}
43
36/* this is called for each file to process */ 44/* this is called for each file to process */
37enum codec_status codec_run(void) 45enum codec_status codec_run(void)
38{ 46{
diff --git a/apps/codecs/atrac3_rm.c b/apps/codecs/atrac3_rm.c
index 1322e917ed..4c619898bb 100644
--- a/apps/codecs/atrac3_rm.c
+++ b/apps/codecs/atrac3_rm.c
@@ -41,6 +41,14 @@ static void init_rm(RMContext *rmctx)
41 memcpy(ci->id3->id3v2buf, (char*)rmctx->codec_extradata, rmctx->extradata_size*sizeof(char)); 41 memcpy(ci->id3->id3v2buf, (char*)rmctx->codec_extradata, rmctx->extradata_size*sizeof(char));
42} 42}
43 43
44/* this is the codec entry point */
45enum codec_status codec_main(enum codec_entry_call_reason reason)
46{
47 /* Nothing to do */
48 return CODEC_OK;
49 (void)reason;
50}
51
44/* this is called for each file to process */ 52/* this is called for each file to process */
45enum codec_status codec_run(void) 53enum codec_status codec_run(void)
46{ 54{
diff --git a/apps/codecs/cook.c b/apps/codecs/cook.c
index a6b4a1153e..82739694d8 100644
--- a/apps/codecs/cook.c
+++ b/apps/codecs/cook.c
@@ -38,6 +38,14 @@ static void init_rm(RMContext *rmctx)
38 memcpy(rmctx, (void*)(( (intptr_t)ci->id3->id3v2buf + 3 ) &~ 3), sizeof(RMContext)); 38 memcpy(rmctx, (void*)(( (intptr_t)ci->id3->id3v2buf + 3 ) &~ 3), sizeof(RMContext));
39} 39}
40 40
41/* this is the codec entry point */
42enum codec_status codec_main(enum codec_entry_call_reason reason)
43{
44 /* Nothing to do */
45 return CODEC_OK;
46 (void)reason;
47}
48
41/* this is called for each file to process */ 49/* this is called for each file to process */
42enum codec_status codec_run(void) 50enum codec_status codec_run(void)
43{ 51{
diff --git a/apps/codecs/lib/codeclib.c b/apps/codecs/lib/codeclib.c
index 443c0bbdcf..3a46f6d06b 100644
--- a/apps/codecs/lib/codeclib.c
+++ b/apps/codecs/lib/codeclib.c
@@ -33,16 +33,6 @@ unsigned char* mp3buf; // The actual MP3 buffer from Rockbox
33unsigned char* mallocbuf; // 512K from the start of MP3 buffer 33unsigned char* mallocbuf; // 512K from the start of MP3 buffer
34unsigned char* filebuf; // The rest of the MP3 buffer 34unsigned char* filebuf; // The rest of the MP3 buffer
35 35
36/* this is the default codec entry point for when nothing needs to be done
37 on load or unload */
38enum codec_status __attribute__((weak))
39codec_main(enum codec_entry_call_reason reason)
40{
41 /* Nothing to do */
42 return CODEC_OK;
43 (void)reason;
44}
45
46int codec_init(void) 36int codec_init(void)
47{ 37{
48 mem_ptr = 0; 38 mem_ptr = 0;
diff --git a/apps/codecs/speex.c b/apps/codecs/speex.c
index e394efc3d5..85ee9c422c 100644
--- a/apps/codecs/speex.c
+++ b/apps/codecs/speex.c
@@ -367,6 +367,14 @@ static void *process_header(spx_ogg_packet *op,
367 return st; 367 return st;
368} 368}
369 369
370/* this is the codec entry point */
371enum codec_status codec_main(enum codec_entry_call_reason reason)
372{
373 /* Nothing to do */
374 return CODEC_OK;
375 (void)reason;
376}
377
370/* this is called for each file to process */ 378/* this is called for each file to process */
371enum codec_status codec_run(void) 379enum codec_status codec_run(void)
372{ 380{