.net - 32 and 64 bit assemblies in one windows installer -
i have application written in c# depends on sqlite managed provider. sqlite provider platform dependent (there 2 dlls 32 , 64 bit applications same name). application loads desired 1 @ runtime based on os.
the problem while creating installer cannot add 64 bit mode dll setup project getting following error: file '' targeting '' not compatible project's target platform ''.
i use other installer have custom action must invoked during setup.
so wanted know if there installer let me add 32 , 64 bit dll , execute custom action written in c#.
one possible solution have 2 installers avoid if possible.
any suggestions?
the inno setup installer support feature wich request, installer flexible , reliable, exist many samples of scripts in web make conditional installation depending of architecture of final client.
check script located in c:\program files\inno setup 5\examples\64bitthreearch.iss
-- 64bitthreearch.iss -- ; demonstrates how install program built 3 different ; architectures (x86, x64, itanium) using single installer. ; see documentation details on creating .iss script files! [setup] appname=my program appvername=my program version 1.5 defaultdirname={pf}\my program defaultgroupname=my program uninstalldisplayicon={app}\myprog.exe compression=lzma2 solidcompression=yes outputdir=userdocs:inno setup examples output ; "architecturesinstallin64bitmode=x64 ia64" requests install ; done in "64-bit mode" on x64 & itanium, meaning should use ; native 64-bit program files directory , 64-bit view of ; registry. on other architectures install in "32-bit mode". architecturesinstallin64bitmode=x64 ia64 [files] ; install myprog-x64.exe if running on x64, myprog-ia64.exe if ; running on itanium, myprog.exe otherwise. source: "myprog-x64.exe"; destdir: "{app}"; destname: "myprog.exe"; check: isx64 source: "myprog-ia64.exe"; destdir: "{app}"; destname: "myprog.exe"; check: isia64 source: "myprog.exe"; destdir: "{app}"; check: isotherarch source: "myprog.chm"; destdir: "{app}" source: "readme.txt"; destdir: "{app}"; flags: isreadme [icons] name: "{group}\my program"; filename: "{app}\myprog.exe" [code] function isx64: boolean; begin result := is64bitinstallmode , (processorarchitecture = pax64); end; function isia64: boolean; begin result := is64bitinstallmode , (processorarchitecture = paia64); end; function isotherarch: boolean; begin result := not isx64 , not isia64; end;
Comments
Post a Comment