Bug 21034 - mandroid, out of memory
Summary: mandroid, out of memory
Alias: None
Product: Android
Classification: Xamarin
Component: MSBuild ()
Version: 4.12.4
Hardware: Macintosh Mac OS
: Normal normal
Target Milestone: 5.1
Assignee: dean.ellis
Depends on:
Reported: 2014-07-02 03:53 UTC by renan jegouzo
Modified: 2015-02-20 16:17 UTC (History)
4 users (show)

Is this bug a regression?: ---
Last known good build:

complete build log. (524.38 KB, text/plain)
2014-07-02 03:53 UTC, renan jegouzo

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description renan jegouzo 2014-07-02 03:53:55 UTC
Created attachment 7261 [details]
complete build log.

on a 650Mb project, the real project is 2GB but I use only a part of the assets during the dev, waiting a fix for this bug https://bugzilla.xamarin.com/show_bug.cgi?id=20084  
the 650MB version was building well before the last updates.

Target _Mandroid needs to be built as output file 'bin/Debug/chaoDroid.chaoDroid.apk' does not exist.
	Target _Mandroid:
	Target _Mandroid needs to be built as output file 'bin/Debug/chaoDroid.chaoDroid.apk' does not exist.
	Task "Mandroid"
		Using task Mandroid from Xamarin.Android.Tasks.Mandroid, Xamarin.Android.Build.Tasks, Version=, Culture=neutral, PublicKeyToken=null
		Mandroid Task
		  Assemblies: bin/Debug/chaoDroid.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v4.4/Mono.Android.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v4.4/OpenTK.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0/mscorlib.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0/System.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0/System.Xml.Linq.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0/System.Xml.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0/System.Json.dll; /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0/System.Core.dll; /Users/renanyoy/git/aestesis-mono/alibs/AlibDroid/bin/Debug//AlibDroid.dll
		  BuildDirectory: obj/Debug/
		  ReferenceAssembliesDirectory: /Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v4.4;/Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0;/Library/Frameworks/Mono.framework/External/xbuild-frameworks/MonoAndroid/v1.0/Facades/
		  AndroidSdkDirectory: /Users/renanyoy/android sdk/
		  JavaSdkDirectory: /usr/
		  AssetDirectory: obj/Debug/assets/
		  AndroidSdkPlatform: 20
		  MonoAndroidToolsDirectory: /Library/Frameworks/Xamarin.Android.framework/Versions/Current/lib/mandroid/
		  ResourceDirectory: obj/Debug/res/
		  ManifestTemplate: /Users/renanyoy/git/aestesis-mono/auth/chaoDroid/Properties/AndroidManifest.xml
		  Package: chaoDroid.chaoDroid
		  Debug: True
		  UseSharedRuntime: True
		  SupportedAbis: armeabi;armeabi-v7a;x86
		  LinkMode: None
:  monodroiderror XA0000: Unexpected error - Please file a bug report at http://bugzilla.xamarin.com. Reason: Out of memory
	Task "Mandroid" execution -- FAILED
	Done building target "_Mandroid" in project "/Users/renanyoy/git/aestesis-mono/auth/chaoDroid/chaoDroid.csproj".-- FAILED
Done building target "_Mandroid" in project "/Users/renanyoy/git/aestesis-mono/auth/chaoDroid/chaoDroid.csproj" ("/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets"); "Package" depends on it.
Done building target "Package" in project "/Users/renanyoy/git/aestesis-mono/auth/chaoDroid/chaoDroid.csproj" ("/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets"); "SignAndroidPackage" depends on it.
Done building target "SignAndroidPackage" in project "/Users/renanyoy/git/aestesis-mono/auth/chaoDroid/chaoDroid.csproj" ("/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets").
Done building project "/Users/renanyoy/git/aestesis-mono/auth/chaoDroid/chaoDroid.csproj".-- FAILED

my SDKs:
Xamarin Studio
Version 5.1 (build 479)
Installation UUID: 2a46676f-5eb8-4569-9aa7-630cd15bdfc2
	Mono 3.4.0 ((no/954ed3c)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 304000214

Apple Developer Tools
Xcode 5.1.1 (5085)
Build 5B1008


Version: (Business Edition)
Hash: e7f4f92
Build date: 2014-06-18 02:37:27-0400

Version: 4.12.5 (Business Edition)
Android SDK: /Users/renanyoy/android sdk
	Supported Android versions:
		2.3   (API level 10)
		4.0   (API level 14)
		4.0.3 (API level 15)
		4.1   (API level 16)
		4.2   (API level 17)
		4.3   (API level 18)
		4.4   (API level 19)
Java SDK: /usr
java version "1.6.0_65"
Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-11M4609)
Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode)

Build Information
Release ID: 501000479
Git revision: e5a428cec75d4cc7e6e3ccd8192a3660d013e7dc
Build date: 2014-06-26 09:28:17-04
Xamarin addins: 190d93e026e17280e75a3680ef38f2630b9228d3

Operating System
Mac OS X 10.9.3
Darwin macbook.home 13.2.0 Darwin Kernel Version 13.2.0
    Thu Apr 17 23:03:13 PDT 2014
    root:xnu-2422.100.13~1/RELEASE_X86_64 x86_64
Comment 1 renan jegouzo 2014-07-14 00:21:15 UTC
what is the maximum apk size possible with xamarin for now ?
Comment 2 Alex 2015-02-19 08:19:14 UTC
Where can I find this information?
Comment 3 renan jegouzo 2015-02-19 08:34:55 UTC
there is near no limit now, but it's better to use a zip file with all your data.

this zip file can also be distributed on the google play store among your app.
Comment 4 Jonathan Pryor 2015-02-19 14:27:23 UTC
Comment #3 appears to have no bearing on the bug at hand, as the bug has nothing to do with the maximum .apk size that Google will accept.

The bug is that if the project is too big, the Xamarin.Android tools OOM while attempting to generate the .apk. That's a different matter entirely, and is absolutely something we need to address.
Comment 5 renan jegouzo 2015-02-19 18:55:29 UTC
sry, I though it was fixed: https://bugzilla.xamarin.com/show_bug.cgi?id=20084
Comment 6 dean.ellis 2015-02-20 12:47:22 UTC
Fixed in monodroid/master/30cd85a0