Changeset 76023 in vbox for trunk/src/VBox/Additions/darwin/Installer/VBoxGuestAdditions_mpkg
- Timestamp:
- Dec 6, 2018 7:05:37 PM (6 years ago)
- svn:sync-xref-src-repo-rev:
- 127249
- Location:
- trunk/src/VBox/Additions/darwin/Installer/VBoxGuestAdditions_mpkg
- Files:
-
- 1 edited
- 1 copied
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/darwin/Installer/VBoxGuestAdditions_mpkg/Localizable.strings
r48251 r76023 7 7 'choiceVBoxToolsAndServices_msg' = 'Installs the @VBOX_PRODUCT@ Guest Additions Tools and Services to /Library/Application Support/VirtualBox Guest Additions.'; 8 8 9 'UNSUPPORTED_OS_TLE' = "Unsupported OS version detected!"; 10 'UNSUPPORTED_OS_MSG' = "The installer has detected an unsupported operation system. VirtualBox Guest Additions require Mac OS X 10.6 or later."; 9 'UNSUPPORTED_AMD64_OS_TLE' = "Incompatible OS version detected!"; 10 'UNSUPPORTED_AMD64_OS_MSG' = "VirtualBox Guest Additions require Mac OS X 10.7 or later running in 64-bit mode."; 11 12 'UNSUPPORTED_X86_OS_TLE' = "Incompatible OS version detected!"; 13 'UNSUPPORTED_X86_OS_MSG' = "The 32-bit VirtualBox Guest Additions are only for Mac OS X 10.7 and earlier running in 32-bit mode."; 14 -
trunk/src/VBox/Additions/darwin/Installer/VBoxGuestAdditions_mpkg/distribution-amd64.dist
r76020 r76023 15 15 <installer-gui-script minSpecVersion="1.0"> 16 16 <title>VirtualBox_title</title> 17 <options customize="allow" allow-external-scripts="yes" rootVolumeOnly="true" hostArchitectures="i386"/> 18 <installation-check script="checkPrerequisite()"></installation-check> 17 <options customize="allow" allow-external-scripts="false" rootVolumeOnly="true" hostArchitectures="i386"/> 19 18 <domains enable_anywhere="false" enable_currentUserHome="false" enable_localSystem="true"/> 19 <!-- This allowes a better error message compared to allowed-os-versions: --> 20 <installation-check script="checkPrerequisites()"></installation-check> 20 21 <script> 21 22 /* js:pkmk:start */ 22 function checkPrerequisite ()23 function checkPrerequisites() 23 24 { 24 try25 {26 test= system.version['ProductVersion'];27 system.log("OS version detected: " + test);28 result = (system.compareVersions(test, '10.6') >= 0);29 } catch (e) { system.log(e); result = false; }30 31 if (!result)32 {33 my.result.type = 'Fatal';34 my.result.title = system.localizedString('UNSUPPORTED_OS_TLE');35 my.result.message = system.localizedString('UNSUPPORTED_OS_MSG');36 return result;37 }38 39 system.log("result:" + result);40 return result;25 sArch = system.sysctl('hw.machine'); 26 system.log("Detected hw arch: " + sArch); 27 sVer = system.version['ProductVersion']; 28 system.log("Detected OS version: " + sVer); 29 if (sArch == 'x86_64') 30 { 31 if (system.compareVersions(sVer, '10.7') >= 0) 32 { 33 system.log("checkPrerequisites returns true"); 34 return true; 35 } 36 } 37 system.log("checkPrerequisites returns false!"); 38 my.result.type = 'Fatal'; 39 my.result.title = system.localizedString('UNSUPPORTED_AMD64_OS_TLE'); 40 my.result.message = system.localizedString('UNSUPPORTED_AMD64_OS_MSG'); 41 return false; 41 42 } 42 43 /* js:pkmk:end */ … … 52 53 <pkg-ref id="org.virtualbox.pkg.additions.tools-and-services"></pkg-ref> 53 54 </choice> 54 <choice id="choiceVBoxKEXTs" title="choiceVBoxKEXTs_title" description="choiceVBoxKEXTs_msg"start_selected="true" start_enabled="false" start_visible="true">55 <choice id="choiceVBoxKEXTs" title="choiceVBoxKEXTs_title" description="choiceVBoxKEXTs_msg" start_selected="true" start_enabled="false" start_visible="true"> 55 56 <pkg-ref id="org.virtualbox.pkg.additions.kexts"></pkg-ref> 56 57 </choice> -
trunk/src/VBox/Additions/darwin/Installer/VBoxGuestAdditions_mpkg/distribution-x86.dist
r76022 r76023 15 15 <installer-gui-script minSpecVersion="1.0"> 16 16 <title>VirtualBox_title</title> 17 <options customize="allow" allow-external-scripts="yes" rootVolumeOnly="true" hostArchitectures="i386"/> 18 <installation-check script="checkPrerequisite()"></installation-check> 17 <options customize="allow" allow-external-scripts="false" rootVolumeOnly="true" hostArchitectures="i386"/> 19 18 <domains enable_anywhere="false" enable_currentUserHome="false" enable_localSystem="true"/> 19 <!-- This allowes a better error message compared to allowed-os-versions: --> 20 <installation-check script="checkPrerequisites()"></installation-check> 20 21 <script> 21 22 /* js:pkmk:start */ 22 function checkPrerequisite ()23 function checkPrerequisites() 23 24 { 24 try25 {26 test= system.version['ProductVersion'];27 system.log("OS version detected: " + test);28 result = (system.compareVersions(test, '10.6') >= 0);29 } catch (e) { system.log(e); result = false; }30 31 if (!result)32 {33 my.result.type = 'Fatal';34 my.result.title = system.localizedString('UNSUPPORTED_OS_TLE');35 my.result.message = system.localizedString('UNSUPPORTED_OS_MSG');36 return result;37 }38 39 system.log("result:" + result);40 return result;25 sArch = system.sysctl('hw.machine'); 26 system.log("Detected hw arch: " + sArch); 27 sVer = system.version['ProductVersion']; 28 system.log("Detected OS version: " + sVer); 29 if (sArch == 'i386') 30 { 31 if (system.compareVersions(sVer, '10.8') < 0) 32 { 33 system.log("checkPrerequisites returns true"); 34 return true; 35 } 36 } 37 system.log("checkPrerequisites returns false!"); 38 my.result.type = 'Fatal'; 39 my.result.title = system.localizedString('UNSUPPORTED_X86_OS_TLE'); 40 my.result.message = system.localizedString('UNSUPPORTED_X86_OS_MSG'); 41 return false; 41 42 } 42 43 /* js:pkmk:end */ … … 52 53 <pkg-ref id="org.virtualbox.pkg.additions.tools-and-services"></pkg-ref> 53 54 </choice> 54 <choice id="choiceVBoxKEXTs" title="choiceVBoxKEXTs_title" description="choiceVBoxKEXTs_msg"start_selected="true" start_enabled="false" start_visible="true">55 <choice id="choiceVBoxKEXTs" title="choiceVBoxKEXTs_title" description="choiceVBoxKEXTs_msg" start_selected="true" start_enabled="false" start_visible="true"> 55 56 <pkg-ref id="org.virtualbox.pkg.additions.kexts"></pkg-ref> 56 57 </choice>
Note:
See TracChangeset
for help on using the changeset viewer.