-Changed code to use Yabause's logging system, fixed a few odd things

This commit is contained in:
cyberwarriorx 2006-04-14 00:32:35 +00:00
parent 435a82a144
commit 619c90e81c
3 changed files with 33 additions and 3 deletions

View File

@ -5,6 +5,6 @@ libdesmume_a_SOURCES = \
arm_instructions.cpp arm_instructions.hpp \ arm_instructions.cpp arm_instructions.hpp \
bios.cpp bios.hpp cp15.cpp cp15.hpp \ bios.cpp bios.hpp cp15.cpp cp15.hpp \
Disassembler.cpp Disassembler.hpp \ Disassembler.cpp Disassembler.hpp \
GPU.cpp GPU.hpp log.cpp log.hpp \ GPU.cpp GPU.hpp debug.c debug.h \
MMU.cpp MMU.hpp NDSSystem.cpp NDSSystem.hpp \ MMU.cpp MMU.hpp NDSSystem.cpp NDSSystem.hpp \
thumb_instructions.cpp thumb_instructions.hpp thumb_instructions.cpp thumb_instructions.hpp

View File

@ -3,7 +3,7 @@
#include <stdio.h> #include <stdio.h>
#include "log.h" #include "debug.h"
#endif /*__CONFIG_H__*/ #endif /*__CONFIG_H__*/

View File

@ -1,7 +1,7 @@
#ifndef DEBUG_H #ifndef DEBUG_H
#define DEBUG_H #define DEBUG_H
#include "core.h" #include "types.h"
#include <stdio.h> #include <stdio.h>
typedef enum { DEBUG_STRING, DEBUG_STREAM , DEBUG_STDOUT, DEBUG_STDERR } DebugOutType; typedef enum { DEBUG_STRING, DEBUG_STREAM , DEBUG_STDOUT, DEBUG_STDERR } DebugOutType;
@ -33,4 +33,34 @@ void LogStop(void);
#define LOG(f, r...) #define LOG(f, r...)
#endif #endif
#ifdef GPUDEBUG
#define GPULOG(f, r...) DebugPrintf(MainLog, __FILE__, __LINE__, f, ## r)
#else
#define GPULOG(f, r...)
#endif
#ifdef DIVDEBUG
#define DIVLOG(f, r...) DebugPrintf(MainLog, __FILE__, __LINE__, f, ## r)
#else
#define DIVLOG(f, r...)
#endif
#ifdef SQRTDEBUG
#define SQRTLOG(f, r...) DebugPrintf(MainLog, __FILE__, __LINE__, f, ## r)
#else
#define SQRTLOG(f, r...)
#endif
#ifdef CARDDEBUG
#define CARDLOG(f, r...) DebugPrintf(MainLog, __FILE__, __LINE__, f, ## r)
#else
#define CARDLOG(f, r...)
#endif
#ifdef DMADEBUG
#define DMALOG(f, r...) DebugPrintf(MainLog, __FILE__, __LINE__, f, ## r)
#else
#define DMALOG(f, r...)
#endif
#endif #endif