1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Android openGL build fixes.

This commit is contained in:
jules 2011-10-11 12:44:57 +01:00
parent be3565ac98
commit 7a91c10a81
5 changed files with 27 additions and 0 deletions

View file

@ -62,6 +62,8 @@ public:
if (getInternetNeeded().toString().isEmpty())
getInternetNeeded() = true;
androidDynamicLibs.add ("GLESv1_CM");
}
//==============================================================================
@ -241,9 +243,23 @@ private:
<< " LOCAL_CPPFLAGS += " << createCPPFlags (false) << newLine
<< "endif" << newLine
<< newLine
<< getDynamicLibs()
<< newLine
<< "include $(BUILD_SHARED_LIBRARY)" << newLine;
}
String getDynamicLibs()
{
if (androidDynamicLibs.size() == 0)
return String::empty;
String flags ("LOCAL_LDLIBS :=");
for (int i = 0; i < androidDynamicLibs.size(); ++i)
flags << " -l" << androidDynamicLibs[i];
return flags + newLine;
}
String createIncludePathFlags (const Project::BuildConfiguration& config)
{
String flags;

View file

@ -144,6 +144,9 @@ public:
String msvcPostBuildCommand, msvcPostBuildOutputs;
String msvcPreBuildDescription, msvcPreBuildCommand;
//==============================================================================
StringArray androidDynamicLibs;
//==============================================================================
StringArray extraSearchPaths;

View file

@ -52,4 +52,6 @@ else
LOCAL_CPPFLAGS += -fsigned-char -fexceptions -frtti -I "../../JuceLibraryCode" -Os -D "JUCE_ANDROID=1" -D "NDEBUG=1" -D "JUCE_UNIT_TESTS=1" -D "JUCER_ANDROID_7F0E4A25=1"
endif
LOCAL_LDLIBS := -lGLESv1_CM
include $(BUILD_SHARED_LIBRARY)

View file

@ -114,6 +114,10 @@
#undef SIZEOF
#undef KeyPress
//==============================================================================
#elif JUCE_ANDROID
#include <GLES/glext.h>
#endif
//==============================================================================

View file

@ -65,6 +65,8 @@
#elif JUCE_MAC
#include <OpenGL/gl.h>
#include "OpenGL/glext.h"
#elif JUCE_ANDROID
#include <GLES/gl.h>
#endif
#ifndef GL_BGRA_EXT