Merge pull request #351 from libertyernie/fix-compile-new-libs

Fix compilation errors with latest libraries
This commit is contained in:
dborth 2018-07-30 12:08:30 -06:00 committed by GitHub
commit f792c201df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 5607 additions and 5603 deletions

View File

@ -346,7 +346,7 @@ int FileSortCallback(const void *f1, const void *f2)
if(((BROWSERENTRY *)f1)->isdir && !(((BROWSERENTRY *)f2)->isdir)) return -1;
if(!(((BROWSERENTRY *)f1)->isdir) && ((BROWSERENTRY *)f2)->isdir) return 1;
return stricmp(((BROWSERENTRY *)f1)->filename, ((BROWSERENTRY *)f2)->filename);
return strcasecmp(((BROWSERENTRY *)f1)->filename, ((BROWSERENTRY *)f2)->filename);
}
/****************************************************************************
@ -361,7 +361,7 @@ bool IsSz()
char * p = strrchr(browserList[browser.selIndex].filename, '.');
if (p != NULL)
if(stricmp(p, ".7z") == 0)
if(strcasecmp(p, ".7z") == 0)
return true;
}
return false;

View File

@ -563,12 +563,12 @@ static bool ParseDirEntries()
if(ext == NULL)
continue;
if( stricmp(ext, "agb") != 0 && stricmp(ext, "gba") != 0 &&
stricmp(ext, "bin") != 0 && stricmp(ext, "elf") != 0 &&
stricmp(ext, "mb") != 0 && stricmp(ext, "dmg") != 0 &&
stricmp(ext, "gb") != 0 && stricmp(ext, "gbc") != 0 &&
stricmp(ext, "cgb") != 0 && stricmp(ext, "sgb") != 0 &&
stricmp(ext, "zip") != 0 && stricmp(ext, "7z") != 0)
if( strcasecmp(ext, "agb") != 0 && strcasecmp(ext, "gba") != 0 &&
strcasecmp(ext, "bin") != 0 && strcasecmp(ext, "elf") != 0 &&
strcasecmp(ext, "mb") != 0 && strcasecmp(ext, "dmg") != 0 &&
strcasecmp(ext, "gb") != 0 && strcasecmp(ext, "gbc") != 0 &&
strcasecmp(ext, "cgb") != 0 && strcasecmp(ext, "sgb") != 0 &&
strcasecmp(ext, "zip") != 0 && strcasecmp(ext, "7z") != 0)
continue;
}
}

View File

@ -13,12 +13,12 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <wiiuse/wpad.h>
#include <wupc/wupc.h>
#include <sys/stat.h>
#ifdef HW_RVL
#include <di/di.h>
#include <wiiuse/wpad.h>
#include <wupc/wupc.h>
#endif
#include "vbagx.h"

View File

@ -313,7 +313,7 @@ bool InitializeNetwork(bool silent)
break;
}
#else
networkInit = !(if_config(wiiIP, NULL, NULL, true) < 0);
networkInit = !(if_config(wiiIP, NULL, NULL, true, 10) < 0);
#endif
CancelAction();

View File

@ -82,7 +82,7 @@ static void createXMLSetting(const char * name, const char * description, const
mxmlElementSetAttr(item, "description", description);
}
static void createXMLController(unsigned int controller[], const char * name, const char * description)
static void createXMLController(u32 controller[], const char * name, const char * description)
{
item = mxmlNewElement(section, "controller");
mxmlElementSetAttr(item, "name", name);
@ -201,7 +201,9 @@ preparePrefsData ()
createXMLSection("Menu", "Menu Settings");
#ifdef HW_RVL
createXMLSetting("WiimoteOrientation", "Wiimote Orientation", toStr(GCSettings.WiimoteOrientation));
#endif
createXMLSetting("ExitAction", "Exit Action", toStr(GCSettings.ExitAction));
createXMLSetting("MusicVolume", "Music Volume", toStr(GCSettings.MusicVolume));
createXMLSetting("SFXVolume", "Sound Effects Volume", toStr(GCSettings.SFXVolume));
@ -331,7 +333,7 @@ static void loadXMLSetting(float * var, const char * name)
* Load XML elements into variables for a controller mapping
***************************************************************************/
static void loadXMLController(unsigned int controller[], const char * name)
static void loadXMLController(u32 controller[], const char * name)
{
item = mxmlFindElement(xml, xml, "controller", "name", name, MXML_DESCEND);

View File

@ -41,6 +41,7 @@
#include "vba/gba/Sound.h"
extern "C" {
extern char* strcasestr(const char *, const char *);
extern void __exception_setreload(int t);
}
@ -272,7 +273,7 @@ bool SaneIOS(u32 ios)
static bool gecko = false;
static mutex_t gecko_mutex = 0;
static ssize_t __out_write(struct _reent *r, int fd, const char *ptr, size_t len)
static ssize_t __out_write(struct _reent *r, void* fd, const char *ptr, size_t len)
{
if (!gecko || len == 0)
return len;

View File

@ -11,6 +11,7 @@
#define _VBAGX_H_
#include <unistd.h>
#include <sys/param.h>
#include "filelist.h"
#include "utils/FreeTypeGX.h"

View File

@ -32,7 +32,7 @@ u32 FrameTimer = 0;
/*** External 2D Video ***/
/*** 2D Video Globals ***/
GXRModeObj *vmode = NULL; // Graphics Mode Object
unsigned int *xfb[2] = { NULL, NULL }; // Framebuffers
u32 *xfb[2] = { NULL, NULL }; // Framebuffers
int whichfb = 0; // Frame buffer toggle
static Mtx GXmodelView2D;