Android build quick start guide

Discussion of issues specific to mobile platforms such as iOS, Android, Symbian and Meego.
Post Reply
sknipas
Gnoblar
Posts: 2
Joined: Fri Nov 16, 2012 2:30 am

Re: Android build quick start guide

Post by sknipas » Fri Nov 16, 2012 5:02 am

My bad! Forgot to issue an ndk-build now works perfectly
0 x

cww
Gnoblar
Posts: 15
Joined: Thu Nov 22, 2012 4:56 pm

Re: Android build quick start guide

Post by cww » Thu Nov 22, 2012 5:09 pm

I managed to build for android by using cmake and then going into SampleBrowserNDK folder and issue a ndk-build.

However, after ndk-build clean, I can't build it again as I run into a lot of undefined references. Any idea how to resolve these? Extracted example:

/Users/cww/Documents/workspace/Ogre/OgreMercurial_v1.9/AndroidDependencies/lib/armeabi/libfreetype.a(ftgzip.c.o): In function `inflate.constprop.1':
ftgzip.c:(.text.inflate.constprop.1+0x42): undefined reference to `__gnu_thumb1_case_uhi'
ftgzip.c:(.text.inflate.constprop.1+0x2e8): undefined reference to `__gnu_thumb1_case_uhi'
ftgzip.c:(.text.inflate.constprop.1+0x85c): undefined reference to `__gnu_thumb1_case_uhi'
collect2: ld returned 1 exit status
make: *** [obj/local/armeabi/libOgreSampleBrowser.so] Error 1

Thanks in advance for any help.
PS: I am using a Mac.
0 x

dudeabot
Gnome
Posts: 334
Joined: Thu Jun 28, 2007 2:12 pm
Location: Brazil
Contact:

Re: Android build quick start guide

Post by dudeabot » Thu Nov 22, 2012 10:19 pm

humm dont use NDK r8b (it seems)

r8c or r8

[]'s
0 x

cww
Gnoblar
Posts: 15
Joined: Thu Nov 22, 2012 4:56 pm

Re: Android build quick start guide

Post by cww » Fri Nov 23, 2012 1:39 am

EDIT: It was an error on my configuration. There was an old entry in my PATH that was pointing to r8 that my eyes failed to detect and I recently added a newer entry pointing to r8c. Hence when I run ndk-build in command line it was calling the r8 version but my Orgre Android was compiled using r8c.

Thanks for the help.
0 x

User avatar
luis
Greenskin
Posts: 119
Joined: Tue Mar 02, 2004 3:33 pm
Location: Spain / Argentina
x 4
Contact:

Re: Android build quick start guide

Post by luis » Wed Nov 28, 2012 12:01 pm

hello people,
I can't make it work...
I'm using this guide: http://www.ogre3d.org/tikiwiki/tiki-ind ... on=Android
Visual studio express 2008, Windows XP
Ogre unstable 1.9 (sinbad-ogre-v1-9-adfa6903083a)
ndk version: android-ndk-r8
cmake version: 2.8
ant: 1.8.4
jdk: 6.0_32 (irrelevant here)

The problem I have is that fails when linking SampleBrowser, also I can't compile dependencies if I do step 6 (build deps) I have this error:

Code: Select all

C:\luis\auxi\apis\sinbad-ogre-v1-9-adfa6903083a\build>cmake -G"NMake Makefiles" -DCMAKE_TOOLCHAIN_FILE=..\cmake\android.toolchain.cmake -DAN
DROID_ABI=armeabi ..
CMake Error at C:/Archivos de programa/CMake 2.8/share/cmake-2.8/Modules/CMakeDetermineSystem.cmake:95 (message):
  Could not find toolchain file: ..\cmake\android.toolchain.cmake
Call Stack (most recent call first):
  CMakeLists.txt:44 (project)


CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_C_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_C_COMPILER
CMake Error: Could not find cmake module file:C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/build/CMakeFiles/2.8.10.1/CMakeCCompiler.cmake

CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_CXX_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_CXX_COMPILER
CMake Error: Could not find cmake module file:C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/build/CMakeFiles/2.8.10.1/CMakeCXXCompiler.cma
ke
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!

I'm doing it inside "build" directory because cmake directory doesn't exists at the same level than sinbad-ogre-v1-9-adfa6903083a (the path in the comand is "..\cmake\android.toolchain.cmake"). Perhaps this guide is wrong, or android.toolchain.cmake file for deps is missing in the repository/zips ?

