Setup targeting both x86 and x64?

前端 未结 4 545
执笔经年
执笔经年 2020-12-09 03:47

I have a program that requires both x64 and x86 dlls (it figures out which ones it needs at run time), but when trying to create a setup, it complains:

4条回答
  •  无人及你
    2020-12-09 04:23

    I ran into this too and wrote a blog post about my solution:

    • deflate the file using deflate.exe, naming it with a different extension (e.g. .x64)
    • add it to your main project as a content file
    • add a custom action project to your solution
    • add the custom action to the setup projects "Install" custom actions
    • inflate the file inside the custom actions Install method using
    • System.IO.Compression.DeflateStream (see code above)
    • do a little dance around your desk, down the hall, and past as many coworkers as you care to annoy :)

    The deflate.exe file can be downloaded from its repository on google code.

提交回复
热议问题