# File locana/locana_bindings.rb, line 48
def mswin32_installed?(mswin32_so)
   windir = ENV['WINDIR']
   windir = ENV['windir'] if (!windir)
   if (!windir)
      debug 0, "mswin32_installed? = false because ENV['WINDIR'] or ENV['windir'] does not exist" if ($DEBUG)
      return false
   end
   # Locana_gui_mswin32.dll must exist

   if (!File.exists?(windir.upcase + '/SYSTEM/Locana_gui_mswin32.DLL') && !File.exists?(windir + '/SYSTEM32/Locana_gui_mswin32.DLL'))
      debug 0, "mswin32_installed? = false because Locana_gui_mswin32.DLL does not exist" if ($DEBUG)
   end
   # user32.dll must also exist

   if (!File.exists?(windir.upcase + '/SYSTEM/USER32.DLL') && !File.exists?(windir + '/SYSTEM32/USER32.DLL'))
      debug 0, "mswin32_installed? = false because USER32.DLL does not exist" if ($DEBUG)
      return false
   end
   # gdi32.dll must also exist

   if (!File.exists?(windir.upcase + '/SYSTEM/GDI32.DLL') && !File.exists?(windir + '/SYSTEM32/GDI32.DLL'))
      debug 0, "mswin32_installed? = false because GDI32.DLL does not exist" if ($DEBUG)
      return false
   end
   debug 0, "The mswin32 GUI binding exists" if ($DEBUG)
   return true
end