Ship Android with Keystore : Proguard warning (UE4 4.10.4 / Fmod 1.8)

Hey there. I really need help to be able to ship my game on Google play.
I had a lot of problems with UE4, but now I feel that I’m close to a good result.
Anyway it still doesn’t work and the package stops when I have those warnings :

MainFrameActions: Packaging (Android (All)): [proguard] Warning: org.fmod.MediaCodec$2DataSource: can’t find superclass or interface android.media.MediaDataSource
MainFrameActions: Packaging (Android (All)): [proguard] Warning: org.fmod.MediaCodec: can’t find referenced method ‘void setDataSource(android.media.MediaDataSource)’ in class android.media.MediaExtractor
MainFrameActions: Packaging (Android (All)): [proguard] Warning: org.fmod.MediaCodec$2DataSource: can’t find referenced class android.media.MediaDataSource
MainFrameActions: Packaging (Android (All)): [proguard] Warning: org.fmod.MediaCodec$2DataSource: can’t find referenced class android.media.MediaDataSource
MainFrameActions: Packaging (Android (All)): [proguard] You should check if you need to specify additional program jars.
MainFrameActions: Packaging (Android (All)): [proguard] Warning: there were 3 unresolved references to classes or interfaces.
MainFrameActions: Packaging (Android (All)): [proguard] You may need to specify additional library jars (using ‘-libraryjars’).
MainFrameActions: Packaging (Android (All)): [proguard] Warning: there were 1 unresolved references to program class members.
MainFrameActions: Packaging (Android (All)): [proguard] Your input classes appear to be inconsistent.
MainFrameActions: Packaging (Android (All)): [proguard] You may need to recompile them and try again.
MainFrameActions: Packaging (Android (All)): [proguard] Alternatively, you may have to specify the option
MainFrameActions: Packaging (Android (All)): [proguard] ‘-dontskipnonpubliclibraryclassmembers’.
MainFrameActions: Packaging (Android (All)): BUILD FAILED
MainFrameActions: Packaging (Android (All)): /Users/Tomavatars/NVPACK/android-sdk-macosx/tools/ant/build.xml:871: Please correct the above warnings first.
MainFrameActions: Packaging (Android (All)): Total time: 20 seconds
MainFrameActions: Packaging (Android (All)): BuildCommand.Execute: ERROR: BUILD FAILED
MainFrameActions: Packaging (Android (All)): Program.Main: ERROR: AutomationTool terminated with exception:
MainFrameActions: Packaging (Android (All)): Program.Main: ERROR: Exception in UnrealBuildTool: ERROR: /bin/sh failed with args -c ‘"/Users/Tomavatars/NVPACK/apache-ant-1.8.2/bin/ant" -quiet release’

Do you have a clue about what is happening?
Thank you!

Its complaining because android.media.MediaDataSource may not exist in the Android SDK, but the FMOD java code handles that at runtime with a graceful fallback based on the SDK version.

The warning can be suppressed by adding an extra line in proguard in the FMODStudio_APL.xml:

<proguardAdditions>
	<insert>
		-keep class org.fmod.** {
		*;
		}
		-dontwarn org.fmod.**
	</insert>
</proguardAdditions>

Please let me know if that eliminates those warnings for you, and I’ll roll that into our next patch release.

Hey Geoff. Thanks for the reply.
I decided to upgrade my Mac Os finally and now I can work with UE 4.11.
I followed your new documentation to deploy with Android, but now I’m getting errors at the beginning of the package procedure.
It seems also that Fmod plugin binaries are not built for Android.
I’m sorry, I’m a real noob in programing :confused:

Anyway, if nothing works with 4.11, I’ll try the Proguard solution you gave me.

Also, the pro guard solution can’t work for me as I’m using an Fmod plugin that has no FMODStudio_APL.xml

It work! Hooray!!!
Thanks Geoff!

Great, thanks for letting me know!