Added support for Mac OS X and building with clang (bug 5601, r=dvander).

This commit is contained in:
Scott Ehlert
2013-02-13 01:14:37 -06:00
parent b0fe6c83e2
commit 40c1fee55a
191 changed files with 3835 additions and 1946 deletions

View File

@@ -42,7 +42,7 @@
#define PACKED
#endif
#if defined __linux__
#if defined(__linux__) || defined(__APPLE__)
#pragma pack(1) /* structures must be packed (byte-aligned) */
#else
#pragma pack(1) /* structures must be packed (byte-aligned) */
@@ -127,7 +127,7 @@ CAmxxReader::CAmxxReader(const char *filename, int cellsize)
for (mint8_t i = 0; i < m_Bh.numPlugins; i++)
{
pe = &(m_Bh.plugins[i]);
pe = &(m_Bh.plugins[(unsigned)i]);
DATAREAD(&pe->cellsize, sizeof(mint8_t), 1);
DATAREAD(&pe->disksize, sizeof(int32_t), 1);
DATAREAD(&pe->imagesize, sizeof(int32_t), 1);
@@ -137,7 +137,7 @@ CAmxxReader::CAmxxReader(const char *filename, int cellsize)
for (mint8_t i = 0; i < m_Bh.numPlugins; i++)
{
pe = &(m_Bh.plugins[i]);
pe = &(m_Bh.plugins[(unsigned)i]);
if (pe->cellsize == m_CellSize)
{