Bug 9468 - OutOfMemoryException: Out of memory building
Summary: OutOfMemoryException: Out of memory building
Status: RESOLVED NORESPONSE
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Android Add-in ()
Version: 4.0
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: Alan McGovern
URL:
Depends on:
Blocks:
 
Reported: 2013-01-10 18:23 UTC by gbarnes206
Modified: 2013-12-05 18:34 UTC (History)
1 user (show)

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

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:
Status:
RESOLVED NORESPONSE

Description gbarnes206 2013-01-10 18:23:11 UTC
I encountered this issue when doing command-line based builds for automating the build process: 

Here's the Powershell script used that generated the error: (this script runs 24 times a day, 7 days a week) 
bp is an alias
tf get $location /version:T /recursive /force

Write-Host "Cleaning the Release target..."
bp C:\bin\release\Our.csproj /p:Configuration=Release /t:Clean

# Now build the project, using a the Release target.
Write-Host "Building Release and APK Targets..."
bp C:\bin\release\Our.csproj /p:Configuration=Release /t:SignAndroidPackage

Error: 

"C:\bin\release\Our.csproj" (SignAndroidPackage target) (1) ->
(_Mandroid target) ->
  monodroid : error XA0000: Unexpected error - Please fill a bug report at http://bugzilla.xamarin.com. Reason: System.
OutOfMemoryException: Out of memory [C:\bin\release\Our.csproj]
Comment 1 Alan McGovern 2013-01-14 05:20:55 UTC
By any chance do you have large assets being included as embedded resources in your compiled assemblies? That can trigger this kind of issue. You can check this by looking for the built binaries in either the 'bin' directory or the temporary 'obj' directory inside your project tree and checking the size of every dll or exe in there. If there are large ones (> 100mb) this is likely to be the cause of the problem.

If the assemblies are all 'normal' sized, only a few megabytes, would you be able to provide a copy of the solution so we can reproduce the issue? You can add it as a private attachment to the bug report or email it separately to us if you'd prefer.
Comment 2 PJ 2013-11-19 17:04:13 UTC
This bug has been in the NEEDINFO state with no changes for the last 90 days. Can we put this back into the NEW or CONFIRMED state, or are we still awaiting response?

If there is no change in the status of this bug over the next two weeks, this bug will be marked as NORESPONSE.
Comment 3 PJ 2013-12-05 18:34:13 UTC
This bug has not been changed from the NEEDINFO state since my previous comment, marking as RESOLVED NORESPONSE.

Please feel free to REOPEN this bug at any time if you are still experiencing the issue. Please add the requested information and set the bug back to the NEW (or CONFIRMED) state.