diff --git a/src/libraries/Box2D/Common/b2BlockAllocator.cpp b/src/libraries/Box2D/Common/b2BlockAllocator.cpp index 59674e81b..f16db7028 100755 --- a/src/libraries/Box2D/Common/b2BlockAllocator.cpp +++ b/src/libraries/Box2D/Common/b2BlockAllocator.cpp @@ -20,6 +20,7 @@ #include #include #include +#include int32 b2BlockAllocator::s_blockSizes[b2_blockSizes] = { diff --git a/src/modules/graphics/opengl/Image.cpp b/src/modules/graphics/opengl/Image.cpp index 52079f5ad..9503d12e6 100644 --- a/src/modules/graphics/opengl/Image.cpp +++ b/src/modules/graphics/opengl/Image.cpp @@ -26,6 +26,16 @@ // STD #include // for min/max +#ifdef LOVE_ANDROID +// log2 is not declared in the math.h shipped with the Android NDK +#include +inline double log2( double n ) +{ + // log(n)/log(2) is log2. + return std::log( n ) / std::log( 2 ); +} +#endif + namespace love { namespace graphics diff --git a/src/modules/sound/lullaby/ModPlugDecoder.h b/src/modules/sound/lullaby/ModPlugDecoder.h index 671059faf..58dd37427 100644 --- a/src/modules/sound/lullaby/ModPlugDecoder.h +++ b/src/modules/sound/lullaby/ModPlugDecoder.h @@ -29,8 +29,12 @@ #include "common/Data.h" #include "Decoder.h" -// SDL_sound +// libmodplug +#ifdef LOVE_ANDROID +#include +#else #include +#endif namespace love {