Merge pull request #2256 from leiradel/master

only add cheevos to the build when HAVE_NETWORKING is enabled
This commit is contained in:
Twinaphex 2015-10-19 17:42:53 +02:00
commit 1aeaff1b2a
2 changed files with 10 additions and 24 deletions

View File

@ -820,13 +820,6 @@ ifeq ($(HAVE_ZLIB_DEFLATE),1)
DEFINES += -DHAVE_ZLIB_DEFLATE
endif
# Retro Achievements
ifeq ($(HAVE_CHEEVOS), 1)
OBJ += cheevos.o libretro-common/utils/md5.o
DEFINES += -DHAVE_CHEEVOS
endif
# Camera
ifeq ($(HAVE_V4L2),1)
@ -834,7 +827,7 @@ ifeq ($(HAVE_V4L2),1)
DEFINES += -DHAVE_V4L2
endif
# Netplay
# Things that depend on network availability
ifeq ($(HAVE_NETWORKING), 1)
DEFINES += -DHAVE_NETWORKING
@ -846,10 +839,19 @@ ifeq ($(HAVE_NETWORKING), 1)
LIBS += -lws2_32
endif
# Netplay
ifeq ($(HAVE_NETPLAY), 1)
DEFINES += -DHAVE_NETPLAY -DHAVE_NETWORK_CMD
OBJ += netplay.o
endif
# Retro Achievements
ifeq ($(HAVE_CHEEVOS), 1)
DEFINES += -DHAVE_CHEEVOS
OBJ += cheevos.o libretro-common/utils/md5.o
endif
endif
ifneq ($(findstring Win32,$(OS)),)

View File

@ -1132,8 +1132,6 @@ Load achievements from retroachievements.org.
static const char* cheevos_http_get( const char* url, size_t* size )
{
#ifdef HAVE_NETWORKING
struct http_connection_t* conn;
struct http_t* http;
uint8_t* data;
@ -1196,20 +1194,6 @@ error1:
}
return (char*)result;
#else /* HAVE_NETWORKING */
RARCH_LOG( "CHEEVOS http get %s\n", url );
RARCH_ERROR( "CHEEVOS Network unavailable\n" );
if ( size )
{
*size = 0;
}
return NULL;
#endif /* HAVE_NETWORKING */
}
typedef struct