Fix the cmake build for natty to find the glib libraries properly. Yuck!

Fix a few minor compiler warnings.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7551 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Glenn Rice 2011-05-19 14:26:03 +00:00
parent 48b605df71
commit 47135170d8
3 changed files with 12 additions and 6 deletions

View File

@ -382,9 +382,14 @@ if(NOT DISABLE_WX)
# There is a bug in the FindGTK module in cmake version 2.8.2 that # There is a bug in the FindGTK module in cmake version 2.8.2 that
# does not find gdk-pixbuf-2.0. On the other hand some 2.8.3 # does not find gdk-pixbuf-2.0. On the other hand some 2.8.3
# users have complained that pkg-config does not find # users have complained that pkg-config does not find
# gdk-pixbuf-2.0 # gdk-pixbuf-2.0. On yet another hand, cmake version 2.8.3 in
# Ubuntu Natty does not find the glib libraries correctly.
# Ugly!!!
execute_process(COMMAND lsb_release -c -s
OUTPUT_VARIABLE DIST_NAME
ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE)
if(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}.${CMAKE_PATCH_VERSION} if(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}.${CMAKE_PATCH_VERSION}
VERSION_EQUAL 2.8.2) VERSION_EQUAL 2.8.2 OR "${DIST_NAME}" STREQUAL "natty")
check_lib(GTK2 gtk+-2.0 gtk.h REQUIRED) check_lib(GTK2 gtk+-2.0 gtk.h REQUIRED)
else() else()
include(FindGTK2) include(FindGTK2)

View File

@ -53,7 +53,7 @@ void HLE_IPC_CreateVirtualFATFilesystem()
{ {
const int cdbSize = 0x01400000; const int cdbSize = 0x01400000;
const std::string cdbPath = Common::GetTitleDataPath(TITLEID_SYSMENU) + "cdb.vff"; const std::string cdbPath = Common::GetTitleDataPath(TITLEID_SYSMENU) + "cdb.vff";
if (File::GetSize(cdbPath) < cdbSize) if ((int)File::GetSize(cdbPath) < cdbSize)
{ {
// cdb.vff is a virtual Fat filesystem created on first launch of sysmenu // cdb.vff is a virtual Fat filesystem created on first launch of sysmenu
// we create it here as it is faster ~3 minutes for me when sysmenu does it ~1 second created here // we create it here as it is faster ~3 minutes for me when sysmenu does it ~1 second created here

View File

@ -447,7 +447,7 @@ bool CWII_IPC_HLE_Device_es::IOCtlV(u32 _CommandAddress)
u32 retVal = 0; u32 retVal = 0;
const DiscIO::INANDContentLoader& Loader = AccessContentDevice(TitleID); const DiscIO::INANDContentLoader& Loader = AccessContentDevice(TitleID);
u32 ViewCount = ViewCount = Loader.GetTIKSize() / DiscIO::INANDContentLoader::TICKET_SIZE; u32 ViewCount = Loader.GetTIKSize() / DiscIO::INANDContentLoader::TICKET_SIZE;
if (!ViewCount) if (!ViewCount)
{ {
@ -536,12 +536,13 @@ bool CWII_IPC_HLE_Device_es::IOCtlV(u32 _CommandAddress)
_dbg_assert_msg_(WII_IPC_ES, Buffer.NumberPayloadBuffer == 1, "IOCTL_ES_GETTMDVIEWCNT no out buffer"); _dbg_assert_msg_(WII_IPC_ES, Buffer.NumberPayloadBuffer == 1, "IOCTL_ES_GETTMDVIEWCNT no out buffer");
u64 TitleID = Memory::Read_U64(Buffer.InBuffer[0].m_Address); u64 TitleID = Memory::Read_U64(Buffer.InBuffer[0].m_Address);
u32 TitleID_HI = (u32)(TitleID >> 32);
const DiscIO::INANDContentLoader& Loader = AccessContentDevice(TitleID); const DiscIO::INANDContentLoader& Loader = AccessContentDevice(TitleID);
// Assert if title is not a disc title and the loader is not valid // Assert if title is not a disc title and the loader is not valid
_dbg_assert_msg_(WII_IPC_ES, (TitleID_HI == 0x00010000) || (TitleID_HI == 0x00010004) || Loader.IsValid(), "Loader not valid for TitleID %08x/%08x", TitleID_HI, (u32)TitleID); _dbg_assert_msg_(WII_IPC_ES, ((u32)(TitleID >> 32) == 0x00010000) ||
((u32)(TitleID >> 32) == 0x00010004) || Loader.IsValid(),
"Loader not valid for TitleID %08x/%08x", (u32)(TitleID >> 32), (u32)TitleID);
u32 TMDViewCnt = 0; u32 TMDViewCnt = 0;
if (Loader.IsValid()) if (Loader.IsValid())