summaryrefslogtreecommitdiff
path: root/lib/chef/provider/package
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/provider/package')
-rw-r--r--lib/chef/provider/package/windows/msi.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/provider/package/windows/msi.rb b/lib/chef/provider/package/windows/msi.rb
index 31faa78215..7fdbbcff35 100644
--- a/lib/chef/provider/package/windows/msi.rb
+++ b/lib/chef/provider/package/windows/msi.rb
@@ -18,7 +18,7 @@
# TODO: Allow @new_resource.source to be a Product Code as a GUID for uninstall / network install
-require 'chef/win32/api/installer' if RUBY_PLATFORM =~ /mswin|mingw32|windows/
+require 'chef/win32/api/installer' if (RUBY_PLATFORM =~ /mswin|mingw32|windows/) && Chef::Platform.supports_msi?
require 'chef/mixin/shell_out'
class Chef
@@ -26,7 +26,7 @@ class Chef
class Package
class Windows
class MSI
- include Chef::ReservedNames::Win32::API::Installer if RUBY_PLATFORM =~ /mswin|mingw32|windows/
+ include Chef::ReservedNames::Win32::API::Installer if (RUBY_PLATFORM =~ /mswin|mingw32|windows/) && Chef::Platform.supports_msi?
include Chef::Mixin::ShellOut
def initialize(resource)