add global proxy / cache settings to httpget class. This removes the need of passing...
[Rockbox.git] / firmware / export / logf.h
blobb706f3a4b0adfcaafc30534548e7aa7646d34e2c
1 /***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
10 * Copyright (C) 2005 by Daniel Stenberg
12 * All files in this archive are subject to the GNU General Public License.
13 * See the file COPYING in the source tree root for full license agreement.
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
18 ****************************************************************************/
19 #ifndef LOGF_H
20 #define LOGF_H
21 #include <config.h>
22 #include <stdbool.h>
23 #include "../include/_ansi.h"
24 #include "debug.h"
26 #ifdef ROCKBOX_HAS_LOGF
28 #ifndef __PCTOOL__
29 #define MAX_LOGF_LINES 1000
30 #define MAX_LOGF_ENTRY 30
31 #define MAX_LOGF_DATASIZE (MAX_LOGF_ENTRY*MAX_LOGF_LINES)
33 extern unsigned char logfbuffer[MAX_LOGF_LINES][MAX_LOGF_ENTRY];
34 extern int logfindex;
35 extern bool logfwrap;
36 #endif /* __PCTOOL__ */
38 #define logf _logf
39 void _logf(const char *format, ...) ATTRIBUTE_PRINTF(1, 2);
41 #else /* !ROCKBOX_HAS_LOGF */
43 /* built without logf() support enabled, replace logf() by DEBUGF() */
44 #define logf(f,args...) DEBUGF(f"\n",##args)
46 #endif /* !ROCKBOX_HAS_LOGF */
48 #endif /* LOGF_H */
50 /* Allow fine tuning (per file) of the logf output */
51 #ifndef LOGF_ENABLE
52 #undef logf
53 #define logf(...)
54 #endif