output debugf() nicely for simulator builds too
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@895 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
d4c9173888
commit
fb153c5570
2 changed files with 2 additions and 6 deletions
|
@ -215,13 +215,9 @@ void debug_init(void)
|
|||
|
||||
void debugf(char *fmt, ...)
|
||||
{
|
||||
#ifdef DEBUG
|
||||
va_list ap;
|
||||
|
||||
va_start( ap, fmt );
|
||||
vsnprintf( debugmembuf, sizeof(debugmembuf), fmt, ap );
|
||||
vfprintf( stderr, fmt, ap );
|
||||
va_end( ap );
|
||||
printf( "%s", debugmembuf );
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -25,7 +25,7 @@ extern void debugf(char* fmt,...);
|
|||
#ifdef __GNUC__
|
||||
|
||||
/* */
|
||||
#ifdef DEBUG
|
||||
#if defined(DEBUG) || defined(SIMULATOR)
|
||||
#define DEBUGF(...) debugf(__VA_ARGS__)
|
||||
#else
|
||||
#define DEBUGF(...)
|
||||
|
|
Loading…
Reference in a new issue