Bug 43689 - [incremental builds] AOT compiler cannot find symbols between binding projects
Summary: [incremental builds] AOT compiler cannot find symbols between binding projects
Status: VERIFIED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: Tools ()
Version: XI 9.8 (tvOS / C7)
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: 15.2
Assignee: Rolf Bjarne Kvinge [MSFT]
URL:
: 44049 47626 ()
Depends on:
Blocks:
 
Reported: 2016-08-24 00:07 UTC by Israel Soto
Modified: 2017-05-10 13:47 UTC (History)
13 users (show)

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


Attachments
AOT bug File (741 bytes, application/zip)
2016-12-07 12:47 UTC, Shuaib Mohammad
Details
IDE logs (8.26 KB, application/zip)
2017-04-10 10:37 UTC, Prasad Raghorte
Details


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:
VERIFIED FIXED

Description Israel Soto 2016-08-24 00:07:55 UTC
Test case: https://www.dropbox.com/s/4s9z1qo93cfkjtc/IncrementalBuilds.zip?dl=0

Steps to reproduce the issue:

1. Open sample located at IncrementalBuilds/Google.SignIn/samples/SignInSample folder
2. Run the sample

*********************************************

Hi guys!

I have an app project that has referenced 4 binding projects:

1. Firebase.InstanceID
2. Firebase.Analytics
3. Google.Core
4. Google.SignIn

When I try to compile the app project with "Incremental Builds" enabled, the AOT compiler fails with the following error (uploaded to Gist):

https://gist.github.com/SotoiGhost/d0033a444353a820568e305b2ea322d0

As I understand it, it is failing because Google.Core uses symbols that lives within Firebase.Analytics lib but the AOT compiler doesn't know that those symbols live in Firebase.Analytics lib. Is there a way to tell to AOT compiler where it can find those symbols?

Greetings,
Israel Soto
--
Comment 1 Israel Soto 2016-08-24 00:11:25 UTC
I forgot to tell, this works when `Incremental Builds` is disabled.
Comment 2 Rolf Bjarne Kvinge [MSFT] 2016-09-08 09:50:16 UTC
*** Bug 44049 has been marked as a duplicate of this bug. ***
Comment 3 Rolf Bjarne Kvinge [MSFT] 2016-10-31 17:14:18 UTC
The fix is to do the equivalent of the managed compiler's -r: when building a dylib - link with the dylibs for the assemblies each assembly references.
Comment 4 Shuaib Mohammad 2016-12-07 12:47:45 UTC
Created attachment 18806 [details]
AOT bug File
Comment 5 Shuaib Mohammad 2016-12-07 13:11:28 UTC
Comment on attachment 18806 [details]
AOT bug File

Sorry not mentioned earlier after disabling the increment build again  this error is generated.
Comment 6 Rolf Bjarne Kvinge [MSFT] 2016-12-08 12:58:22 UTC
@Shuaib, if you're seeing an MT3001 error with incremental builds disabled, you're running into a different issue. Please file a new bug and attach the complete build log.
Comment 7 Rolf Bjarne Kvinge [MSFT] 2017-01-02 08:12:25 UTC
*** Bug 47626 has been marked as a duplicate of this bug. ***
Comment 8 Rolf Bjarne Kvinge [MSFT] 2017-02-23 09:17:43 UTC
This will be fixed with https://github.com/xamarin/xamarin-macios/pull/1680.
Comment 9 Sebastien Pouliot 2017-03-24 19:33:47 UTC
PR was merged in master https://github.com/xamarin/xamarin-macios/commit/9f0fd32330e127b303874121f96c9e7d737c4297

It should be possible to verify this, even before 15.2 branch
Comment 10 Prasad Raghorte 2017-04-10 10:37:21 UTC
Created attachment 21385 [details]
IDE logs

This Bug is Resolved , hence marking as Verified 

================================================================

Verified on Environment :

=== Visual Studio for Mac Preview ===

Version Preview 6 (7.0 build 2740)
Installation UUID: 44676f3a-0a59-427e-8093-c40df6f917ef
Runtime:
	Mono 5.0.0.48 (2017-02/851b6c7) (64-bit)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 500000048

=== .NET Core ===

Runtime: Not installed
SDK: Not installed
MSBuild SDKs: /Library/Frameworks/Mono.framework/Versions/5.0.0/lib/mono/msbuild/15.0/bin/Sdks

=== NuGet ===

Version: 4.0.0.2323

=== Xamarin.Profiler ===

Version: 1.5.2
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler

=== Apple Developer Tools ===

Xcode 8.3 (12169)
Build 8E162

=== Xamarin.iOS ===

Version: 10.10.0.4 (Visual Studio Enterprise)
Hash: 9245c1c0
Branch: d15-2
Build date: 2017-04-08 04:10:28-0400

=== Xamarin.Android ===

Version: 7.3.0.2 (Visual Studio Enterprise)
Android SDK: /Users/rogersmsirfp3.0/Library/Developer/Xamarin/android-sdk-macosx
	Supported Android versions:
		4.4 (API level 19)
		6.0 (API level 23)
		7.0 (API level 24)
		7.1 (API level 25)

SDK Tools Version: 25.2.5
SDK Platform Tools Version: 25.0.4
SDK Build Tools Version: 25.0.1

Java SDK: /usr
java version "1.8.0_91"
Java(TM) SE Runtime Environment (build 1.8.0_91-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.91-b14, mixed mode)

Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

=== Xamarin.Mac ===

Version: 3.4.0.4 (Visual Studio Enterprise)

=== Xamarin Inspector ===

Version: 1.2.0+60
Hash: 38530f4
Branch: d15-1
Build date: Mon, 20 Mar 2017 00:32:51 GMT

=== Build Information ===

Release ID: 700002740
Git revision: 43886850206b214855338d0de1256f2bfedf5763
Build date: 2017-04-09 11:44:06-04
Xamarin addins: 2a9cb93dc912f67727067a5f638c5eb6b9e5fc61
Build lane: monodevelop-lion-d15-2

=== Operating System ===

Mac OS X 10.12.3
Darwin Kumars-MacBook-Pro.local 16.4.0 Darwin Kernel Version 16.4.0
    Thu Dec 22 22:53:21 PST 2016
    root:xnu-3789.41.3~3/RELEASE_X86_64 x86_64

======================================================================

Screencast link : https://www.screencast.com/t/UK1YgFzn4s