VirtualBox

Changeset 36790 in vbox for trunk/src/VBox/Additions


Ignore:
Timestamp:
Apr 21, 2011 12:30:24 PM (14 years ago)
Author:
vboxsync
Message:

Solaris/additions/postinstall.sh: minor clean up.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/solaris/Installer/postinstall.sh

    r36751 r36790  
    2323#
    2424
     25# uncompress(directory, file)
     26# Updates package metadata and uncompresses the file.
     27uncompress_file()
     28{
     29    if test -z "$1" || test -z "$2"; then
     30        echo "missing argument to uncompress_file()"
     31        return 1
     32    fi
     33   
     34    # Remove compressed path from the pkg
     35    /usr/sbin/removef $PKGINST "$1/$2.Z" 1>/dev/null
     36   
     37    # Add uncompressed path to the pkg
     38    /usr/sbin/installf -c none $PKGINST "$1/$2" f
     39
     40    # Uncompress the file (removes compressed file when done)
     41    uncompress -f "$1/$2.Z" > /dev/null 2>&1
     42}
     43
    2544uncompress_files()
    2645{
    27     # Remove compressed names from the pkg
    28     /usr/sbin/removef $PKGINST "$1/VBoxClient.Z" 1>/dev/null
    29     /usr/sbin/removef $PKGINST "$1/VBoxService.Z" 1>/dev/null
    30     /usr/sbin/removef $PKGINST "$1/VBoxControl.Z" 1>/dev/null
    31     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_13.so.Z" 1>/dev/null
    32     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_14.so.Z" 1>/dev/null
    33     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_15.so.Z" 1>/dev/null
    34     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_16.so.Z" 1>/dev/null
    35     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_17.so.Z" 1>/dev/null
    36     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_18.so.Z" 1>/dev/null
    37     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_19.so.Z" 1>/dev/null
    38     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_110.so.Z" 1>/dev/null
    39     /usr/sbin/removef $PKGINST "$1/vboxvideo_drv_71.so.Z" 1>/dev/null
    40     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_14.so.Z" 1>/dev/null
    41     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_15.so.Z" 1>/dev/null
    42     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_16.so.Z" 1>/dev/null
    43     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_17.so.Z" 1>/dev/null
    44     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_18.so.Z" 1>/dev/null
    45     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_19.so.Z" 1>/dev/null
    46     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_110.so.Z" 1>/dev/null
    47     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_70.so.Z" 1>/dev/null
    48     /usr/sbin/removef $PKGINST "$1/vboxmouse_drv_71.so.Z" 1>/dev/null
    49 
    50     # Add uncompressed names to the pkg
    51     /usr/sbin/installf -c none $PKGINST "$1/VBoxClient" f
    52     /usr/sbin/installf -c none $PKGINST "$1/VBoxService" f
    53     /usr/sbin/installf -c none $PKGINST "$1/VBoxControl" f
    54     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_13.so" f
    55     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_14.so" f
    56     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_15.so" f
    57     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_16.so" f
    58     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_17.so" f
    59     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_18.so" f
    60     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_19.so" f
    61     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_110.so" f
    62     /usr/sbin/installf -c none $PKGINST "$1/vboxvideo_drv_71.so" f
    63     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_14.so" f
    64     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_15.so" f
    65     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_16.so" f
    66     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_17.so" f
    67     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_18.so" f
    68     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_19.so" f
    69     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_110.so" f
    70     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_70.so" f
    71     /usr/sbin/installf -c none $PKGINST "$1/vboxmouse_drv_71.so" f
    72 
    73     # Overwrite compressed with uncompressed file
    74     uncompress -f "$1/VBoxClient.Z" > /dev/null 2>&1
    75     uncompress -f "$1/VBoxService.Z" > /dev/null 2>&1
    76     uncompress -f "$1/VBoxControl.Z" > /dev/null 2>&1
    77     uncompress -f "$1/vboxvideo_drv_13.so.Z" > /dev/null 2>&1
    78     uncompress -f "$1/vboxvideo_drv_14.so.Z" > /dev/null 2>&1
    79     uncompress -f "$1/vboxvideo_drv_15.so.Z" > /dev/null 2>&1
    80     uncompress -f "$1/vboxvideo_drv_16.so.Z" > /dev/null 2>&1
    81     uncompress -f "$1/vboxvideo_drv_17.so.Z" > /dev/null 2>&1
    82     uncompress -f "$1/vboxvideo_drv_18.so.Z" > /dev/null 2>&1
    83     uncompress -f "$1/vboxvideo_drv_19.so.Z" > /dev/null 2>&1
    84     uncompress -f "$1/vboxvideo_drv_110.so.Z" > /dev/null 2>&1
    85     uncompress -f "$1/vboxvideo_drv_71.so.Z" > /dev/null 2>&1
    86     uncompress -f "$1/vboxmouse_drv_14.so.Z" > /dev/null 2>&1
    87     uncompress -f "$1/vboxmouse_drv_15.so.Z" > /dev/null 2>&1
    88     uncompress -f "$1/vboxmouse_drv_16.so.Z" > /dev/null 2>&1
    89     uncompress -f "$1/vboxmouse_drv_17.so.Z" > /dev/null 2>&1
    90     uncompress -f "$1/vboxmouse_drv_18.so.Z" > /dev/null 2>&1
    91     uncompress -f "$1/vboxmouse_drv_19.so.Z" > /dev/null 2>&1
    92     uncompress -f "$1/vboxmouse_drv_110.so.Z" > /dev/null 2>&1
    93     uncompress -f "$1/vboxmouse_drv_70.so.Z" > /dev/null 2>&1
    94     uncompress -f "$1/vboxmouse_drv_71.so.Z" > /dev/null 2>&1
     46    # VBox guest files
     47    uncompress_file "$1" "VBoxClient"
     48    uncompress_file "$1" "VBoxService"
     49    uncompress_file "$1" "VBoxControl"
     50
     51    # VBox Xorg Video drivers
     52    uncompress_file "$1" "vboxvideo_drv_13.so"
     53    uncompress_file "$1" "vboxvideo_drv_14.so"
     54    uncompress_file "$1" "vboxvideo_drv_15.so"
     55    uncompress_file "$1" "vboxvideo_drv_16.so"
     56    uncompress_file "$1" "vboxvideo_drv_17.so"
     57    uncompress_file "$1" "vboxvideo_drv_18.so"
     58    uncompress_file "$1" "vboxvideo_drv_19.so"
     59    uncompress_file "$1" "vboxvideo_drv_110.so"
     60    uncompress_file "$1" "vboxvideo_drv_70.so"
     61    uncompress_file "$1" "vboxvideo_drv_71.so"
     62
     63    # VBox Xorg Mouse drivers
     64    uncompress_file "$1" "vboxmouse_drv_13.so"
     65    uncompress_file "$1" "vboxmouse_drv_14.so"
     66    uncompress_file "$1" "vboxmouse_drv_15.so"
     67    uncompress_file "$1" "vboxmouse_drv_16.so"
     68    uncompress_file "$1" "vboxmouse_drv_17.so"
     69    uncompress_file "$1" "vboxmouse_drv_18.so"
     70    uncompress_file "$1" "vboxmouse_drv_19.so"
     71    uncompress_file "$1" "vboxmouse_drv_110.so"
     72    uncompress_file "$1" "vboxmouse_drv_70.so"
     73    uncompress_file "$1" "vboxmouse_drv_71.so"
    9574}
    9675
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette