[wix-users] Is bindingRedirect possible for a managed bootstrapper application?

Gerhard Matzen gmatzen at osisoft.com
Tue Apr 4 18:03:28 PDT 2017


I have a managed bootstrapper application.  My payload contains 2 dlls.

"a.dll" references Newtonsoft.Json 9.0.
"b.dll" references Newtonsoft.Json 10.0.

I tried adding...

    <runtime>
      <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
        <dependentAssembly>
          <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
          <bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0" />
        </dependentAssembly>
      </assemblyBinding>
    </runtime>

...to my BootstrapperCore.confi file.

And I put the 10.0 version of newtonsoft.json.dll in the payload.

But I still get an error similar to:

---------------------------
PI AF Services 2017
---------------------------
Could not load file or assembly 'Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The system cannot find the file specified.
---------------------------
OK
---------------------------

Since the bootstrapper is native, I don't know if there is a good way to do bindingRedirect.

Does anyone know if adding a binding redirect is possible?

Thanks,
Gerhard


More information about the wix-users mailing list