forked from len0rd/rockbox
Add rbcodecplatform.h and rbcodecconfig.h.
librbcodec users must provide these two files when the library is built. rbcodecconfig.h provides configuration #defines and basic types, and will be included by public librbcodec headers, so it must not conflict with the user's code. rbcodecplatform.h provides various OS functions, and will only be included by source files and private headers. This system is intended to provide maximum flexibility for use on embedded systems, where no operating system headers are included. Unix systems can just copy rbcodecconfig-example.h and rbcodecplatform-unix.h with minimal changes. Change-Id: I350a2274d173da391fd1ca00c4202e9760d91def Reviewed-on: http://gerrit.rockbox.org/143 Reviewed-by: Nils Wallménius <nils@rockbox.org> Tested-by: Nils Wallménius <nils@rockbox.org>
This commit is contained in:
parent
5f0cb71361
commit
cadb3627fc
70 changed files with 430 additions and 81 deletions
|
|
@ -22,8 +22,8 @@
|
|||
#include <stdio.h>
|
||||
#include "metadata.h"
|
||||
#include "logf.h"
|
||||
|
||||
#include "metadata_parsers.h"
|
||||
#include "platform.h"
|
||||
|
||||
static const unsigned short a52_bitrates[] =
|
||||
{
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@
|
|||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -24,13 +24,13 @@
|
|||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
|
||||
#include "system.h"
|
||||
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
#include "rbunicode.h"
|
||||
#include "debug.h"
|
||||
|
||||
#include "platform.h"
|
||||
#define MAX_SONGS 32
|
||||
|
||||
static bool parse_dec(int *retval, const char *p, int minval, int maxval)
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "metadata.h"
|
||||
#include "replaygain.h"
|
||||
|
|
@ -31,7 +32,6 @@
|
|||
#include "rbunicode.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
#include "system.h"
|
||||
#include <codecs/libasf/asf.h>
|
||||
|
||||
/* TODO: Just read the GUIDs into a 16-byte array, and use memcmp to compare */
|
||||
|
|
|
|||
|
|
@ -21,8 +21,8 @@
|
|||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -35,11 +35,9 @@
|
|||
#include <stdbool.h>
|
||||
#include <stddef.h>
|
||||
#include <ctype.h>
|
||||
#include "platform.h"
|
||||
#include "string-extra.h"
|
||||
#include "config.h"
|
||||
#include "file.h"
|
||||
#include "logf.h"
|
||||
#include "system.h"
|
||||
#include "replaygain.h"
|
||||
#include "rbunicode.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include "string-extra.h"
|
||||
|
||||
#include "platform.h"
|
||||
#include "debug.h"
|
||||
#include "logf.h"
|
||||
#include "cuesheet.h"
|
||||
|
|
|
|||
|
|
@ -22,10 +22,7 @@
|
|||
#ifndef _METADATA_H
|
||||
#define _METADATA_H
|
||||
|
||||
#include <stdbool.h>
|
||||
#include "config.h"
|
||||
#include "file.h"
|
||||
|
||||
#include "platform.h"
|
||||
|
||||
/* Audio file types. */
|
||||
/* NOTE: The values of the AFMT_* items are used for the %fc tag in the WPS
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@
|
|||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
|
||||
#include "system.h"
|
||||
#include "platform.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include <string-extra.h>
|
||||
#include "metadata_common.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -34,10 +34,9 @@
|
|||
#include <stdbool.h>
|
||||
#include "string-extra.h"
|
||||
#include "config.h"
|
||||
#include "file.h"
|
||||
#include "logf.h"
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "mp3data.h"
|
||||
#include "metadata_common.h"
|
||||
|
|
|
|||
|
|
@ -37,8 +37,7 @@
|
|||
#include "debug.h"
|
||||
#include "logf.h"
|
||||
#include "mp3data.h"
|
||||
#include "file.h"
|
||||
#include "system.h"
|
||||
#include "platform.h"
|
||||
|
||||
//#define DEBUG_VERBOSE
|
||||
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "errno.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@
|
|||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include <inttypes.h>
|
||||
#include "system.h"
|
||||
#include "platform.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
@ -68,7 +68,7 @@ bool get_ogg_metadata(int fd, struct mp3entry* id3)
|
|||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/* All Ogg streams start with OggS */
|
||||
if (memcmp(buf, "OggS", 4) != 0)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -46,6 +46,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <inttypes.h>
|
||||
#include <string.h>
|
||||
#include "platform.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
#include "strlcpy.h"
|
||||
#include "strcasecmp.h"
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "debug.h"
|
||||
#include "replaygain.h"
|
||||
|
|
|
|||
|
|
@ -23,9 +23,9 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include <codecs/librm/rm.h>
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -20,9 +20,9 @@
|
|||
****************************************************************************/
|
||||
#include <inttypes.h>
|
||||
#include <stdio.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "string-extra.h"
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
|
||||
#include "system.h"
|
||||
#include "platform.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@
|
|||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include "platform.h"
|
||||
|
||||
#include "system.h"
|
||||
#include "metadata.h"
|
||||
#include "metadata_common.h"
|
||||
#include "metadata_parsers.h"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue