diff options
-rw-r--r-- | apps/logfdisp.c | 2 | ||||
-rw-r--r-- | apps/plugins/calendar.c | 10 | ||||
-rw-r--r-- | apps/plugins/lib/configfile.c | 2 | ||||
-rw-r--r-- | apps/plugins/midi/synth.c | 4 | ||||
-rw-r--r-- | apps/plugins/midi2wav.c | 3 | ||||
-rw-r--r-- | apps/plugins/midiplay.c | 3 | ||||
-rw-r--r-- | apps/plugins/pacbox/pacbox.c | 4 | ||||
-rw-r--r-- | apps/plugins/rockboy/menu.c | 2 | ||||
-rw-r--r-- | apps/plugins/rockboy/rockmacros.h | 2 | ||||
-rw-r--r-- | apps/plugins/snake2.c | 2 | ||||
-rw-r--r-- | apps/plugins/zxbox/snapshot.c | 2 |
11 files changed, 19 insertions, 17 deletions
diff --git a/apps/logfdisp.c b/apps/logfdisp.c index 734a6aec63..6463ae6d88 100644 --- a/apps/logfdisp.c +++ b/apps/logfdisp.c | |||
@@ -108,7 +108,7 @@ bool logfdump(void) | |||
108 | /* nothing is logged just yet */ | 108 | /* nothing is logged just yet */ |
109 | return false; | 109 | return false; |
110 | 110 | ||
111 | fd = open("/.rockbox/logf.txt", O_CREAT|O_WRONLY|O_TRUNC); | 111 | fd = open(ROCKBOX_DIR "/logf.txt", O_CREAT|O_WRONLY|O_TRUNC); |
112 | if(-1 != fd) { | 112 | if(-1 != fd) { |
113 | unsigned char buffer[MAX_LOGF_ENTRY +1]; | 113 | unsigned char buffer[MAX_LOGF_ENTRY +1]; |
114 | int index = logfindex-1; | 114 | int index = logfindex-1; |
diff --git a/apps/plugins/calendar.c b/apps/plugins/calendar.c index 8c0b6af5b9..8ed6122c3f 100644 --- a/apps/plugins/calendar.c +++ b/apps/plugins/calendar.c | |||
@@ -218,7 +218,7 @@ static void load_memo(struct shown *shown) | |||
218 | for (k = 0; k < 7; k++) | 218 | for (k = 0; k < 7; k++) |
219 | wday_has_memo[k] = false; | 219 | wday_has_memo[k] = false; |
220 | memos_in_memory = 0; | 220 | memos_in_memory = 0; |
221 | fp = rb->open("/.rockbox/.memo",O_RDONLY); | 221 | fp = rb->open(ROCKBOX_DIR "/.memo",O_RDONLY); |
222 | if (fp > -1) | 222 | if (fp > -1) |
223 | { | 223 | { |
224 | int count = rb->filesize(fp); | 224 | int count = rb->filesize(fp); |
@@ -315,8 +315,8 @@ static void load_memo(struct shown *shown) | |||
315 | static bool save_memo(int changed, bool new_mod, struct shown *shown) | 315 | static bool save_memo(int changed, bool new_mod, struct shown *shown) |
316 | { | 316 | { |
317 | int fp,fq; | 317 | int fp,fq; |
318 | fp = rb->open("/.rockbox/.memo",O_RDONLY | O_CREAT); | 318 | fp = rb->open(ROCKBOX_DIR "/.memo",O_RDONLY | O_CREAT); |
319 | fq = rb->creat("/.rockbox/~temp"); | 319 | fq = rb->creat(ROCKBOX_DIR "/~temp"); |
320 | if ( (fq != -1) && (fp != -1) ) | 320 | if ( (fq != -1) && (fp != -1) ) |
321 | { | 321 | { |
322 | int i; | 322 | int i; |
@@ -345,7 +345,7 @@ static bool save_memo(int changed, bool new_mod, struct shown *shown) | |||
345 | rb->write(fq,temp,1); | 345 | rb->write(fq,temp,1); |
346 | } | 346 | } |
347 | rb->close(fp); | 347 | rb->close(fp); |
348 | fp = rb->creat("/.rockbox/.memo"); | 348 | fp = rb->creat(ROCKBOX_DIR "/.memo"); |
349 | rb->lseek(fp, 0, SEEK_SET); | 349 | rb->lseek(fp, 0, SEEK_SET); |
350 | rb->lseek(fq, 0, SEEK_SET); | 350 | rb->lseek(fq, 0, SEEK_SET); |
351 | for (i = 0; i < rb->filesize(fq); i++) | 351 | for (i = 0; i < rb->filesize(fq); i++) |
@@ -355,7 +355,7 @@ static bool save_memo(int changed, bool new_mod, struct shown *shown) | |||
355 | } | 355 | } |
356 | rb->close(fp); | 356 | rb->close(fp); |
357 | rb->close(fq); | 357 | rb->close(fq); |
358 | rb->remove("/.rockbox/~temp"); | 358 | rb->remove(ROCKBOX_DIR "/~temp"); |
359 | load_memo(shown); | 359 | load_memo(shown); |
360 | return true; | 360 | return true; |
361 | } | 361 | } |
diff --git a/apps/plugins/lib/configfile.c b/apps/plugins/lib/configfile.c index 54c067c4a7..0fbba81580 100644 --- a/apps/plugins/lib/configfile.c +++ b/apps/plugins/lib/configfile.c | |||
@@ -33,7 +33,7 @@ void get_cfg_filename(char* buf, int buf_len, const char* filename) | |||
33 | s = cfg_rb->strrchr(buf, '/'); | 33 | s = cfg_rb->strrchr(buf, '/'); |
34 | if (!s) /* should never happen */ | 34 | if (!s) /* should never happen */ |
35 | { | 35 | { |
36 | cfg_rb->snprintf(buf, buf_len, "/.rockbox/rocks/%s", filename); | 36 | cfg_rb->snprintf(buf, buf_len, PLUGIN_DIR "/%s", filename); |
37 | } | 37 | } |
38 | else | 38 | else |
39 | { | 39 | { |
diff --git a/apps/plugins/midi/synth.c b/apps/plugins/midi/synth.c index 6ec229b4bf..00a01e41cb 100644 --- a/apps/plugins/midi/synth.c +++ b/apps/plugins/midi/synth.c | |||
@@ -131,7 +131,7 @@ int initSynth(struct MIDIfile * mf, char * filename, char * drumConfig) | |||
131 | while(readChar(file)!=' ' && !eof(file)); | 131 | while(readChar(file)!=' ' && !eof(file)); |
132 | readTextBlock(file, name); | 132 | readTextBlock(file, name); |
133 | 133 | ||
134 | rb->snprintf(fn, 40, "/.rockbox/patchset/%s.pat", name); | 134 | rb->snprintf(fn, 40, ROCKBOX_DIR "/patchset/%s.pat", name); |
135 | /* printf("\nLOADING: <%s> ", fn); */ | 135 | /* printf("\nLOADING: <%s> ", fn); */ |
136 | 136 | ||
137 | if(patchUsed[a]==1) | 137 | if(patchUsed[a]==1) |
@@ -162,7 +162,7 @@ int initSynth(struct MIDIfile * mf, char * filename, char * drumConfig) | |||
162 | { | 162 | { |
163 | readTextBlock(file, number); | 163 | readTextBlock(file, number); |
164 | readTextBlock(file, name); | 164 | readTextBlock(file, name); |
165 | rb->snprintf(fn, 40, "/.rockbox/patchset/%s.pat", name); | 165 | rb->snprintf(fn, 40, ROCKBOX_DIR "/patchset/%s.pat", name); |
166 | 166 | ||
167 | idx = rb->atoi(number); | 167 | idx = rb->atoi(number); |
168 | if(idx == 0) | 168 | if(idx == 0) |
diff --git a/apps/plugins/midi2wav.c b/apps/plugins/midi2wav.c index 368c8b9125..ad41451d88 100644 --- a/apps/plugins/midi2wav.c +++ b/apps/plugins/midi2wav.c | |||
@@ -107,7 +107,8 @@ int midimain(void * filename) | |||
107 | struct MIDIfile * mf = loadFile(filename); | 107 | struct MIDIfile * mf = loadFile(filename); |
108 | 108 | ||
109 | rb->splash(HZ/5, "LOADING PATCHES"); | 109 | rb->splash(HZ/5, "LOADING PATCHES"); |
110 | if (initSynth(mf, "/.rockbox/patchset/patchset.cfg", "/.rockbox/patchset/drums.cfg") == -1) | 110 | if (initSynth(mf, ROCKBOX_DIR "/patchset/patchset.cfg", |
111 | ROCKBOX_DIR "/patchset/drums.cfg") == -1) | ||
111 | { | 112 | { |
112 | return -1; | 113 | return -1; |
113 | } | 114 | } |
diff --git a/apps/plugins/midiplay.c b/apps/plugins/midiplay.c index c19ca04806..59594a97f7 100644 --- a/apps/plugins/midiplay.c +++ b/apps/plugins/midiplay.c | |||
@@ -237,7 +237,8 @@ int midimain(void * filename) | |||
237 | return -1; | 237 | return -1; |
238 | } | 238 | } |
239 | 239 | ||
240 | if (initSynth(mf, "/.rockbox/patchset/patchset.cfg", "/.rockbox/patchset/drums.cfg") == -1) | 240 | if (initSynth(mf, ROCKBOX_DIR "/patchset/patchset.cfg", |
241 | ROCKBOX_DIR "/patchset/drums.cfg") == -1) | ||
241 | return -1; | 242 | return -1; |
242 | 243 | ||
243 | //#ifndef SIMULATOR | 244 | //#ifndef SIMULATOR |
diff --git a/apps/plugins/pacbox/pacbox.c b/apps/plugins/pacbox/pacbox.c index 712c3aff77..fad27358d2 100644 --- a/apps/plugins/pacbox/pacbox.c +++ b/apps/plugins/pacbox/pacbox.c | |||
@@ -68,7 +68,7 @@ static bool loadFile( const char * name, unsigned char * buf, int len ) | |||
68 | { | 68 | { |
69 | char filename[MAX_PATH]; | 69 | char filename[MAX_PATH]; |
70 | 70 | ||
71 | rb->snprintf(filename,sizeof(filename),"/.rockbox/pacman/%s",name); | 71 | rb->snprintf(filename,sizeof(filename), ROCKBOX_DIR "/pacman/%s",name); |
72 | 72 | ||
73 | int fd = rb->open( filename, O_RDONLY); | 73 | int fd = rb->open( filename, O_RDONLY); |
74 | 74 | ||
@@ -419,7 +419,7 @@ enum plugin_status plugin_start(struct plugin_api* api, void* parameter) | |||
419 | SETTINGS_VERSION); | 419 | SETTINGS_VERSION); |
420 | } | 420 | } |
421 | } else { | 421 | } else { |
422 | rb->splash(HZ*2, "No ROMs in /.rockbox/pacman/"); | 422 | rb->splash(HZ*2, "No ROMs in %s/pacman/", ROCKBOX_DIR); |
423 | } | 423 | } |
424 | 424 | ||
425 | #ifdef HAVE_ADJUSTABLE_CPU_FREQ | 425 | #ifdef HAVE_ADJUSTABLE_CPU_FREQ |
diff --git a/apps/plugins/rockboy/menu.c b/apps/plugins/rockboy/menu.c index 0c9e46bbdf..e896e26c20 100644 --- a/apps/plugins/rockboy/menu.c +++ b/apps/plugins/rockboy/menu.c | |||
@@ -35,7 +35,7 @@ static void do_slot_menu(bool is_load); | |||
35 | static void munge_name(char *buf, size_t bufsiz); | 35 | static void munge_name(char *buf, size_t bufsiz); |
36 | 36 | ||
37 | /* directory ROM save slots belong in */ | 37 | /* directory ROM save slots belong in */ |
38 | #define STATE_DIR "/.rockbox/rockboy" | 38 | #define STATE_DIR ROCKBOX_DIR "/rockboy" |
39 | 39 | ||
40 | int getbutton(char *text) | 40 | int getbutton(char *text) |
41 | { | 41 | { |
diff --git a/apps/plugins/rockboy/rockmacros.h b/apps/plugins/rockboy/rockmacros.h index 83b599897e..01beb43fb5 100644 --- a/apps/plugins/rockboy/rockmacros.h +++ b/apps/plugins/rockboy/rockmacros.h | |||
@@ -121,6 +121,6 @@ struct options { | |||
121 | bool plugbuf; | 121 | bool plugbuf; |
122 | 122 | ||
123 | extern struct options options; | 123 | extern struct options options; |
124 | #define savedir "/.rockbox/rockboy" | 124 | #define savedir ROCKBOX_DIR "/rockboy" |
125 | 125 | ||
126 | #endif | 126 | #endif |
diff --git a/apps/plugins/snake2.c b/apps/plugins/snake2.c index dbefef6b7b..385af159e4 100644 --- a/apps/plugins/snake2.c +++ b/apps/plugins/snake2.c | |||
@@ -370,7 +370,7 @@ int load_all_levels(void) | |||
370 | return 0; | 370 | return 0; |
371 | } | 371 | } |
372 | 372 | ||
373 | /*Hi-Score reading and writing to file "/.rockbox/snake2.levels" function */ | 373 | /*Hi-Score reading and writing to file "/.rockbox/rocks/games/snake2.levels" function */ |
374 | void iohiscore(void) | 374 | void iohiscore(void) |
375 | { | 375 | { |
376 | int fd; | 376 | int fd; |
diff --git a/apps/plugins/zxbox/snapshot.c b/apps/plugins/zxbox/snapshot.c index d693d1f6b8..0010550392 100644 --- a/apps/plugins/zxbox/snapshot.c +++ b/apps/plugins/zxbox/snapshot.c | |||
@@ -37,7 +37,7 @@ | |||
37 | 37 | ||
38 | #define COMPRESS_SAVE 1 | 38 | #define COMPRESS_SAVE 1 |
39 | 39 | ||
40 | static char quick_snap_file[]="/.rockbox/zxboxq.z80"; | 40 | static char quick_snap_file[]= ROCKBOX_DIR "/zxboxq.z80"; |
41 | 41 | ||
42 | typedef struct { | 42 | typedef struct { |
43 | int isfile; | 43 | int isfile; |