Fw: Problems with Wix and MSBuild32 but not MSBuild64

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Fw: Problems with Wix and MSBuild32 but not MSBuild64

David J Ryan

All,

I'm having a problem with integrating Wix with MSBuild32 with the latest msbuild tools 12.0. MSBuild crashes with the following exception only with the 32-bit version of msbuild. The 64-bit version does not do this.

I have followed the instructions at the website Integrating WiX Projects Into Daily Builds according to this pattern. First I copied the wix39-binaries.zip to a folder directly under the root of our source tree $(SourceCodeControlRoot)\wix\3.9. I then had to make a copy of the sdk folder and put it at this location $(SourceCodeControlRoot)\wix\sdk.
I set the environment variables and everything works great with msbuild64 but crashes each time with msbuild32.


<PropertyGroup>
     <
WixToolPath>$(SourceCodeControlRoot)\wix\[[Version]]\</WixToolPath>
     <
WixTargetsPath>$(WixToolPath)Wix.targets</WixTargetsPath>
     <
WixTasksPath>$(WixToolPath)wixtasks.dll</WixTasksPath>
<
/PropertyGroup>

Thanks,
Dave

  Correlator -> C:\workspace\TIP\Deliverables\Correlator.root\Correlator\CorrelatorProcessor\bin\x64\Release\CorrelatorProcessor.exe
  DataTransferAgentGui -> C:\workspace\TIP\Deliverables\DataTransferAgentGui.root\DataTransferAgentGui\DataTransferAgentGui\bin\x64\Release\DataTransferAgentGui.exe
  Could not load file or assembly 'file:///c:\workspace\TIP\deliverables\wix\3.9\candle.exe' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)
     at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
     at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
     at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
     at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
     at System.Reflection.Assembly.LoadFrom(String assemblyFile)
     at Microsoft.Tools.WindowsInstallerXml.Build.Tasks.WixToolTask.ExecuteToolThread(Object parameters)

Unhandled Exception: System.IO.FileLoadException: Could not load file or assembly 'file:///c:\workspace\TIP\deliverables\wix\3.9\candle.exe' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) ---> System.NotSupportedException: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=155569 for more information.
   --- End of inner exception stack trace ---
   at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
   at System.Reflection.Assembly.LoadFrom(String assemblyFile)
   at Microsoft.Tools.WindowsInstallerXml.Build.Tasks.WixToolTask.ExecuteToolThread(Object parameters)
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart(Object obj)


    Regards,
       
       
      David J Ryan
      Principal Systems Engineer
      ENGINEERING
      HTMS System Engineering - SE
      Network Centric Systems

      Raytheon Company
      CCNA


------------------------------------------------------------------------------
New Year. New Location. New Benefits. New Data Center in Ashburn, VA.
GigeNET is offering a free month of service with a new server in Ashburn.
Choose from 2 high performing configs, both with 100TB of bandwidth.
Higher redundancy.Lower latency.Increased capacity.Completely compliant.
http://p.sf.net/sfu/gigenet
_______________________________________________
WiX-devs mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-devs
Reply | Threaded
Open this post in threaded view
|

Re: Fw: Problems with Wix and MSBuild32 but not MSBuild64

David J Ryan

All,

I did resolve this by adding  loadFromRemoteSources to MSBuild.exe.config.

Dave


Inactive hide details for David J Ryan ---01/21/2015 06:20:22 PM---All, I'm having a problem with integrating Wix with MSBuild3David J Ryan ---01/21/2015 06:20:22 PM---All, I'm having a problem with integrating Wix with MSBuild32 with the latest

From: David J Ryan <[hidden email]>
To: [hidden email]
Date: 01/21/2015 06:20 PM
Subject: [WiX-devs] Fw: Problems with Wix and MSBuild32 but not MSBuild64





All,

I'm having a problem with integrating Wix with MSBuild32 with the latest msbuild tools 12.0. MSBuild crashes with the following exception only with the 32-bit version of msbuild. The 64-bit version does not do this.


I have followed the instructions at the website
 Integrating WiX Projects Into Daily Builds according to this pattern. First I copied the wix39-binaries.zip to a folder directly under the root of our source tree $(SourceCodeControlRoot)\wix\3.9. I then had to make a copy of the sdk folder and put it at this location $(SourceCodeControlRoot)\wix\sdk.
I set the environment variables and everything works great with msbuild64 but crashes each time with msbuild32.



<
PropertyGroup>
    <
WixToolPath>$(SourceCodeControlRoot)\wix\[[Version]]\</WixToolPath>
    <
WixTargetsPath>$(WixToolPath)Wix.targets</WixTargetsPath>
    <
WixTasksPath>$(WixToolPath)wixtasks.dll</WixTasksPath>
<
/PropertyGroup>

Thanks,
Dave


 Correlator -> C:\workspace\TIP\Deliverables\Correlator.root\Correlator\CorrelatorProcessor\bin\x64\Release\CorrelatorProcessor.exe
 DataTransferAgentGui -> C:\workspace\TIP\Deliverables\DataTransferAgentGui.root\DataTransferAgentGui\DataTransferAgentGui\bin\x64\Release\DataTransferAgentGui.exe
 Could not load file or assembly 'file:///c:\workspace\TIP\deliverables\wix\3.9\candle.exe' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)
    at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
    at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
    at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
    at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
    at System.Reflection.Assembly.LoadFrom(String assemblyFile)
    at Microsoft.Tools.WindowsInstallerXml.Build.Tasks.WixToolTask.ExecuteToolThread(Object parameters)


Unhandled Exception: System.IO.FileLoadException: Could not load file or assembly 'file:///c:\workspace\TIP\deliverables\wix\3.9\candle.exe' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) ---> System.NotSupportedException: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See
http://go.microsoft.com/fwlink/?LinkId=155569 for more information.
  --- End of inner exception stack trace ---
  at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
  at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
  at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
  at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
  at System.Reflection.Assembly.LoadFrom(String assemblyFile)
  at Microsoft.Tools.WindowsInstallerXml.Build.Tasks.WixToolTask.ExecuteToolThread(Object parameters)
  at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
  at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
  at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
  at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
  at System.Threading.ThreadHelper.ThreadStart(Object obj)


    Regards, 
       
       
      David J Ryan
      Principal Systems Engineer
      ENGINEERING
      HTMS System Engineering - SE
      Network Centric Systems

      Raytheon Company
      CCNA
    ------------------------------------------------------------------------------
    New Year. New Location. New Benefits. New Data Center in Ashburn, VA.
    GigeNET is offering a free month of service with a new server in Ashburn.
    Choose from 2 high performing configs, both with 100TB of bandwidth.
    Higher redundancy.Lower latency.Increased capacity.Completely compliant.
    http://p.sf.net/sfu/gigenet_______________________________________________
    WiX-devs mailing list
    [hidden email]
    https://lists.sourceforge.net/lists/listinfo/wix-devs


------------------------------------------------------------------------------
New Year. New Location. New Benefits. New Data Center in Ashburn, VA.
GigeNET is offering a free month of service with a new server in Ashburn.
Choose from 2 high performing configs, both with 100TB of bandwidth.
Higher redundancy.Lower latency.Increased capacity.Completely compliant.
http://p.sf.net/sfu/gigenet
_______________________________________________
WiX-devs mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-devs