summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorBjörn Stenberg <bjorn@haxx.se>2008-12-15 23:42:19 +0000
committerBjörn Stenberg <bjorn@haxx.se>2008-12-15 23:42:19 +0000
commitee46a3d88e8378e58f01ff0d521477ba0b7201fb (patch)
treead63d929d4ebb1f762faf838ee9da965cfc0ab0b /apps
parent9f37f04619feb93a6a5adb36e7db6d7ace3c227c (diff)
downloadrockbox-ee46a3d88e8378e58f01ff0d521477ba0b7201fb.zip
rockbox-ee46a3d88e8378e58f01ff0d521477ba0b7201fb.tar.gz
rockbox-ee46a3d88e8378e58f01ff0d521477ba0b7201fb.tar.bz2
rockbox-ee46a3d88e8378e58f01ff0d521477ba0b7201fb.tar.xz
Moved database builder into a separate directory, and gave it its' own Makefile. Now it compiles cleanly and builds a database if ran in root of music tree.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19448 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r--apps/metadata.c2
-rw-r--r--apps/tagcache.c16
2 files changed, 16 insertions, 2 deletions
diff --git a/apps/metadata.c b/apps/metadata.c
index fa11fa7..0892fc6 100644
--- a/apps/metadata.c
+++ b/apps/metadata.c
@@ -397,6 +397,7 @@ bool get_metadata(struct mp3entry* id3, int fd, const char* trackname)
return true;
}
+#ifndef __PCTOOL__
#if CONFIG_CODEC == SWCODEC
void strip_tags(int handle_id)
{
@@ -434,6 +435,7 @@ void strip_tags(int handle_id)
bufcuttail(handle_id, len);
}
#endif /* CONFIG_CODEC == SWCODEC */
+#endif /* ! __PCTOOL__ */
void adjust_mp3entry(struct mp3entry *entry, void *dest, const void *orig)
{
diff --git a/apps/tagcache.c b/apps/tagcache.c
index b6cfcd5..8e14b9f 100644
--- a/apps/tagcache.c
+++ b/apps/tagcache.c
@@ -155,10 +155,12 @@ struct tagcache_command_entry {
int32_t data;
};
+#ifndef __PCTOOL__
static struct tagcache_command_entry command_queue[TAGCACHE_COMMAND_QUEUE_LENGTH];
static volatile int command_queue_widx = 0;
static volatile int command_queue_ridx = 0;
static struct mutex command_queue_mutex;
+#endif
/* Tag database structures. */
@@ -633,6 +635,8 @@ static bool get_index(int masterfd, int idxid,
return true;
}
+#ifndef __PCTOOL__
+
static bool write_index(int masterfd, int idxid, struct index_entry *idx)
{
/* We need to exclude all memory only flags & tags when writing to disk. */
@@ -678,6 +682,8 @@ static bool write_index(int masterfd, int idxid, struct index_entry *idx)
return true;
}
+#endif /* !__PCTOOL__ */
+
static bool open_files(struct tagcache_search *tcs, int tag)
{
if (tcs->idxfd[tag] < 0)
@@ -2993,6 +2999,8 @@ static void free_tempbuf(void)
tempbuf_size = 0;
}
+#ifndef __PCTOOL__
+
static bool modify_numeric_entry(int masterfd, int idx_id, int tag, long data)
{
struct index_entry idx;
@@ -3040,6 +3048,7 @@ static bool command_queue_is_full(void)
return (next == command_queue_ridx);
}
+
static bool command_queue_sync_callback(void)
{
@@ -3152,6 +3161,7 @@ void tagcache_update_numeric(int idx_id, int tag, long data)
{
queue_command(CMD_UPDATE_NUMERIC, idx_id, tag, data);
}
+#endif /* !__PCTOOL__ */
long tagcache_get_serial(void)
{
@@ -3187,6 +3197,8 @@ static bool write_tag(int fd, const char *tagstr, const char *datastr)
return true;
}
+#ifndef __PCTOOL__
+
static bool read_tag(char *dest, long size,
const char *src, const char *tagstr)
{
@@ -3326,7 +3338,6 @@ static int parse_changelog_line(int line_n, const char *buf, void *parameters)
return write_index(masterfd, idx_id, &idx) ? 0 : -5;
}
-#ifndef __PCTOOL__
bool tagcache_import_changelog(void)
{
struct master_header myhdr;
@@ -3373,7 +3384,8 @@ bool tagcache_import_changelog(void)
return true;
}
-#endif
+
+#endif /* !__PCTOOL__ */
bool tagcache_create_changelog(struct tagcache_search *tcs)
{