Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

ccrewrite aborted due to metadata errors (Xamarin or VS2017 15.2 related?) #488

Open
nexussays opened this issue May 18, 2017 · 0 comments

Comments

@nexussays
Copy link

I wasn't able to find anything regarding the below issue when searching, apologies if I missed something.

I started receiving this error when compiling Xamarin library projects for iOS or Android on a system running VS2017 15.2. It doesn't happen in any app projects that I can tell, just libraries, and just iOS and Android (PCL and .Net4.5 libraries appear fine). I can't recall anything that has changed on my end, but it still works on a machine with VS2017 15.1 as well as VSTS. So I'm presuming it's an issue with the 15.2 update? Somehow?

The specific errors are different between iOS and Android but I am assuming they are related since they both appeared at the same time.

Xamarin.iOS library project:

Task "Exec" (TaskId:164)
  Task Parameter:WorkingDirectory=obj\Release\ (TaskId:164)
  Task Parameter:Command="C:\Users\<snip>\lib\packages\DotNet.Contracts.1.10.20606.1\Bin\ccrewrite.exe" "@projectnameccrewrite.rsp" (TaskId:164)
  "C:\Users\<snip>\lib\packages\DotNet.Contracts.1.10.20606.1\Bin\ccrewrite.exe" "@projectnameccrewrite.rsp" (TaskId:164)
  Reading assembly 'mscorlib' from 'C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\ReferenceAssemblies\Microsoft\Framework\MonoAndroid\v1.0\mscorlib.dll' resulted in errors. (TaskId:164)
ccrewrite : error : Rewrite aborted due to metadata errors. Check output window
    An attempt was made to move the file pointer before the beginning of the file. (TaskId:164)
   (TaskId:164)
  elapsed time: 533.1574ms (TaskId:164)

Xamarin.Android library project:

Task "Exec" (TaskId:167)
  Task Parameter:WorkingDirectory=obj\Release\ (TaskId:167)
  Task Parameter:Command="C:\Users\<snip>\lib\packages\DotNet.Contracts.1.10.20606.1\Bin\ccrewrite.exe" "@projectnameccrewrite.rsp" (TaskId:167)
  "C:\Users\<snip>\lib\packages\DotNet.Contracts.1.10.20606.1\Bin\ccrewrite.exe" "@projectnameccrewrite.rsp" (TaskId:167)
  Reading assembly 'Xamarin.iOS' from 'C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\ReferenceAssemblies\Microsoft\Framework\Xamarin.iOS\v1.0\Xamarin.iOS.dll' resulted in errors. (TaskId:167)
ccrewrite : error : Rewrite aborted due to metadata errors. Check output window
    Could not resolve type reference: [Mono.Security]Mono.Security.Interface.MonoTlsProvider. (TaskId:167)
  elapsed time: 567.021ms (TaskId:167)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant