Start making the logging code more portable

This commit is contained in:
twinaphex 2015-08-29 15:40:23 +02:00
parent 5caf0627f8
commit 5b67aaaa17
4 changed files with 14 additions and 21 deletions

View File

@ -144,11 +144,15 @@ OBJ = griffin/griffin.o $(PLATOBJS)
INCLUDE += -I./libretro-common/include
ifeq ($(HAVE_LOGGER), 1)
CFLAGS += -DHAVE_LOGGER
CFLAGS += -DHAVE_LOGGER
CFLAGS += -DPC_DEVELOPMENT_IP_ADDRESS=\"$(PC_DEVELOPMENT_IP_ADDRESS)\" -DPC_DEVELOPMENT_UDP_PORT=$(PC_DEVELOPMENT_UDP_PORT)
INCLUDE += -Ilogger/netlogger
endif
ifeq ($(platform), wii)
CFLAGS += -DHAVE_SOCKET_LEGACY
endif
ifeq ($(HAVE_LIBRETRO_MANAGEMENT), 1)
CFLAGS += -DHAVE_LIBRETRO_MANAGEMENT
endif

View File

@ -47,6 +47,10 @@
#include <xtl.h>
#include <io.h>
#elif defined(GEKKO)
#include <network.h>
#else
#include <sys/select.h>
#include <sys/types.h>
@ -60,11 +64,12 @@
#include <arpa/inet.h>
#include <netdb.h>
#include <fcntl.h>
#include <errno.h>
#if defined(__CELLOS_LV2__) && !defined(__PSL1GHT__)
#include <cell/sysmodule.h>
#include <netex/net.h>
#include <netex/libnetctl.h>
#include <sys/timer.h>
#ifndef EWOULDBLOCK
#define EWOULDBLOCK SYS_NET_EWOULDBLOCK
@ -76,6 +81,8 @@
#endif
#include <errno.h>
static INLINE bool isagain(int bytes)
{
#if defined(_WIN32)

View File

@ -16,17 +16,6 @@
#if defined(__CELLOS_LV2__)
#include "../../defines/ps3_defines.h"
#ifndef __PSL1GHT__
#include <netex/net.h>
#include <cell/sysmodule.h>
#include <netex/libnetctl.h>
#include <sys/timer.h>
#endif
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#elif defined(GEKKO)
#include <network.h>
#endif
#include <stdio.h>
@ -35,10 +24,7 @@
#include <string.h>
#include <retro_miscellaneous.h>
#ifndef GEKKO
#include <net/net_compat.h>
#endif
#include "logger.h"

View File

@ -14,7 +14,7 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include <net/net.h>
#include <net/compat.h>
#include <stdio.h>
#include <unistd.h>
@ -23,10 +23,6 @@
#include <errno.h>
#include <stdarg.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include "logger.h"
#if !defined(PC_DEVELOPMENT_IP_ADDRESS)