Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
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
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.
It is not possible to turn off "Embed assemblies in native code" from the GUI after ending a Trial.
## Steps to reproduce
1. Open an Android project as a non-enterprise user.
2. Turn on "Project Options -> Build -> Android Build -> Packaging -> Embed assemblies in native code".
3. Choose "Begin a Trial".
4. Save the project with "Embed assemblies in native code" switched on.
5. Close the project.
6. End the Trial.
7. Open the project, and go to "Project Options -> Build -> Android Build -> Packaging".
8. You will be prompted to start a Trial again. Click "Cancel".
9. The "Embed assemblies in native code" option will be un-checked.
10. Close the project, and repeat step 7. Once again you will be prompted to start a Trial, indicating that "Embed assemblies in native code" is still switched on.
After step 6, it is not possible to remove `<BundleAssemblies>true</BundleAssemblies>` from the project file via the GUI. This causes an error when creating Android bundles for Release:
error XA9004: Bundling assemblies requires a Enterprise license.
Another tiny point, perhaps this error message could be updated/reworded to match the GUI?
error XA9004: Embedding assemblies in native code requires an Enterprise license.
Remove `<BundleAssemblies>true</BundleAssemblies>` from the project file using a text editor.
I cannot reproduce this with the listed steps with either 4.0.11 or with master. The option is unchecked when I cancel the upgrade/trial, and remains unchecked.
What version are you using?
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.
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.
This is still a big problem. http://forums.xamarin.com/discussion/74298/cant-create-apk-file-after-upgrade-to-visual-studio-2015-enterprise-update-3
To make matters worse, the process just fails without any explanation as to what the problem might be. I just happened to find the fix embedded in an old Xamarin Forums thread. The thread created this ticket.
I am running Visual Studio 2015 Enterprise Update 3 and using Xamarin 188.8.131.52 and Xamarin.Android 184.108.40.206. I am also running Enterprise Xamarin. I never ran any Trial version with Visual Studio, so that's not the issue.
This could be a separate bug, but I have the feeling that this is the same issue.
That does sound like an unrelated issue:
1. This bug was filed against Xamarin Studio, but your new observations are on Visual Studio.
2. If you are running Enterprise Xamarin in Visual Studio, then the "Bundle assembly" feature is included in your license. A failure when using that feature would therefore suggest to me that something other than the original licensing restriction (from Comment 0) is happening in your case. I checked briefly on my end using an old standalone "Xamarin Enterprise" license in VS Professional (since by chance I don't have a VS Enterprise installation handy at home this weekend), and the .apk with assembly bundling enabled was created successfully. There's a chance the built-in Xamarin entitlements in VS Enterprise might be behaving differently from the old standalone licenses or that something else is unique to your test conditions. If by chance you get a moment to file a quick new bug report with some of the following information, the Xamarin team would be interested to investigate:
- Does updating to the more recent versions of Xamarin (XamarinVS 4.1.2 currently on Stable or XamarinVS 4.2.0 currently on Beta) resolve the problem?
- Please collect and attach the diagnostic MSBuild output  for the failing build.
 See "verbose build output" on https://kb.xamarin.com/customer/en/portal/articles/1675684#verbose-build-output-logs
- Do you get the same problem on a new template "Visual C# > Android > Blank App (Android)" project where you enable Bundle assemblies (or manually add the corresponding entry in the .csproj file)?
- If the template project does not show the problem, then if at all possible, please attach on the new bug report a small, self-contained test case that reproduces the bug with as little code as possible.
- Lastly, if the "Bundle assemblies in native code" setting is not allowing you to un-check it (or if un-checking it and saving the project settings is not properly storing the setting), be sure to mention that symptom on the new bug report too.
Thanks in advance! (See also https://kb.xamarin.com/customer/en/portal/articles/1910343 for additional details about what to include and some strategies for minimizing test cases.)