Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android arm64-v8a - OpenCFile crashs #486

Open
Mac767 opened this issue Jul 22, 2019 · 3 comments
Open

Android arm64-v8a - OpenCFile crashs #486

Mac767 opened this issue Jul 22, 2019 · 3 comments

Comments

@Mac767
Copy link

Mac767 commented Jul 22, 2019

Hi

if I build Monkey2 for arm64-v8a all compiles fine
(after EACCES fix from seyhajin - http://monkeycoder.co.nz/forums/topic/android-64bit-arm64-v8a/#post-16227).

After my App tries to read a config file it crashs at:

2019-07-22 07:43:55.587 18510-18679/com.lb.app I/MX2: Monkey 2 Runtime error: SIGNAL: Memory access violation
2019-07-22 07:43:55.587 18510-18679/com.lb.app I/MX2: {{!DEBUG!}}
2019-07-22 07:43:55.587 18510-18679/com.lb.app I/MX2: >OpenCFile:libc.FILE Ptr(path:monkey.types.String,mode:monkey.types.String);C:/dev/monkey2/modules/std/filesystem/filesystem.monkey2;926;5746
2019-07-22 07:43:55.587 18510-18679/com.lb.app I/MX2: path:String="en.txt"
2019-07-22 07:43:55.587 18510-18679/com.lb.app I/MX2: mode:String="rb"

Line 926 is:
Local asset:=AAssetManager_open( asstMngr,path,0 )
Is differs in my source because I add some debug log output.

The same APK on a armeabi-v7a works fine (compiled for both v7a and v8a in one APK).

I'm using the latst NDK Version (20.0.5594570).

@Mac767
Copy link
Author

Mac767 commented Jul 23, 2019 via email

@nitrologic
Copy link

Apologies, I removed the suggestion after realizing I was confused. I became more confused when
not seeing this in my windows config (macos only?):

'MX2_ANDROID_APP_ABI=all

I assume from your user name you are on Mac and have this switched on to enable the 64 bit mode?

@Mac767
Copy link
Author

Mac767 commented Jul 23, 2019

No, I'm working with Win10.

My android section looks like this:
'***** ANDROID TARGET *****

'Note: Requires Android Studio + Android NDK, see: https://developer.android.com/studio/index.html

'This is where my ndk-bundle is located - yours is probably somewhere else!
'
'For android builds, you need to either set this correctly or make sure 'ndk-build' is available from the command line via you PATH.
'
'PATH=D:\devtools\Android\sdk\ndk-bundle;${PATH}
PATH=C:\apps\Android\Sdk\ndk-bundle;${PATH}

'Application.mk
'
MX2_ANDROID_APP_CFLAGS=-std=gnu99 -fno-stack-protector
MX2_ANDROID_APP_CPPFLAGS=-std=c++11 -fno-stack-protector -frtti -fexceptions
MX2_ANDROID_APP_PLATFORM=android-16
MX2_ANDROID_APP_ABI=armeabi-v7a arm64-v8a
MX2_ANDROID_APP_STL=c++_static

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants