Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Create single setup to install x64 & x86 msi

Create single setup to install x64 & x86 msi

Scheduled Pinned Locked Moved C#
csharpdatabasevisual-studiohelpworkspace
7 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    honeyashu
    wrote on last edited by
    #1

    Hi, I have to create a single setup package which on detection of User's machine decides which msi to consider(compiled for x86 bit machine or x64 bit machine). My Project using: 1. Visual Studio 2010 2. Coded in C# 3. Built on framework 4.0 4. Using Windows Installer 4.0 5. Prerequisits included (Framework 4.0 (integrated x86 & x64) and SQL Express2008 (integrated x86 & x64)) Problem is currently i have to build 2 setups for different target palteforms (x86 & x64) which bundeling same prerequist files. If a single setup can be done which decides which sub-msi to use will save more that 100 mb of files to be included in the package. Thus i want to create one setup.exe, one set of prerequisites and two msis' in separate folders (e.g. x86 & x64) which contains their respective msi file. So that executing setup.exe will search for firstly prerequisites & then on the basis of system will run the appropriate msi to install. Regards, honeyashu

    M B 2 Replies Last reply
    0
    • H honeyashu

      Hi, I have to create a single setup package which on detection of User's machine decides which msi to consider(compiled for x86 bit machine or x64 bit machine). My Project using: 1. Visual Studio 2010 2. Coded in C# 3. Built on framework 4.0 4. Using Windows Installer 4.0 5. Prerequisits included (Framework 4.0 (integrated x86 & x64) and SQL Express2008 (integrated x86 & x64)) Problem is currently i have to build 2 setups for different target palteforms (x86 & x64) which bundeling same prerequist files. If a single setup can be done which decides which sub-msi to use will save more that 100 mb of files to be included in the package. Thus i want to create one setup.exe, one set of prerequisites and two msis' in separate folders (e.g. x86 & x64) which contains their respective msi file. So that executing setup.exe will search for firstly prerequisites & then on the basis of system will run the appropriate msi to install. Regards, honeyashu

      M Offline
      M Offline
      Mycroft Holmes
      wrote on last edited by
      #2

      I don't think that is possible, every app I have downloaded that has a different requirement for 86/64 has supplied separate MSIs. I would be mightily annoyed if I had to download x86 files when installing on a 64 machine!

      Never underestimate the power of human stupidity RAH

      H 1 Reply Last reply
      0
      • H honeyashu

        Hi, I have to create a single setup package which on detection of User's machine decides which msi to consider(compiled for x86 bit machine or x64 bit machine). My Project using: 1. Visual Studio 2010 2. Coded in C# 3. Built on framework 4.0 4. Using Windows Installer 4.0 5. Prerequisits included (Framework 4.0 (integrated x86 & x64) and SQL Express2008 (integrated x86 & x64)) Problem is currently i have to build 2 setups for different target palteforms (x86 & x64) which bundeling same prerequist files. If a single setup can be done which decides which sub-msi to use will save more that 100 mb of files to be included in the package. Thus i want to create one setup.exe, one set of prerequisites and two msis' in separate folders (e.g. x86 & x64) which contains their respective msi file. So that executing setup.exe will search for firstly prerequisites & then on the basis of system will run the appropriate msi to install. Regards, honeyashu

        B Offline
        B Offline
        BobJanova
        wrote on last edited by
        #3

        I don't think it can be done with an MSI installer. You need to have two projects which build two versions of the .msi and which you both provide for download to the user. You could write a tiny application that checks the platform, downloads the appropriate MSI and uses Process.Start to run it. Most applications don't bother with this, they expect users to know which platform they're on.

        1 Reply Last reply
        0
        • M Mycroft Holmes

          I don't think that is possible, every app I have downloaded that has a different requirement for 86/64 has supplied separate MSIs. I would be mightily annoyed if I had to download x86 files when installing on a 64 machine!

          Never underestimate the power of human stupidity RAH

          H Offline
          H Offline
          honeyashu
          wrote on last edited by
          #4

          Thanks for your reply, but what i want is i want to create one setup.exe, one set of prerequisites and two msis' in separate folders (e.g. x86 & x64) which contains their respective msi file. Thus running on setup.exe will search for firstly prerequisites & then on the basis of system will run the appropriate msi to install. Regards, Ashish

          D 1 Reply Last reply
          0
          • H honeyashu

            Thanks for your reply, but what i want is i want to create one setup.exe, one set of prerequisites and two msis' in separate folders (e.g. x86 & x64) which contains their respective msi file. Thus running on setup.exe will search for firstly prerequisites & then on the basis of system will run the appropriate msi to install. Regards, Ashish

            D Offline
            D Offline
            Dave Kreskowiak
            wrote on last edited by
            #5

            OK, so what's the problem then?? Other than, yes it's possible. Setup.exe wrapped installers like this are made all the time. BTW: Your pre-req's, depending on what they are and how your application uses them, would possibly ALSO have to be seperated into x86 and x64 versions. You cannot mix 32 and 64-bit code in the same process, so if your app is running 64-bit, it cannot use a 32-bit library.

            A guide to posting questions on CodeProject[^]
            Dave Kreskowiak

            H 1 Reply Last reply
            0
            • D Dave Kreskowiak

              OK, so what's the problem then?? Other than, yes it's possible. Setup.exe wrapped installers like this are made all the time. BTW: Your pre-req's, depending on what they are and how your application uses them, would possibly ALSO have to be seperated into x86 and x64 versions. You cannot mix 32 and 64-bit code in the same process, so if your app is running 64-bit, it cannot use a 32-bit library.

              A guide to posting questions on CodeProject[^]
              Dave Kreskowiak

              H Offline
              H Offline
              honeyashu
              wrote on last edited by
              #6

              Problem is i am unable to find a way to create such type of setup.exe which should call appropriate msi to run on correct system.

              D 1 Reply Last reply
              0
              • H honeyashu

                Problem is i am unable to find a way to create such type of setup.exe which should call appropriate msi to run on correct system.

                D Offline
                D Offline
                Dave Kreskowiak
                wrote on last edited by
                #7

                You can create the Setup.exe in any language you want. C and C++ won't require you to install a prereq just to run the Setup.exe. You could use C# or VB.NET, but the user would have to install the .NET Framework on the machine first (if needed) before the user launches your Setup.exe. In any case, all your Setup.exe is doing is determining which bitness of Windows it's running on then starting a new Process with the appropriate command line to launch your installer, such as "msiexec /i myinstall.msi" and waiting for it to end.

                A guide to posting questions on CodeProject[^]
                Dave Kreskowiak

                1 Reply Last reply
                0
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • World
                • Users
                • Groups