summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThom Johansen <thomj@rockbox.org>2007-11-16 14:30:51 +0000
committerThom Johansen <thomj@rockbox.org>2007-11-16 14:30:51 +0000
commit869a7e7ca67332c358c96c3b6ac591ee062528c0 (patch)
tree6f25fcd6979a58fe97e4c185708c3d9f8394deac
parent5398125fb30bf4326b29b5a7207ec0a517f09ff0 (diff)
downloadrockbox-869a7e7ca67332c358c96c3b6ac591ee062528c0.tar.gz
rockbox-869a7e7ca67332c358c96c3b6ac591ee062528c0.zip
Trim some stuff and move some defines to a more logical place.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15637 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/codecs/libspeex/config-speex.h16
-rw-r--r--apps/codecs/libspeex/rockbox.h11
2 files changed, 12 insertions, 15 deletions
diff --git a/apps/codecs/libspeex/config-speex.h b/apps/codecs/libspeex/config-speex.h
index 31ebe80741..1378fc2a69 100644
--- a/apps/codecs/libspeex/config-speex.h
+++ b/apps/codecs/libspeex/config-speex.h
@@ -3,9 +3,6 @@
3/* config.h. Generated from config.h.in by configure. */ 3/* config.h. Generated from config.h.in by configure. */
4/* config.h.in. Generated from configure.ac by autoheader. */ 4/* config.h.in. Generated from configure.ac by autoheader. */
5 5
6/* Make use of ARM4 assembly optimizations */
7/* #undef ARM4_ASM */
8
9/* Make use of ARM4E assembly optimizations */ 6/* Make use of ARM4E assembly optimizations */
10#if defined(CPU_ARM) 7#if defined(CPU_ARM)
11#define ARM4_ASM 8#define ARM4_ASM
@@ -31,7 +28,7 @@
31/* Debug fixed-point implementation */ 28/* Debug fixed-point implementation */
32/* #undef FIXED_DEBUG */ 29/* #undef FIXED_DEBUG */
33 30
34/* Compile as fixed-point */ 31/* Compile target codec as fixed point */
35#define FIXED_POINT 32#define FIXED_POINT
36 33
37/* Define to 1 if you have the <dlfcn.h> header file. */ 34/* Define to 1 if you have the <dlfcn.h> header file. */
@@ -159,15 +156,4 @@
159#define restrict __restrict 156#define restrict __restrict
160 157
161#define RELEASE 1 158#define RELEASE 1
162#define OVERRIDE_SPEEX_ALLOC 1
163#define OVERRIDE_SPEEX_ALLOC_SCRATCH 1
164#define OVERRIDE_SPEEX_REALLOC 1
165#define OVERRIDE_SPEEX_FREE 1
166#define OVERRIDE_SPEEX_FREE_SCRATCH 1
167#define OVERRIDE_SPEEX_MOVE 1
168#define OVERRIDE_SPEEX_FATAL 1
169#define OVERRIDE_SPEEX_WARNING 1
170#define OVERRIDE_SPEEX_WARNING_INT 1
171#define OVERRIDE_SPEEX_NOTIFY 1
172#define OVERRIDE_SPEEX_PUTC 1
173 159
diff --git a/apps/codecs/libspeex/rockbox.h b/apps/codecs/libspeex/rockbox.h
index 368f1fb2d2..0f8c6d932f 100644
--- a/apps/codecs/libspeex/rockbox.h
+++ b/apps/codecs/libspeex/rockbox.h
@@ -38,57 +38,68 @@
38 38
39extern struct codec_api* ci; 39extern struct codec_api* ci;
40 40
41#define OVERRIDE_SPEEX_ALLOC 1
41static inline void *speex_alloc (int size) 42static inline void *speex_alloc (int size)
42{ 43{
43 return codec_calloc(size, 1); 44 return codec_calloc(size, 1);
44} 45}
45 46
47#define OVERRIDE_SPEEX_ALLOC_SCRATCH 1
46static inline void *speex_alloc_scratch (int size) 48static inline void *speex_alloc_scratch (int size)
47{ 49{
48 return codec_calloc(size,1); 50 return codec_calloc(size,1);
49} 51}
50 52
53#define OVERRIDE_SPEEX_REALLOC 1
51static inline void *speex_realloc (void *ptr, int size) 54static inline void *speex_realloc (void *ptr, int size)
52{ 55{
53 return codec_realloc(ptr, size); 56 return codec_realloc(ptr, size);
54} 57}
55 58
59#define OVERRIDE_SPEEX_FREE 1
56static inline void speex_free (void *ptr) 60static inline void speex_free (void *ptr)
57{ 61{
58 codec_free(ptr); 62 codec_free(ptr);
59} 63}
60 64
65#define OVERRIDE_SPEEX_FREE_SCRATCH 1
61static inline void speex_free_scratch (void *ptr) 66static inline void speex_free_scratch (void *ptr)
62{ 67{
63 codec_free(ptr); 68 codec_free(ptr);
64} 69}
65 70
71#define OVERRIDE_SPEEX_MOVE 1
66static inline void *speex_move (void *dest, void *src, int n) 72static inline void *speex_move (void *dest, void *src, int n)
67{ 73{
68 return memmove(dest,src,n); 74 return memmove(dest,src,n);
69} 75}
70 76
77#define OVERRIDE_SPEEX_FATAL 1
71static inline void _speex_fatal(const char *str, const char *file, int line) 78static inline void _speex_fatal(const char *str, const char *file, int line)
72{ 79{
73 DEBUGF("Fatal error: %s\n", str); 80 DEBUGF("Fatal error: %s\n", str);
74 //exit(1); 81 //exit(1);
75} 82}
76 83
84#define OVERRIDE_SPEEX_WARNING 1
77static inline void speex_warning(const char *str) 85static inline void speex_warning(const char *str)
78{ 86{
79 DEBUGF("warning: %s\n", str); 87 DEBUGF("warning: %s\n", str);
80} 88}
81 89
90#define OVERRIDE_SPEEX_WARNING_INT 1
82static inline void speex_warning_int(const char *str, int val) 91static inline void speex_warning_int(const char *str, int val)
83{ 92{
84 DEBUGF("warning: %s %d\n", str, val); 93 DEBUGF("warning: %s %d\n", str, val);
85} 94}
86 95
96#define OVERRIDE_SPEEX_NOTIFY 1
87static inline void speex_notify(const char *str) 97static inline void speex_notify(const char *str)
88{ 98{
89 DEBUGF("notice: %s\n", str); 99 DEBUGF("notice: %s\n", str);
90} 100}
91 101
102#define OVERRIDE_SPEEX_PUTC 1
92static inline void _speex_putc(int ch, void *file) 103static inline void _speex_putc(int ch, void *file)
93{ 104{
94 //FILE *f = (FILE *)file; 105 //FILE *f = (FILE *)file;