Omnibus and MSI-packages


#1

Hello all.

I have one question regarding compilation msi-packages with omnibus-ruby.

As i see, omnibus compiles msi with this command:

def msi_command
  msi_command = ["light.exe",
                 "-nologo",
                 "-ext WixUIExtension",
                 "-cultures:en-us",
                 "-loc #{install_path}\\msi-tmp\\#{package_name}-en-us.wxl",
                 "#{install_path}\\msi-tmp\\#{package_name}-Files.wixobj",
                 "#{install_path}\\msi-tmp\\#{package_name}.wixobj",
                 "-out #{config.package_dir}\\#{output_package("msi")}"]

  # Don't care about the 204 return code from light.exe since it's
  # about some expected warnings...
  [msi_command.join(" "), {:returns => [0, 204]}]
end

Could you talk, how i can redefine that and execute light.exe with some additional parameters?

I need to create some complicated msi-installer with help of your instrument, and i need ability to change parameters for light.exe.


With best regards, Anton Baranov.


#2

On Tuesday, August 6, 2013 at 5:11 AM, Anton Baranov wrote:

Hello all.

I have one question regarding compilation msi-packages with omnibus-ruby.

As i see, omnibus compiles msi with this command:

def msi_command
  msi_command = ["light.exe",
                 "-nologo",
                 "-ext WixUIExtension",
                 "-cultures:en-us",
                 "-loc #{install_path}\\msi-tmp\\#{package_name}-en-us.wxl",
                 "#{install_path}\\msi-tmp\\#{package_name}-Files.wixobj",
                 "#{install_path}\\msi-tmp\\#{package_name}.wixobj",
                 "-out #{config.package_dir}\\#{output_package("msi")}"]

  # Don't care about the 204 return code from light.exe since it's
  # about some expected warnings...
  [msi_command.join(" "), {:returns => [0, 204]}]
end

Could you talk, how i can redefine that and execute light.exe with some additional parameters?

I need to create some complicated msi-installer with help of your instrument, and i need ability to change parameters for light.exe.


With best regards, Anton Baranov.

To get going, you can monkey patch the method to do what you want. You should probably generalize what you’re doing and then submit a patch for omnibus to support custom MSI options.


Daniel DeLeo


#3

What is the reason you want to change light.exe parameteres Anton? Understanding that might help us direct you better.

Serdar


From: Anton Baranov anton@atalanta-systems.com
Sent: Tuesday, August 06, 2013 3:11 PM
To: chef-dev@lists.opscode.com
Subject: [chef-dev] Omnibus and MSI-packages

Hello all.

I have one question regarding compilation msi-packages with omnibus-ruby.

As i see, omnibus compiles msi with this command:

def msi_command
  msi_command = ["light.exe",
                 "-nologo",
                 "-ext WixUIExtension",
                 "-cultures:en-us",
                 "-loc #{install_path}\\msi-tmp\\#{package_name}-en-us.wxl",
                 "#{install_path}\\msi-tmp\\#{package_name}-Files.wixobj",
                 "#{install_path}\\msi-tmp\\#{package_name}.wixobj",
                 "-out #{config.package_dir}\\#{output_package("msi")}"]

  # Don't care about the 204 return code from light.exe since it's
  # about some expected warnings...
  [msi_command.join(" "), {:returns => [0, 204]}]
end

Could you talk, how i can redefine that and execute light.exe with some additional parameters?

I need to create some complicated msi-installer with help of your instrument, and i need ability to change parameters for light.exe.


With best regards, Anton Baranov.