4.0.13 update - Error A1046

rjmrjm CAMember ✭✭✭

After installing 4.0.13 I can no longer compile my solution. I get the error:

/Users/me/Workspace/Solution/MyProject/ALINK: Error A1046: Resource identifier 'that.cs.resources' has already been used in this assembly (A1046) (Core)

I was able to revert to 4.0.12 which fixes the issue.

Posts

  • mhutchmhutch USMember, Xamarin Team Xamurai

    What is ALINK? It looks like a custom tool.

  • rjmrjm CAMember ✭✭✭

    There is no file, folder, path or tool in my solution called 'ALINK'. The term is completely knew to me.

    Additionally, that.cs.resources doesn't make any sense either. I have some resources in one of my projects, however none of them have an ID like 'that'.

    A full text search of my solution shows no reference to 'ALINK' or 'that.cs.resources'

  • mhutchmhutch USMember, Xamarin Team Xamurai

    I assume you're using Android, since that error appears to come from MSBuild. Could you please gist the full build log?

  • rjmrjm CAMember ✭✭✭

    Here you go

    I'm using Xamarin.Mac, no Android projects at all

  • JeffreyStedfastJeffreyStedfast USXamarin Team Xamurai

    You should not be using MSBuild with Xamarin.Mac projects.

    Use mdtool if you are building from the command-line. If you are building from inside Xamarin Studio, then you must have somehow switch this project to use msbuild instead of the default.

    Open up your Project Options and go to the General/Main Settings section and uncheck the "Use the MSBuild build engine (unsupported for this project type)" checkbox.

  • mhutchmhutch USMember, Xamarin Team Xamurai

    In this case it looks like the problem is in a shared .NET library, not a Xamarin.Mac project. .NET projects should be using the MSBuild engine - it's now the default setting in XS 4.0.13.

    The problem seems to be:

        Target GenerateSatelliteAssemblies:
            Tool /Library/Frameworks/Mono.framework/Versions/3.2.3/bin/al execution started with arguments:  /culture:cs /embed:obj/Debug/that.cs.resources /embed:obj/Debug/that.cs.resources /out:obj/Debug/cs/Core.resources.dll
    ALINK: error A1046: Resource identifier 'that.cs.resources' has already been used in this assembly
            Task "AL" execution -- FAILED
    

    It looks to me like the error is likely correct, but the old MonoDevelop build engine wasn't catching it.

    Would you be able to share the Core.csproj file?

  • rjmrjm CAMember ✭✭✭

    Correct, it is indeed a shared .NET library

    @mhutch - I have sent you a PM with a link to the Core.csproj

  • rjmrjm CAMember ✭✭✭

    Seemingly caused by one of the .resx in the project. Remove and re-adding the resources from the project seems to have fixed the issue.

  • DaveHuntDaveHunt USMember ✭✭✭✭✭

    @rjm - thanks for following up with your solution.

Sign In or Register to comment.