diff options
author | Thomas Martitz <kugel@rockbox.org> | 2010-06-21 16:53:00 +0000 |
---|---|---|
committer | Thomas Martitz <kugel@rockbox.org> | 2010-06-21 16:53:00 +0000 |
commit | 35e8b1429a2cdcf6580f6d25890fed9865165d0b (patch) | |
tree | 084be19a29bffa879eee8e3cad92d8f3b342a337 /firmware/export | |
parent | 02e04585bdf1fbd00cf84d2000f59ec198440cb3 (diff) | |
download | rockbox-35e8b1429a2cdcf6580f6d25890fed9865165d0b.tar.gz rockbox-35e8b1429a2cdcf6580f6d25890fed9865165d0b.zip |
Rockbox as an application: Replace many occurences of #ifdef SIMULATOR with #if (CONFIG_PLATFORM & PLATFORM_HOSTED) (or equivalently).
The simulator defines PLATFORM_HOSTED, as RaaA will do (RaaA will not define SIMULATOR).
The new define is to (de-)select code to compile on hosted platforms generally.
Should be no functional change to targets or the simulator.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27019 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/export')
-rw-r--r-- | firmware/export/ata_idle_notify.h | 2 | ||||
-rw-r--r-- | firmware/export/audio.h | 2 | ||||
-rw-r--r-- | firmware/export/buffer.h | 6 | ||||
-rw-r--r-- | firmware/export/config.h | 28 | ||||
-rw-r--r-- | firmware/export/config/sim.h | 1 | ||||
-rw-r--r-- | firmware/export/font.h | 2 | ||||
-rw-r--r-- | firmware/export/hwcompat.h | 4 | ||||
-rw-r--r-- | firmware/export/kernel.h | 2 | ||||
-rw-r--r-- | firmware/export/power.h | 2 | ||||
-rw-r--r-- | firmware/export/powermgmt.h | 4 | ||||
-rw-r--r-- | firmware/export/storage.h | 4 | ||||
-rw-r--r-- | firmware/export/system.h | 9 | ||||
-rw-r--r-- | firmware/export/thread.h | 8 | ||||
-rw-r--r-- | firmware/export/timer.h | 2 | ||||
-rw-r--r-- | firmware/export/tuner.h | 4 |
15 files changed, 48 insertions, 32 deletions
diff --git a/firmware/export/ata_idle_notify.h b/firmware/export/ata_idle_notify.h index 348165f1d1..439b883e41 100644 --- a/firmware/export/ata_idle_notify.h +++ b/firmware/export/ata_idle_notify.h | |||
@@ -43,7 +43,7 @@ enum { | |||
43 | DISK_EVENT_SPINUP = (EVENT_CLASS_DISK|1), | 43 | DISK_EVENT_SPINUP = (EVENT_CLASS_DISK|1), |
44 | }; | 44 | }; |
45 | 45 | ||
46 | #define USING_STORAGE_CALLBACK !defined(SIMULATOR) \ | 46 | #define USING_STORAGE_CALLBACK (CONFIG_PLATFORM & PLATFORM_NATIVE) \ |
47 | && ! ((CONFIG_STORAGE & STORAGE_NAND) \ | 47 | && ! ((CONFIG_STORAGE & STORAGE_NAND) \ |
48 | && (CONFIG_NAND == NAND_IFP7XX)) \ | 48 | && (CONFIG_NAND == NAND_IFP7XX)) \ |
49 | && !defined(BOOTLOADER) | 49 | && !defined(BOOTLOADER) |
diff --git a/firmware/export/audio.h b/firmware/export/audio.h index 1e09081ba5..b81597a892 100644 --- a/firmware/export/audio.h +++ b/firmware/export/audio.h | |||
@@ -36,7 +36,7 @@ | |||
36 | #endif /* CONFIG_CODEC == SWCODEC */ | 36 | #endif /* CONFIG_CODEC == SWCODEC */ |
37 | 37 | ||
38 | 38 | ||
39 | #ifdef SIMULATOR | 39 | #if (CONFIG_PLATFORM & PLATFORM_HOSTED) |
40 | #define audio_play(x) sim_audio_play(x) | 40 | #define audio_play(x) sim_audio_play(x) |
41 | #endif | 41 | #endif |
42 | 42 | ||
diff --git a/firmware/export/buffer.h b/firmware/export/buffer.h index 4c80471b27..ae8886bffc 100644 --- a/firmware/export/buffer.h +++ b/firmware/export/buffer.h | |||
@@ -23,10 +23,10 @@ | |||
23 | 23 | ||
24 | #include "config.h" | 24 | #include "config.h" |
25 | /* defined in linker script */ | 25 | /* defined in linker script */ |
26 | #ifdef SIMULATOR | 26 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) |
27 | extern unsigned char *audiobufend; | ||
28 | #else | ||
29 | extern unsigned char audiobufend[]; | 27 | extern unsigned char audiobufend[]; |
28 | #else | ||
29 | extern unsigned char *audiobufend; | ||
30 | #endif | 30 | #endif |
31 | 31 | ||
32 | extern unsigned char *audiobuf; | 32 | extern unsigned char *audiobuf; |
diff --git a/firmware/export/config.h b/firmware/export/config.h index de84dc3742..c06e5d110a 100644 --- a/firmware/export/config.h +++ b/firmware/export/config.h | |||
@@ -74,6 +74,13 @@ | |||
74 | #define AT91SAM9260 9260 | 74 | #define AT91SAM9260 9260 |
75 | #define AS3525v2 35252 | 75 | #define AS3525v2 35252 |
76 | 76 | ||
77 | /* platforms | ||
78 | * bit fields to allow PLATFORM_HOSTED to be OR'ed e.g. with a | ||
79 | * possible future PLATFORM_ANDROID (some OSes might need totally different | ||
80 | * handling to run on them than a stand-alone application) */ | ||
81 | #define PLATFORM_NATIVE (1<<0) | ||
82 | #define PLATFORM_HOSTED (1<<1) | ||
83 | |||
77 | /* CONFIG_KEYPAD */ | 84 | /* CONFIG_KEYPAD */ |
78 | #define PLAYER_PAD 1 | 85 | #define PLAYER_PAD 1 |
79 | #define RECORDER_PAD 2 | 86 | #define RECORDER_PAD 2 |
@@ -497,6 +504,10 @@ Lyre prototype 1 */ | |||
497 | #define CONFIG_BACKLIGHT_FADING BACKLIGHT_NO_FADING | 504 | #define CONFIG_BACKLIGHT_FADING BACKLIGHT_NO_FADING |
498 | #endif | 505 | #endif |
499 | 506 | ||
507 | #ifndef CONFIG_PLATFORM | ||
508 | #define CONFIG_PLATFORM PLATFORM_NATIVE | ||
509 | #endif | ||
510 | |||
500 | #ifndef CONFIG_TUNER | 511 | #ifndef CONFIG_TUNER |
501 | #define CONFIG_TUNER 0 | 512 | #define CONFIG_TUNER 0 |
502 | #endif | 513 | #endif |
@@ -675,10 +686,10 @@ Lyre prototype 1 */ | |||
675 | #define HAVE_EXTENDED_MESSAGING_AND_NAME | 686 | #define HAVE_EXTENDED_MESSAGING_AND_NAME |
676 | #define HAVE_WAKEUP_EXT_CB | 687 | #define HAVE_WAKEUP_EXT_CB |
677 | 688 | ||
678 | #ifndef SIMULATOR | 689 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) |
679 | #define HAVE_PRIORITY_SCHEDULING | 690 | #define HAVE_PRIORITY_SCHEDULING |
680 | #define HAVE_SCHEDULER_BOOSTCTRL | 691 | #define HAVE_SCHEDULER_BOOSTCTRL |
681 | #endif /* SIMULATOR */ | 692 | #endif /* PLATFORM_NATIVE */ |
682 | 693 | ||
683 | #define HAVE_SEMAPHORE_OBJECTS | 694 | #define HAVE_SEMAPHORE_OBJECTS |
684 | 695 | ||
@@ -744,7 +755,7 @@ Lyre prototype 1 */ | |||
744 | #endif | 755 | #endif |
745 | 756 | ||
746 | /* IRAM usage */ | 757 | /* IRAM usage */ |
747 | #if !defined(SIMULATOR) && /* Not for simulators */ \ | 758 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) && /* Not for hosted environments */ \ |
748 | (((CONFIG_CPU == SH7034) && !defined(PLUGIN)) || /* SH1 archos: core only */ \ | 759 | (((CONFIG_CPU == SH7034) && !defined(PLUGIN)) || /* SH1 archos: core only */ \ |
749 | defined(CPU_COLDFIRE) || /* Coldfire: core, plugins, codecs */ \ | 760 | defined(CPU_COLDFIRE) || /* Coldfire: core, plugins, codecs */ \ |
750 | defined(CPU_PP) || /* PortalPlayer: core, plugins, codecs */ \ | 761 | defined(CPU_PP) || /* PortalPlayer: core, plugins, codecs */ \ |
@@ -780,9 +791,10 @@ Lyre prototype 1 */ | |||
780 | #define IBSS_ATTR | 791 | #define IBSS_ATTR |
781 | #define STATICIRAM static | 792 | #define STATICIRAM static |
782 | #endif | 793 | #endif |
794 | |||
783 | #if (defined(CPU_PP) || (CONFIG_CPU == AS3525) || (CONFIG_CPU == AS3525v2) || \ | 795 | #if (defined(CPU_PP) || (CONFIG_CPU == AS3525) || (CONFIG_CPU == AS3525v2) || \ |
784 | (CONFIG_CPU == IMX31L)) \ | 796 | (CONFIG_CPU == IMX31L)) \ |
785 | && !defined(SIMULATOR) && !defined(BOOTLOADER) | 797 | && (CONFIG_PLATFORM & PLATFORM_NATIVE) && !defined(BOOTLOADER) |
786 | /* Functions that have INIT_ATTR attached are NOT guaranteed to survive after | 798 | /* Functions that have INIT_ATTR attached are NOT guaranteed to survive after |
787 | * root_menu() has been called. Their code may be overwritten by other data or | 799 | * root_menu() has been called. Their code may be overwritten by other data or |
788 | * code in order to save RAM, and references to them might point into | 800 | * code in order to save RAM, and references to them might point into |
@@ -799,7 +811,7 @@ Lyre prototype 1 */ | |||
799 | #define INIT_ATTR | 811 | #define INIT_ATTR |
800 | #endif | 812 | #endif |
801 | 813 | ||
802 | #if defined(SIMULATOR) && defined(__APPLE__) | 814 | #if (CONFIG_PLATFORM & PLATFORM_HOSTED) && defined(__APPLE__) |
803 | #define DATA_ATTR __attribute__ ((section("__DATA, .data"))) | 815 | #define DATA_ATTR __attribute__ ((section("__DATA, .data"))) |
804 | #else | 816 | #else |
805 | #define DATA_ATTR __attribute__ ((section(".data"))) | 817 | #define DATA_ATTR __attribute__ ((section(".data"))) |
@@ -923,7 +935,7 @@ Lyre prototype 1 */ | |||
923 | 935 | ||
924 | #else /* BOOTLOADER */ | 936 | #else /* BOOTLOADER */ |
925 | 937 | ||
926 | #ifndef SIMULATOR | 938 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) |
927 | //#define USB_ENABLE_SERIAL | 939 | //#define USB_ENABLE_SERIAL |
928 | #define USB_ENABLE_STORAGE | 940 | #define USB_ENABLE_STORAGE |
929 | 941 | ||
@@ -941,11 +953,11 @@ Lyre prototype 1 */ | |||
941 | /* This attribute can be used to enable to detection of plugin file handles leaks. | 953 | /* This attribute can be used to enable to detection of plugin file handles leaks. |
942 | * When enabled, the plugin core will monitor open/close/creat and when the plugin exits | 954 | * When enabled, the plugin core will monitor open/close/creat and when the plugin exits |
943 | * will display an error message if the plugin leaked some file handles */ | 955 | * will display an error message if the plugin leaked some file handles */ |
944 | #ifndef SIMULATOR | 956 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) |
945 | #define HAVE_PLUGIN_CHECK_OPEN_CLOSE | 957 | #define HAVE_PLUGIN_CHECK_OPEN_CLOSE |
946 | #endif | 958 | #endif |
947 | 959 | ||
948 | #if defined(HAVE_DIRCACHE) && !defined(SIMULATOR) | 960 | #if defined(HAVE_DIRCACHE) && (CONFIG_PLATFORM & PLATFORM_NATIVE) |
949 | #define HAVE_IO_PRIORITY | 961 | #define HAVE_IO_PRIORITY |
950 | #endif | 962 | #endif |
951 | 963 | ||
diff --git a/firmware/export/config/sim.h b/firmware/export/config/sim.h index d65b0fbbf8..5dcb4f6f2d 100644 --- a/firmware/export/config/sim.h +++ b/firmware/export/config/sim.h | |||
@@ -101,4 +101,5 @@ | |||
101 | 101 | ||
102 | #define HAVE_SDL | 102 | #define HAVE_SDL |
103 | #define HAVE_SDL_AUDIO | 103 | #define HAVE_SDL_AUDIO |
104 | #define CONFIG_PLATFORM PLATFORM_HOSTED | ||
104 | #define _ISOC99_SOURCE 1 | 105 | #define _ISOC99_SOURCE 1 |
diff --git a/firmware/export/font.h b/firmware/export/font.h index f6915d9c09..7284564380 100644 --- a/firmware/export/font.h +++ b/firmware/export/font.h | |||
@@ -28,7 +28,7 @@ | |||
28 | */ | 28 | */ |
29 | #include "config.h" | 29 | #include "config.h" |
30 | 30 | ||
31 | #if defined(HAVE_LCD_BITMAP) || defined(SIMULATOR) | 31 | #if defined(HAVE_LCD_BITMAP) || (CONFIG_PLATFORM & PLATFORM_HOSTED) |
32 | #ifndef __PCTOOL__ | 32 | #ifndef __PCTOOL__ |
33 | #include "font_cache.h" | 33 | #include "font_cache.h" |
34 | #include "sysfont.h" | 34 | #include "sysfont.h" |
diff --git a/firmware/export/hwcompat.h b/firmware/export/hwcompat.h index 27fcb25e36..c37add49f9 100644 --- a/firmware/export/hwcompat.h +++ b/firmware/export/hwcompat.h | |||
@@ -24,7 +24,7 @@ | |||
24 | #include <stdbool.h> | 24 | #include <stdbool.h> |
25 | #include "config.h" | 25 | #include "config.h" |
26 | 26 | ||
27 | #if (CONFIG_CPU == SH7034) && !defined(SIMULATOR) | 27 | #if (CONFIG_CPU == SH7034) && (CONFIG_PLATFORM & PLATFORM_NATIVE) |
28 | 28 | ||
29 | #define ROM_VERSION (*(short *)0x020000fe) | 29 | #define ROM_VERSION (*(short *)0x020000fe) |
30 | 30 | ||
@@ -49,7 +49,7 @@ static inline int tuner_detect_type(void) | |||
49 | } | 49 | } |
50 | #endif | 50 | #endif |
51 | 51 | ||
52 | #endif /* (CONFIG_CPU == SH7034) && !SIMULATOR */ | 52 | #endif /* (CONFIG_CPU == SH7034) && (CONFIG_PLATFORM & PLATFORM_NATIVE) */ |
53 | 53 | ||
54 | #ifdef ARCHOS_PLAYER | 54 | #ifdef ARCHOS_PLAYER |
55 | bool is_new_player(void); | 55 | bool is_new_player(void); |
diff --git a/firmware/export/kernel.h b/firmware/export/kernel.h index bcf51c1723..9ef5af8c0c 100644 --- a/firmware/export/kernel.h +++ b/firmware/export/kernel.h | |||
@@ -201,7 +201,7 @@ static inline void call_tick_tasks(void) | |||
201 | } | 201 | } |
202 | #endif | 202 | #endif |
203 | 203 | ||
204 | #if defined(SIMULATOR) && !defined(PLUGIN) && !defined(CODEC) | 204 | #if (CONFIG_PLATFORM & PLATFORM_HOSTED) && !defined(PLUGIN) && !defined(CODEC) |
205 | #define sleep(x) sim_sleep(x) | 205 | #define sleep(x) sim_sleep(x) |
206 | #endif | 206 | #endif |
207 | 207 | ||
diff --git a/firmware/export/power.h b/firmware/export/power.h index 107158767f..137f40cb01 100644 --- a/firmware/export/power.h +++ b/firmware/export/power.h | |||
@@ -81,7 +81,7 @@ void ide_power_enable(bool on); | |||
81 | bool charging_state(void); | 81 | bool charging_state(void); |
82 | #endif | 82 | #endif |
83 | 83 | ||
84 | #ifndef SIMULATOR | 84 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) |
85 | 85 | ||
86 | void power_init(void) INIT_ATTR; | 86 | void power_init(void) INIT_ATTR; |
87 | 87 | ||
diff --git a/firmware/export/powermgmt.h b/firmware/export/powermgmt.h index d86118cd9b..03b9d34d54 100644 --- a/firmware/export/powermgmt.h +++ b/firmware/export/powermgmt.h | |||
@@ -74,7 +74,7 @@ extern unsigned int power_thread_inputs; | |||
74 | #include "powermgmt-target.h" | 74 | #include "powermgmt-target.h" |
75 | #endif | 75 | #endif |
76 | 76 | ||
77 | #ifndef SIMULATOR | 77 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) |
78 | 78 | ||
79 | /* Generic current values that are intentionally meaningless - config header | 79 | /* Generic current values that are intentionally meaningless - config header |
80 | * should define proper numbers.*/ | 80 | * should define proper numbers.*/ |
@@ -129,7 +129,7 @@ extern const unsigned short percent_to_volt_charge[11]; | |||
129 | /* Start up power management thread */ | 129 | /* Start up power management thread */ |
130 | void powermgmt_init(void) INIT_ATTR; | 130 | void powermgmt_init(void) INIT_ATTR; |
131 | 131 | ||
132 | #endif /* SIMULATOR */ | 132 | #endif /* PLATFORM_NATIVE */ |
133 | 133 | ||
134 | /* Returns battery statust */ | 134 | /* Returns battery statust */ |
135 | int battery_level(void); /* percent */ | 135 | int battery_level(void); /* percent */ |
diff --git a/firmware/export/storage.h b/firmware/export/storage.h index e62cf0d902..e59a5e5bf6 100644 --- a/firmware/export/storage.h +++ b/firmware/export/storage.h | |||
@@ -51,7 +51,7 @@ struct storage_info | |||
51 | char *revision; | 51 | char *revision; |
52 | }; | 52 | }; |
53 | 53 | ||
54 | #if !defined(SIMULATOR) && !defined(CONFIG_STORAGE_MULTI) | 54 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) && !defined(CONFIG_STORAGE_MULTI) |
55 | /* storage_spindown, storage_sleep and storage_spin are passed as | 55 | /* storage_spindown, storage_sleep and storage_spin are passed as |
56 | * pointers, which doesn't work with argument-macros. | 56 | * pointers, which doesn't work with argument-macros. |
57 | */ | 57 | */ |
@@ -185,7 +185,7 @@ struct storage_info | |||
185 | #else | 185 | #else |
186 | //#error No storage driver! | 186 | //#error No storage driver! |
187 | #endif | 187 | #endif |
188 | #else /* NOT CONFIG_STORAGE_MULTI and NOT SIMULATOR*/ | 188 | #else /* NOT CONFIG_STORAGE_MULTI and PLATFORM_NATIVE*/ |
189 | 189 | ||
190 | /* Simulator and multi-driver use normal functions */ | 190 | /* Simulator and multi-driver use normal functions */ |
191 | 191 | ||
diff --git a/firmware/export/system.h b/firmware/export/system.h index 5ac92e015d..7a04422b06 100644 --- a/firmware/export/system.h +++ b/firmware/export/system.h | |||
@@ -125,7 +125,7 @@ int get_cpu_boost_counter(void); | |||
125 | 125 | ||
126 | 126 | ||
127 | /* newer? SDL includes endian.h, So we ignore it */ | 127 | /* newer? SDL includes endian.h, So we ignore it */ |
128 | #if defined(SIMULATOR) || defined(__PCTOOL__) | 128 | #if (CONFIG_PLATFORM & PLATFORM_HOSTED) || defined(__PCTOOL__) |
129 | #undef letoh16 | 129 | #undef letoh16 |
130 | #undef letoh32 | 130 | #undef letoh32 |
131 | #undef htole16 | 131 | #undef htole16 |
@@ -234,8 +234,11 @@ enum { | |||
234 | 234 | ||
235 | #if !defined(SIMULATOR) && !defined(__PCTOOL__) | 235 | #if !defined(SIMULATOR) && !defined(__PCTOOL__) |
236 | #include "system-target.h" | 236 | #include "system-target.h" |
237 | #elif defined(HAVE_SDL) /* SIMULATOR */ | 237 | #elif defined(HAVE_SDL) /* SDL build */ |
238 | #include "system-sdl.h" | 238 | #include "system-sdl.h" |
239 | #endif | ||
240 | |||
241 | #if (CONFIG_PLATFORM & PLATFORM_HOSTED) | ||
239 | static inline uint16_t swap16(uint16_t value) | 242 | static inline uint16_t swap16(uint16_t value) |
240 | /* | 243 | /* |
241 | result[15..8] = value[ 7..0]; | 244 | result[15..8] = value[ 7..0]; |
@@ -268,7 +271,7 @@ static inline uint32_t swap_odd_even32(uint32_t value) | |||
268 | return (t >> 8) | ((t ^ value) << 8); | 271 | return (t >> 8) | ((t ^ value) << 8); |
269 | } | 272 | } |
270 | 273 | ||
271 | #endif /* !SIMULATOR */ | 274 | #endif /* PLATFORM_HOSTED */ |
272 | 275 | ||
273 | #ifndef BIT_N | 276 | #ifndef BIT_N |
274 | #define BIT_N(n) (1U << (n)) | 277 | #define BIT_N(n) (1U << (n)) |
diff --git a/firmware/export/thread.h b/firmware/export/thread.h index d907e5dc95..c4b7d1fa22 100644 --- a/firmware/export/thread.h +++ b/firmware/export/thread.h | |||
@@ -81,7 +81,7 @@ | |||
81 | 81 | ||
82 | #define DEFAULT_STACK_SIZE 0x400 /* Bytes */ | 82 | #define DEFAULT_STACK_SIZE 0x400 /* Bytes */ |
83 | 83 | ||
84 | #ifndef SIMULATOR | 84 | #if (CONFIG_PLATFORM & PLATFORM_NATIVE) |
85 | /* Need to keep structures inside the header file because debug_menu | 85 | /* Need to keep structures inside the header file because debug_menu |
86 | * needs them. */ | 86 | * needs them. */ |
87 | #ifdef CPU_COLDFIRE | 87 | #ifdef CPU_COLDFIRE |
@@ -135,15 +135,15 @@ struct regs | |||
135 | uint32_t start; /* 44 - Thread start address, or NULL when started */ | 135 | uint32_t start; /* 44 - Thread start address, or NULL when started */ |
136 | }; | 136 | }; |
137 | #endif /* CONFIG_CPU */ | 137 | #endif /* CONFIG_CPU */ |
138 | #else | 138 | #elif (CONFIG_PLATFORM & PLATFORM_HOSTED) |
139 | struct regs | 139 | struct regs |
140 | { | 140 | { |
141 | void *t; /* Simulator OS thread */ | 141 | void *t; /* OS thread */ |
142 | void *told; /* Last thread in slot (explained in thead-sdl.c) */ | 142 | void *told; /* Last thread in slot (explained in thead-sdl.c) */ |
143 | void *s; /* Semaphore for blocking and wakeup */ | 143 | void *s; /* Semaphore for blocking and wakeup */ |
144 | void (*start)(void); /* Start function */ | 144 | void (*start)(void); /* Start function */ |
145 | }; | 145 | }; |
146 | #endif /* !SIMULATOR */ | 146 | #endif /* PLATFORM_NATIVE */ |
147 | 147 | ||
148 | /* NOTE: The use of the word "queue" may also refer to a linked list of | 148 | /* NOTE: The use of the word "queue" may also refer to a linked list of |
149 | threads being maintained that are normally dealt with in FIFO order | 149 | threads being maintained that are normally dealt with in FIFO order |
diff --git a/firmware/export/timer.h b/firmware/export/timer.h index b070acae31..b12ec55881 100644 --- a/firmware/export/timer.h +++ b/firmware/export/timer.h | |||
@@ -26,7 +26,7 @@ | |||
26 | #include "config.h" | 26 | #include "config.h" |
27 | #include "cpu.h" | 27 | #include "cpu.h" |
28 | 28 | ||
29 | #if defined(SIMULATOR) | 29 | #if (CONFIG_PLATFORM & PLATFORM_HOSTED) |
30 | #define TIMER_FREQ 1000000 | 30 | #define TIMER_FREQ 1000000 |
31 | #endif | 31 | #endif |
32 | 32 | ||
diff --git a/firmware/export/tuner.h b/firmware/export/tuner.h index fa894a4b6c..461c9a3fcb 100644 --- a/firmware/export/tuner.h +++ b/firmware/export/tuner.h | |||
@@ -90,7 +90,7 @@ extern const struct fm_region_data fm_region_data[TUNER_NUM_REGIONS]; | |||
90 | 90 | ||
91 | #if CONFIG_TUNER | 91 | #if CONFIG_TUNER |
92 | 92 | ||
93 | #ifdef SIMULATOR | 93 | #if (CONFIG_PLATFORM & PLATFORM_HOSTED) |
94 | int tuner_set(int setting, int value); | 94 | int tuner_set(int setting, int value); |
95 | int tuner_get(int setting); | 95 | int tuner_get(int setting); |
96 | #ifdef HAVE_RDS_CAP | 96 | #ifdef HAVE_RDS_CAP |
@@ -142,7 +142,7 @@ extern int (*tuner_get)(int setting); | |||
142 | #include "ipod_remote_tuner.h" | 142 | #include "ipod_remote_tuner.h" |
143 | #endif | 143 | #endif |
144 | 144 | ||
145 | #endif /* SIMULATOR */ | 145 | #endif /* PLATFORM_HOSTED */ |
146 | 146 | ||
147 | /* Additional messages that get enumerated after tuner driver headers */ | 147 | /* Additional messages that get enumerated after tuner driver headers */ |
148 | 148 | ||