locked
ALINK warning AL1073: Referenced assembly 'mscorlib.dll' targets a different processor RRS feed

  • Question

  • Hi,

    I hope this forum is the correct place to ask my question - if not feel free to move it.

    I have a C# project which builds with build configuration Release|x86. This project has some satellite dlls (localized resources). When I compile locally with Visual Studio 2012 it works totally fine without warnings. But when our TFS 2012 builds it, there occurs the following "warning: ALINK: Referenced assembly 'mscorlib.dll' targets a different processor". The build log brings more details: 

    ALINK : warning AL1073: Referenced assembly 'mscorlib.dll' targets a different processor [e:\Bld\2\26\Sources\path\to\project\project.csproj]
           GenerateSatelliteAssemblies:
             C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\x64\AL.exe /culture:en-us /out:obj\x86\Release\en-us\proejct.resources.dll /platform:x86 /template:obj\x86\Release\project.exe /embed:obj\x86\Release\project.Properties.Resources.en-us.resources
        15>ALINK : warning AL1073: Referenced assembly 'mscorlib.dll' targets a different processor [e:\Bld\2\26\Sources\path\to\project\project.csproj]

    It seems, that the problem is, that the TFS build runs AL.exe from a x64 subfolder (C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\x64\AL.exe) whereas on my local machine not (C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\AL.exe).

    Does anyone know how to fix this? It would be also fine, if someone could me some advice to ignore that warning (because it's no CSXXXX warning, it cannot be ingored in the project settigns).

    Johannes

    Thursday, March 14, 2013 12:47 PM

Answers

All replies

  • Hi Johannes,

    Thanks for your post!

    I think the issue is related the platform which you select to set.

    In TFS 2012, the "Configurations to build" is set to X86, "MSbuild Platform" as default to Auto.

    Please set "MSBuild Platform" to X86.

    For more information, please refer to http://social.msdn.microsoft.com/Forums/en-US/tfsbuild/thread/dd1c3c80-6fdb-451a-be45-10c879f56953

    and http://social.msdn.microsoft.com/Forums/en-US/netfx64bit/thread/0264b645-f80b-4140-940c-4db7debe2a7a/

    Hope it helps!

    Best Regards,


    Cathy Kong
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Friday, March 15, 2013 8:51 AM
    Moderator
  • Hi Cathy!

    Setting "MSbuild Platform" Auto x86 worked fine.
    Thank you very much!

    I don't think so, but will there be any problems when we want to build 64bit applications?

    Friday, March 15, 2013 2:15 PM
  • Hi Johannes,

    Thanks for your feedback!

    I tried building a C# project and set the solution and project to Release\x64 on my machine, and set the  "Configurations to build" in TFS 2012 to "Auto", the warning is missing. So the platforms and configurations selected for the Configurations to build will depend on the contents of the solution's platforms and configuraions. 

    For more information about this, please refer to http://blogs.msdn.com/b/aaronhallberg/archive/2007/06/25/solution-configurations.aspx

    Hope it helps!

    Best Regards,


    Cathy Kong
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Monday, March 18, 2013 5:12 AM
    Moderator
  • I have this same problem, and the solution does NOT work for me.

    I am specifically trying to target a 64 bit build platform. I see that 

    C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\AL.exe

    gets called, because of this build property:

    SdkToolsPath=C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\

    But I want it to target this instead:

    C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\x64\AL.exe

    Wednesday, November 13, 2013 9:52 PM
  • The solution does not work for me either as I am not using TFS.  It's also looking for the wrong version of AL.exe when building our localization satellite assemblies.

    Surely there must be a way to configure Visual Studio to use the correct version of AL.exe?

    Wednesday, January 22, 2014 8:57 PM