Bug 32326 - Error 334 Xamarin iOS Linker: Failed to resolve assembly: 'ExifLib, Version=, Culture=neutral, PublicKeyToken=null'
Summary: Error 334 Xamarin iOS Linker: Failed to resolve assembly: 'ExifLib, Version=1...
Alias: None
Product: iOS
Classification: Xamarin
Component: General ()
Version: XI 8.10
Hardware: PC Windows
: Normal normal
Target Milestone: Untriaged
Assignee: Bugzilla
Depends on:
Reported: 2015-07-22 14:45 UTC by findlay
Modified: 2015-07-29 06:01 UTC (History)
4 users (show)

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

screenshot (298.03 KB, image/png)
2015-07-28 11:25 UTC, Sebastien Pouliot

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 findlay 2015-07-22 14:45:16 UTC
When I attempt to build my xamarin ios project with linking turned on (without it the app ends up at 140+MB) I get this error. I have tried everything I can think of to fix it and have removed all references to ExifLib from my shared code, iOS and android projects, also removed all references manually from csproj files, app.config, and packages.config but I still get this error. I have no idea why it still thinks theres a reference to this assembly. Nothing I seem to do makes a difference. I get the same error whether I set link All assemblies or link SDK assemblies only and also adding linkskips makes no difference.
Comment 1 Sebastien Pouliot 2015-07-22 15:29:34 UTC
I do not know where `Error 334` comes from. That's not an error that XI reports, they are all in the MTxxxx format.

`Failed to resolve assembly: XXX` means that, at least one, assembly binary given to the linker has a reference to XXX. Without the project itself I cannot tell you which one it is (but you can look/grep the .dll/.exe binaries to get hints).
Comment 2 findlay 2015-07-23 03:43:13 UTC
The Error 334 part is just from VS so its not important. We're happy to share the project with you if that would help us get to the bottom of this.
Comment 3 findlay 2015-07-24 07:44:24 UTC
Any ideas? There are no references to exiflib.dll in the iOS or the PCL project. There is a reference in the Android project but I don't see why the linker would be doing anything with that project when I'm just building the iOS project. I couldnt find anything using grep either :s
Comment 4 Sebastien Pouliot 2015-07-24 11:25:11 UTC
Please attach the project (or a link to the project) to the bug report (you can mark it as private)
Comment 6 Sebastien Pouliot 2015-07-28 11:25:20 UTC
Created attachment 12251 [details]

There's no solution file in your archive so I cannot build it myself.

However the .cproj file for the iOS project does have a (assembly) reference to the ExifLib assembly and also has it under the "Package" section of the project.

That means that any code that reference this will create a reference to the assembly, which in turns will require the linker to load the assembly.

Furthermore I can grep ExifLib in your output directory, e.g.

$ pwd
$ grep ExifLib *
grep: DDDAppiOS.app: Is a directory
Binary file XLabs.Platform.dll matches

^ so it looks like one of your app component requires this assembly. Not having it inside the directory would be the cause of the error you're experiencing.
Comment 7 Sebastien Pouliot 2015-07-28 11:26:06 UTC
Comment 8 findlay 2015-07-29 06:01:37 UTC
Thanks, I'm not sure why grep wouldnt work for me, possibly since I'm restricted on permissions on the mac im using (macincloud) or more likley was due to me not knowing what I was doing.
Thanks for the help. Reinstalling XLabs  seems to have worked since it reloaded all the dependencies.