So, I skiped that step and tried step 7 with both options, armeabi and armeabi v7 in the first option (armeabi) after compiling I get this error:

Code: Select all

C:/android/android-ndk-r8/toolchains/arm-linux-androideabi-4.4.3/prebuilt/windows/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm
-linux-androideabi/bin/ld.exe: Warning: C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/AndroidDependencies/lib/armeabi\libOIS.a(OISKeyboard
.cpp.o): Unknown EABI object attribute 44
C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/AndroidDependencies/lib/armeabi\libzzip.a(file.c.o): In function `zzip_freopen':
file.c:(.text.zzip_freopen+0x78): undefined reference to `__gnu_thumb1_case_shi'
and with armeabi v7 I get:

Code: Select all

C:/android/android-ndk-r8/toolchains/arm-linux-androideabi-4.4.3/prebuilt/windows/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm
-linux-androideabi/bin/ld.exe: Warning: C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/AndroidDependencies/lib/armeabi-v7a\libOIS.a(OISKeyb
oard.cpp.o): Unknown EABI object attribute 44
C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/AndroidDependencies/lib/armeabi-v7a\libFreeImage.a(IlmThreadPool.cpp.o): In function `IlmThr
ead::(anonymous namespace)::WorkerThread::run()':
IlmThreadPool.cpp:(.text._ZN9IlmThread12_GLOBAL__N_112WorkerThread3runEv+0x24): undefined reference to `std::__detail::_List_node_base::_M_u
nhook()'
C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/AndroidDependencies/lib/armeabi-v7a\libFreeImage.a(IlmThreadPool.cpp.o): In function `IlmThr
ead::ThreadPool::setNumThreads(int)':
IlmThreadPool.cpp:(.text._ZN9IlmThread10ThreadPool13setNumThreadsEi+0x56): undefined reference to `std::__detail::_List_node_base::_M_hook(s
td::__detail::_List_node_base*)'
IlmThreadPool.cpp:(.text._ZN9IlmThread10ThreadPool13setNumThreadsEi+0xb6): undefined reference to `std::__detail::_List_node_base::_M_hook(s
td::__detail::_List_node_base*)'
C:/luis/auxi/apis/sinbad-ogre-v1-9-adfa6903083a/AndroidDependencies/lib/armeabi-v7a\libFreeImage.a(IlmThreadPool.cpp.o): In function `IlmThr
ead::ThreadPool::addTask(IlmThread::Task*)':
IlmThreadPool.cpp:(.text._ZN9IlmThread10ThreadPool7addTaskEPNS_4TaskE+0x50): undefined reference to `std::__detail::_List_node_base::_M_hook
(std::__detail::_List_node_base*)'
collect2: ld returned 1 exit status
make: *** [obj/local/armeabi-v7a/libOgreSampleBrowser.so] Error 1
Buildfile: C:\luis\auxi\apis\sinbad-ogre-v1-9-adfa6903083a\build\SampleBrowserNDK\build.xml


any ideas ?
thanks!
0 x

User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 1
Contact:

Re: Android build quick start guide

Post by Wolfmanfx » Wed Nov 28, 2012 12:13 pm

Do you use the official NDK 0.8c from google or which version do you use?
0 x

User avatar
luis
Greenskin
Posts: 119
Joined: Tue Mar 02, 2004 3:33 pm
Location: Spain / Argentina
x 4
Contact:

Re: Android build quick start guide

Post by luis » Wed Nov 28, 2012 12:21 pm

thanks for replying ;)
Wolfmanfx wrote:Do you use the official NDK 0.8c from google or which version do you use?
I'm using the zip in the step 4 in the wiki:
http://dl.google.com/android/ndk/androi ... indows.zip
0 x

User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 1
Contact:

Re: Android build quick start guide

Post by Wolfmanfx » Wed Nov 28, 2012 12:29 pm

Yeah this wont work i builded the deps with 0.8c so use this
http://dl.google.com/android/ndk/androi ... indows.zip

[edit]: I have updated the wiki
0 x

User avatar
luis
Greenskin
Posts: 119
Joined: Tue Mar 02, 2004 3:33 pm
Location: Spain / Argentina
x 4
Contact:

Re: Android build quick start guide

Post by luis » Wed Nov 28, 2012 3:05 pm

Wolfmanfx wrote:Yeah this wont work i builded the deps with 0.8c so use this
http://dl.google.com/android/ndk/androi ... indows.zip

[edit]: I have updated the wiki
it works! thank you ;)
I can't believe I'm seeing Ogre in my tablet....

The only thing it isn't working in the wiki is the step 6 (compiling deps). The file "..\cmake\android.toolchain.cmake" is missing...
0 x

User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 1
Contact:

Re: Android build quick start guide

Post by Wolfmanfx » Wed Nov 28, 2012 3:23 pm

For compiling the deps you have to checkout the deps repo so it wont work with ogre source tree.
Glad you got it working.
0 x

User avatar
luis
Greenskin
Posts: 119
Joined: Tue Mar 02, 2004 3:33 pm
Location: Spain / Argentina
x 4
Contact:

Re: Android build quick start guide

Post by luis » Wed Nov 28, 2012 3:38 pm

Wolfmanfx wrote:For compiling the deps you have to checkout the deps repo so it wont work with ogre source tree.
Glad you got it working.
oh great then, it's been a long time not compiling nor using Ogre ;)
Thanks for your support, I'm glad you're now an ogre team member & Ogre have (will have) an official support for android, that's one of the reasons I'm trying to convice people at work to use this great engine!
0 x

User avatar
Argosse
Gnoblar
Posts: 17
Joined: Wed Apr 27, 2011 9:43 pm

Re: Android build quick start guide

Post by Argosse » Mon Dec 03, 2012 3:12 am

Im trying to initialize Ogre in my android app. I only have the emulator to use for the time being. I have created a new class that inherits from the devtech NVGLES2Activity. Overridden all the required functions.

Code: Select all

extern "C" {

jboolean Java_com_example_testapp_NativeLaunch_initOgre(JNIEnv* env, jobject thiz)
{
			Ogre::StaticPluginLoader* mStaticPluginLoader;
			Ogre::Root* mRoot = OGRE_NEW Ogre::Root();
			mStaticPluginLoader = OGRE_NEW Ogre::StaticPluginLoader();
			mStaticPluginLoader->load();

			mRoot->initialise(false);
	};
}
And heres the logcat output for the app from start to the native launch. It looks like everything goes well. OgreMain and RenderSystem_GLES2Static gets loaded.
**Last 6 lines of log are the problem.

Code: Select all

12-02 15:00:29.669: D/gralloc_goldfish(608): Emulator without GPU emulation detected.
12-02 15:04:07.767: D/dalvikvm(608): GC_CONCURRENT freed 306K, 4% free 9979K/10375K, paused 12ms+12ms
12-02 17:49:38.831: D/dalvikvm(608): GC_CONCURRENT freed 441K, 6% free 9976K/10567K, paused 10ms+12ms
12-02 17:50:40.796: E/SurfaceTextureClient(608): queueBuffer: error queuing buffer to SurfaceTexture, -19
12-02 17:50:40.796: E/SurfaceTextureClient(608): queueBuffer (handle=0x126248) failed (No such device)
12-02 17:50:40.796: D/AndroidRuntime(608): Shutting down VM
12-02 17:50:40.796: W/dalvikvm(608): threadid=1: thread exiting with uncaught exception (group=0x409961f8)
12-02 17:57:44.462: D/gralloc_goldfish(1137): Emulator without GPU emulation detected.
12-02 18:01:18.499: D/dalvikvm(1137): GC_CONCURRENT freed 305K, 4% free 9980K/10375K, paused 12ms+11ms
12-02 18:02:31.569: D/TestAppMain:(1137): NextButton: onClick() called.
12-02 18:02:31.782: D/TestAppMain:(1137): onClick() ended - start button
12-02 18:02:45.060: D/Activity_2:(1137): Application main menu button was pressed.
12-02 18:02:46.030: D/dalvikvm(1137): Trying to load lib /data/data/com.example.testapp/lib/libmyOgreBase.so 0x41342a78
12-02 18:02:46.299: D/dalvikvm(1137): Added shared lib /data/data/com.example.testapp/lib/libmyOgreBase.so 0x41342a78
12-02 18:02:48.299: E/Copy Assets Function2(1137): images
12-02 18:02:48.299: E/Copy Assets Function2(1137): myFiles
12-02 18:02:48.320: E/Copy Assets Function2(1137): plugins
12-02 18:02:48.320: E/Copy Assets Function2(1137): sounds
12-02 18:02:48.419: E/Copy Assets Function2(1137): webkit
12-02 18:02:55.439: D/NativeLaunch:(1137): Application main menu button was pressed.
12-02 18:02:55.620: I/OGRE(1137): Creating resource group General
12-02 18:02:55.629: I/OGRE(1137): Creating resource group Internal
12-02 18:02:55.649: I/OGRE(1137): Creating resource group Autodetect
12-02 18:02:55.659: I/OGRE(1137): SceneManagerFactory for type 'DefaultSceneManager' registered.
12-02 18:02:55.755: I/OGRE(1137): Registering ResourceManager for type Material
12-02 18:02:55.755: I/OGRE(1137): Registering ResourceManager for type Mesh
12-02 18:02:55.779: I/OGRE(1137): Registering ResourceManager for type Skeleton
12-02 18:02:55.779: I/OGRE(1137): MovableObjectFactory for type 'ParticleSystem' registered.
12-02 18:02:55.812: I/OGRE(1137): OverlayElementFactory for type Panel registered.
12-02 18:02:55.812: I/OGRE(1137): OverlayElementFactory for type BorderPanel registered.
12-02 18:02:55.869: I/OGRE(1137): OverlayElementFactory for type TextArea registered.
12-02 18:02:55.869: I/OGRE(1137): Registering ResourceManager for type Font
12-02 18:02:55.869: I/OGRE(1137): ArchiveFactory for archive type FileSystem registered.
12-02 18:02:55.882: I/OGRE(1137): ArchiveFactory for archive type Zip registered.
12-02 18:02:55.882: I/OGRE(1137): ArchiveFactory for archive type EmbeddedZip registered.
12-02 18:02:55.901: I/OGRE(1137): FreeImage version: 3.15.3
12-02 18:02:55.901: I/OGRE(1137): This program uses FreeImage, a free, open source image library supporting all common bitmap formats. See http://freeimage.sourceforge.net for details
12-02 18:02:55.929: I/OGRE(1137): Supported formats: bmp,ico,jpg,jif,jpeg,jpe,jng,koa,iff,lbm,mng,pbm,pbm,pcd,pcx,pgm,pgm,png,ppm,ppm,ras,tga,targa,tif,tiff,wap,wbmp,wbm,psd,cut,xbm,xpm,gif,hdr,g3,sgi,exr,j2k,j2c,jp2,pfm,pct,pict,pic,3fr,arw,bay,bmq,cap,cine,cr2,crw,cs1,dc2,dcr,drf,dsc,dng,erf,fff,ia,iiq,k25,kc2,kdc,mdc,mef,mos,mrw,nef,nrw,orf,pef,ptx,pxn,qtk,raf,raw,rdc,rw2,rwl,rwz,sr2,srf,srw,sti
12-02 18:02:55.929: I/OGRE(1137): PVRTC codec registering
12-02 18:02:55.949: I/OGRE(1137): ETC1 codec registering
12-02 18:02:55.949: I/OGRE(1137): Registering ResourceManager for type HighLevelGpuProgram
12-02 18:02:56.009: I/OGRE(1137): Registering ResourceManager for type Compositor
12-02 18:02:56.049: I/OGRE(1137): MovableObjectFactory for type 'Entity' registered.
12-02 18:02:56.059: I/OGRE(1137): MovableObjectFactory for type 'Light' registered.
12-02 18:02:56.069: I/OGRE(1137): MovableObjectFactory for type 'BillboardSet' registered.
12-02 18:02:56.079: I/OGRE(1137): MovableObjectFactory for type 'ManualObject' registered.
12-02 18:02:56.090: I/OGRE(1137): MovableObjectFactory for type 'BillboardChain' registered.
12-02 18:02:56.109: I/OGRE(1137): MovableObjectFactory for type 'RibbonTrail' registered.
12-02 18:02:56.109: E/OGRE(1137): OGRE EXCEPTION(6:FileNotFoundException): 'plugins.cfg' file not found! in ConfigFile::load at ..\..\OgreMain\src\OgreConfigFile.cpp (line 88)
12-02 18:02:56.169: I/OGRE(1137): plugins.cfg not found, automatic plugin loading disabled.
12-02 18:02:56.169: I/OGRE(1137): *-*-* OGRE Initialising
12-02 18:02:56.169: I/OGRE(1137): *-*-* Version 2.1.0unstable (unnamed)
12-02 18:02:56.180: E/OGRE(1137): OGRE EXCEPTION(1:InvalidStateException): Cannot initialise - no render system has been selected. in Root::initialise at ..\..\OgreMain\src\OgreRoot.cpp (line 666)
12-02 18:02:56.189: A/libc(1137): Fatal signal 11 (SIGSEGV) at 0xdeadbaad (code=1)
Tell me if anymore info is needed. Thanks in advance.
0 x

User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 1
Contact:

Re: Android build quick start guide

Post by Wolfmanfx » Mon Dec 03, 2012 7:05 am

12-02 15:00:29.669: D/gralloc_goldfish(608): Emulator without GPU emulation detected.

Without GPU it wonna suck also the emulator suxs in general with 3d stuff so without device it wont make fun.
0 x

HoneyBunchesOfOats
Gnoblar
Posts: 9
Joined: Thu Mar 25, 2010 9:04 am

Re: Android build quick start guide

Post by HoneyBunchesOfOats » Mon Dec 03, 2012 12:41 pm

I've followed the instructions and seem to be getting errors.

This is my error log.

Would someone be able to help me with this?

Thanks you :oops:
Attachments
CMakeError.log
(7.04 KiB) Downloaded 95 times
0 x

User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 1
Contact:

Re: Android build quick start guide

Post by Wolfmanfx » Mon Dec 03, 2012 12:58 pm

Your paths contains spaces thats not gonna work at least when you gonna compile with the android gcc
0 x

User avatar
Argosse
Gnoblar
Posts: 17
Joined: Wed Apr 27, 2011 9:43 pm

Re: Android build quick start guide

Post by Argosse » Mon Dec 03, 2012 10:58 pm

Am I initializing Ogre::Root* mRoot correctly? Im on the trail of getting plugins.cfg copied from apk to filesystem. But am I initializing the root correctly? Is it just the emulator?
0 x

HoneyBunchesOfOats
Gnoblar
Posts: 9
Joined: Thu Mar 25, 2010 9:04 am

Re: Android build quick start guide

Post by HoneyBunchesOfOats » Thu Dec 06, 2012 4:55 am

I've followed the quick guide to the letter using both the cmake gui and the command line version but i still can't seem to get it to work.

For the android toolchain file, should i be using the one provided in the cmake folder in the ogre folder?

I've provided the error log at the bottom.

Does anyone have a more concrete step by step guide they can help me with?

Thank you :oops:
Attachments
CMakeError.log
(7 KiB) Downloaded 75 times
0 x

User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 1
Contact:

Re: Android build quick start guide

Post by Wolfmanfx » Thu Dec 06, 2012 8:39 am

You have to start the visual studio command prompt! Nmake is needed which is part visual studio
0 x

HoneyBunchesOfOats
Gnoblar
Posts: 9
Joined: Thu Mar 25, 2010 9:04 am

Re: Android build quick start guide

Post by HoneyBunchesOfOats » Fri Dec 07, 2012 11:34 am

For some reason the build progress seems to run into errors with regards to the portion where its trying to find cpu-features.
Did anyone else run into the same problem? I've listed the error below.

Thank you :oops:

[ 32%] Building CXX object OgreMain/CMakeFiles/OgreMain.dir/src/OgrePlatformInfo
rmation.cpp.o
In file included from ..\..\OgreMain\include/OgreStableHeaders.h:38,
from ..\..\OgreMain\src\OgrePlatformInformation.cpp:28:
..\..\OgreMain\include/OgrePlatform.h:279:1: warning: "OGRE_DEBUG_MODE" redefine
d
..\..\OgreMain\include/OgrePlatform.h:253:1: warning: this is the location of th
e previous definition
..\..\OgreMain\include/OgrePlatform.h:284:1: warning: "OGRE_DEBUG_MODE" redefine
d
..\..\OgreMain\include/OgrePlatform.h:279:1: warning: this is the location of th
e previous definition
..\..\OgreMain\src\OgrePlatformInformation.cpp:44:34: error: cpu-features.h: No
such file or directory
0 x

User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 1
Contact:

Re: Android build quick start guide

Post by Wolfmanfx » Fri Dec 07, 2012 1:20 pm

wrong sdk version at least android-9
0 x

HoneyBunchesOfOats
Gnoblar
Posts: 9
Joined: Thu Mar 25, 2010 9:04 am

Re: Android build quick start guide

Post by HoneyBunchesOfOats » Sat Dec 08, 2012 2:54 pm

Thank you for all the help thats been provided so far but i'm still getting the same error. I've included a screenshot below as to my cmake settings.
I've downloaded the files provided in the links on the wiki page. I've tried both Android ABI options, v7a and armeabi. The target API i've tested building for both 9 and 14.

I've even checked the MD5 hash tags to see if my files were corruputed in anyway while downloading them. It still throws an error at the cpu features header seemingly unable to find the file.

I've tried searching the forums for threads with similar issues but was unsuccessful.

This is the error i've gotten:
[ 0%] Building CXX object OgreMain/CMakeFiles/OgreMain.dir/src/OgrePlatformInfo
rmation.cpp.o
..\..\OgreMain\src\OgrePlatformInformation.cpp:44:34: error: cpu-features.h: No such file or directory
..\..\OgreMain\src\OgrePlatformInformation.cpp: In function 'Ogre::uint Ogre::_detectCpuFeatures()':
..\..\OgreMain\src\OgrePlatformInformation.cpp:473: error: 'android_getCpuFeatures' was not declared in this scope
..\..\OgreMain\src\OgrePlatformInformation.cpp:475: error: 'ANDROID_CPU_ARM_FEATURE_NEON' was not declared in this scope
..\..\OgreMain\src\OgrePlatformInformation.cpp:480: error: 'ANDROID_CPU_ARM_FEATURE_VFPv3' was not declared in this scope
..\..\OgreMain\src\OgrePlatformInformation.cpp: In function 'Ogre::String Ogre::_detectCpuIdentifier()':

These are my cmake settings:
http://imgur.com/a/i6pEX

Thank you for taking the time to read this.
0 x

dudeabot
Gnome
Posts: 334
Joined: Thu Jun 28, 2007 2:12 pm
Location: Brazil
Contact:

Re: Android build quick start guide

Post by dudeabot » Sun Dec 09, 2012 4:49 am

are you compiling against branch 1.9? i remember having similar erros trying to compile the wrong ogre version
0 x

HoneyBunchesOfOats
Gnoblar
Posts: 9
Joined: Thu Mar 25, 2010 9:04 am

Re: Android build quick start guide

Post by HoneyBunchesOfOats » Sun Dec 09, 2012 5:55 am

Yes. I checked out a fresh copy through bitbucket.

Edit: Finally got it to work. thanks for the help
0 x

MelodiacMind
Gnoblar
Posts: 1
Joined: Wed Nov 28, 2012 5:42 pm

Re: Android build quick start guide

Post by MelodiacMind » Tue Dec 11, 2012 8:34 pm

Thanks a lot Wolfmanfx!

This is great and eases a lot my job of porting a Windows/Mogre based game to Android.
When building for Android it's always nice being able to work with managed languages, namely Java (with the Dalvik VM) or C# (using Mono For Android). In my case I'm trying MonoDroid out but you know it doesn't get along with Mogre :(

I guess you have worked on using SWIG generated P/INVOKE wrappers before (I read it somewhere in an old post) Have you tried it in Android too?
I'm about to start creating a swig-powered wrapper for v1.8.1 and I want to try it in Android. If you could also share some of your experience with swig (possibly scripts and .i files) it would be great!!

I was also wondering if it wouldn't be a nice occasion to resurrect OgreDotNet? With some support I'd be willing to do so - I know this last subject belongs to another forum sorry :P
0 x

Yati
Greenskin
Posts: 115
Joined: Thu Jun 09, 2011 5:41 am
Location: Melbourne, Australia

Re: Android build quick start guide

Post by Yati » Wed Dec 12, 2012 10:21 pm

Hi,

I'm having the same problem as luis: could not find toolchain file - ..\cmake\toolchain\android.toolchain.cmake

But unlike luis I get it for both step 6 & 7. And I actually can't find android.toolchain.cmake on my machine, does it come with NDK r8c?

thanks!
0 x

Post Reply