Thank you to anyone who has already donated - your generous donations helped make three months of treatment possible.

My brother Nate continues to fight stage IV Hodgkin's lymphoma. He's just 31, with a wife and baby girl. They have no active income (since he's been unable to return to work), no insurance, and cannot afford the treatment he needs. Nate and his family need your help. Please consider a donation, every dollar helps. Thanks.


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
diff --git a/apps/codecs.c b/apps/codecs.c
index 29a6644..9e77dd9 100644
--- a/apps/codecs.c
+++ b/apps/codecs.c
@@ -119,7 +119,7 @@ struct codec_api ci = {
     NULL, /* configure */

     /* kernel/ system */
-#ifdef CPU_ARM
+#if defined(CPU_ARM) && CONFIG_PLATFORM & PLATFORM_NATIVE
     __div0,
 #endif
     PREFIX(sleep),
diff --git a/apps/codecs.h b/apps/codecs.h
index 7e4fe94..97b33ec 100644
--- a/apps/codecs.h
+++ b/apps/codecs.h
@@ -156,7 +156,7 @@ struct codec_api {
     void (*configure)(int setting, intptr_t value);

     /* kernel/ system */
-#ifdef CPU_ARM
+#if defined(CPU_ARM) && CONFIG_PLATFORM & PLATFORM_NATIVE
     void (*__div0)(void);
 #endif
     void (*sleep)(int ticks);
diff --git a/apps/plugin.c b/apps/plugin.c
index b3baea7..cc540cd 100644
--- a/apps/plugin.c
+++ b/apps/plugin.c
@@ -345,7 +345,7 @@ static const struct plugin_api rockbox_api = {
     dir_exists,

     /* kernel/ system */
-#ifdef CPU_ARM
+#if defined(CPU_ARM) && CONFIG_PLATFORM & PLATFORM_NATIVE
     __div0,
 #endif
     PREFIX(sleep),
diff --git a/apps/plugin.h b/apps/plugin.h
index 5ee18d0..624b703 100644
--- a/apps/plugin.h
+++ b/apps/plugin.h
@@ -450,7 +450,7 @@ struct plugin_api {
     bool (*dir_exists)(const char *path);

     /* kernel/ system */
-#ifdef CPU_ARM
+#if defined(CPU_ARM) && CONFIG_PLATFORM & PLATFORM_NATIVE
     void (*__div0)(void);
 #endif
     void (*sleep)(int ticks);
diff --git a/firmware/SOURCES b/firmware/SOURCES
index 4092f71..f27a7dd 100644
--- a/firmware/SOURCES
+++ b/firmware/SOURCES
@@ -448,7 +448,9 @@ target/arm/memset16-arm.S
 #ifdef HAVE_PRIORITY_SCHEDULING
 target/arm/ffs-arm.S
 #endif
+#if CONFIG_PLATFORM & PLATFORM_NATIVE
 target/arm/system-arm.c
+#endif
 #if CONFIG_I2C == I2C_PP5024 || CONFIG_I2C == I2C_PP5020 || CONFIG_I2C == I2C_PP5002
 target/arm/i2c-pp.c
 #elif CONFIG_I2C == I2C_PNX0101
diff --git a/firmware/export/config.h b/firmware/export/config.h
index 3b59004..2a83632 100644
--- a/firmware/export/config.h
+++ b/firmware/export/config.h
@@ -490,7 +490,8 @@ Lyre prototype 1 */
 #define ARM_ARCH 6 /* ARMv6 */

 #elif defined(CPU_TCC77X) || defined(CPU_TCC780X) || (CONFIG_CPU == DM320) \
-  || (CONFIG_CPU == AT91SAM9260) || (CONFIG_CPU == AS3525v2)
+  || (CONFIG_CPU == AT91SAM9260) || (CONFIG_CPU == AS3525v2) \
+  || (CONFIG_PLATFORM & PLATFORM_ANDROID)
 #define CPU_ARM
 #define ARM_ARCH 5 /* ARMv5 */