- Timestamp:
- Feb 6, 2014 2:33:06 PM (11 years ago)
- svn:sync-xref-src-repo-rev:
- 92084
- Location:
- trunk/src/VBox/Additions
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/solaris/Installer/postinstall.sh
r47318 r50345 242 242 fi 243 243 244 # Adjust xorg.conf with video driver sections 245 $vboxadditions_path/x11config15sol.pl 244 # Check for VirtualBox graphics card 245 is_vboxgraphics=`prtconf -d | grep -i pci80ee,beef` 246 if test "$?" -eq 0; then 247 drivername="vboxvideo" 248 else 249 # Check for VMware graphics card 250 is_vmwaregraphics=`prtconf -d | grep -i pci15ad,405` 251 if test "$?" -eq 0; then 252 echo "Configuring X.Org to use VMware SVGA graphics driver..." 253 drivername="vmware" 254 fi 255 fi 256 257 # Adjust xorg.conf with video driver sections if a supported graphics card is found 258 if test ! -z "$drivername"; then 259 $vboxadditions_path/x11config15sol.pl "$drivername" 260 else 261 # No supported graphics card found, do nothing. 262 echo "## No supported graphics card found. Skipped configuring of X.org drivers." 263 fi 246 264 fi 247 265 fi -
trunk/src/VBox/Additions/x11/Installer/x11config15sol.pl
r44528 r50345 1 #!/usr/bin/perl -w1 #!/usr/bin/perl 2 2 # 3 3 # Guest Additions X11 config update script … … 14 14 # 15 15 16 use strict; 17 use warnings; 18 16 19 my $temp="/tmp/xorg.conf"; 17 20 my $os_type=`uname -s`; 18 my @cfg_files = ("/etc/X11/xorg.conf -4", "/etc/X11/xorg.conf", "/etc/X11/.xorg.conf", "/etc/xorg.conf",21 my @cfg_files = ("/etc/X11/xorg.conf", "/etc/X11/.xorg.conf", "/etc/X11/xorg.conf-4", "/etc/xorg.conf", 19 22 "/usr/etc/X11/xorg.conf-4", "/usr/etc/X11/xorg.conf", "/usr/lib/X11/xorg.conf-4", 20 23 "/usr/lib/X11/xorg.conf", "/etc/X11/XF86Config-4", "/etc/X11/XF86Config", 21 24 "/etc/XF86Config", "/usr/X11R6/etc/X11/XF86Config-4", "/usr/X11R6/etc/X11/XF86Config", 22 25 "/usr/X11R6/lib/X11/XF86Config-4", "/usr/X11R6/lib/X11/XF86Config"); 26 27 ## @todo: r=ramshankar: Hmm, why do we use the same variable name with upper/lower case for different variables? 28 my $cfg; 23 29 my $CFG; 24 30 my $TMP; 25 31 my $line; 26 32 my $config_count = 0; 27 33 34 # Command line options 35 if ($#ARGV < 0) 36 { 37 die "x11config15sol.pl: Missing driver name argument to configure for X.org"; 38 } 39 my $driver_name = $ARGV[0]; 40 41 # Loop through all possible config files and change them. It's done this wasy for hysterical raisins 42 # as we didn't know what the correct config file is so we update all of them. However, for Solaris it's 43 # most likely -only- one of the 2 config files (/etc/X11/xorg.conf, /etc/X11/.xorg.conf). 28 44 foreach $cfg (@cfg_files) 29 45 { 30 31 46 if (open(CFG, $cfg)) 32 47 { … … 44 59 $in_section = 1; 45 60 } 46 } else { 61 } 62 else 63 { 47 64 if ($line =~ /^\s*EndSection/i) 48 65 { … … 55 72 if ($line =~ /^\s*driver\s+\"(?:fbdev|vga|vesa|vboxvideo|ChangeMe)\"/i) 56 73 { 57 $line = " Driver \" vboxvideo\"\n";74 $line = " Driver \"$driver_name\"\n"; 58 75 } 59 76 } … … 78 95 79 96 $config_count != 0 or die "Could not find any X11 configuration files"; 97
Note:
See TracChangeset
for help on using the changeset viewer.