RetroArch
util.h
Go to the documentation of this file.
1 /* RetroArch - A frontend for libretro.
2  * Copyright (C) 2015-2016 - Andre Leiradella
3  *
4  * RetroArch is free software: you can redistribute it and/or modify it under the terms
5  * of the GNU General Public License as published by the Free Software Found-
6  * ation, either version 3 of the License, or (at your option) any later version.
7  *
8  * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
9  * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
10  * PURPOSE. See the GNU General Public License for more details.
11  *
12  * You should have received a copy of the GNU General Public License along with RetroArch.
13  * If not, see <http://www.gnu.org/licenses/>.
14  */
15 
16 #ifndef __RARCH_CHEEVOS_UTIL_H
17 #define __RARCH_CHEEVOS_UTIL_H
18 
19 #include <retro_common_api.h>
20 
22 
23 /*****************************************************************************
24 Setup - mainly for debugging
25 *****************************************************************************/
26 
27 /* Define this macro to get extra-verbose log for cheevos. */
28 #undef CHEEVOS_VERBOSE
29 
30 /*****************************************************************************
31 End of setup
32 *****************************************************************************/
33 
34 #define CHEEVOS_TAG "[CHEEVOS]: "
35 #define CHEEVOS_FREE(p) do { void* q = (void*)p; if (q != NULL) free(q); } while (0)
36 
37 #ifdef CHEEVOS_VERBOSE
38 
39 #define CHEEVOS_LOG RARCH_LOG
40 #define CHEEVOS_ERR RARCH_ERR
41 
42 #else
43 
44 #define CHEEVOS_LOG cheevos_log
45 #define CHEEVOS_ERR RARCH_ERR
46 
47 void cheevos_log(const char *fmt, ...);
48 
49 #endif
50 
52 
53 #endif /* __RARCH_CHEEVOS_UTIL_H */
#define RETRO_BEGIN_DECLS
Definition: retro_common_api.h:41
void cheevos_log(const char *fmt,...)
Definition: cheevos.c:309
#define RETRO_END_DECLS
Definition: retro_common_api.h:42