Changeset 53660


Ignore:
Timestamp:
Jul 11, 2009, 10:43:29 AM (10 years ago)
Author:
jmr@…
Message:

Remove stubs for the port image compaction feature, which is unlikely to ever be implemented.

Location:
trunk/base/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/base/src/port/port-help.tcl

    r51780 r53660  
    4141--work        Removes work directory (default)
    4242--all         Removes everything from above
    43 }
    44 
    45 set porthelp(compact) {
    46 Compact the given ports (unimplemented)
    4743}
    4844
     
    274270}
    275271
    276 set porthelp(uncompact) {
    277 Uncompact a port (unimplemented)
    278 }
    279 
    280272set porthelp(uninstall) {
    281273Uninstall the given ports
  • trunk/base/src/port/port.tcl

    r53371 r53660  
    20272027
    20282028
    2029 proc action_compact { action portlist opts } {
    2030     set status 0
    2031     if {[require_portlist portlist]} {
    2032         return 1
    2033     }
    2034     foreachport $portlist {
    2035         if { [catch {portimage::compact $portname [composite_version $portversion [array get variations]]} result] } {
    2036             global errorInfo
    2037             ui_debug "$errorInfo"
    2038             break_softcontinue "port compact failed: $result" 1 status
    2039         }
    2040     }
    2041 
    2042     return $status
    2043 }
    2044 
    2045 
    2046 proc action_uncompact { action portlist opts } {
    2047     set status 0
    2048     if {[require_portlist portlist]} {
    2049         return 1
    2050     }
    2051     foreachport $portlist {
    2052         if { [catch {portimage::uncompact $portname [composite_version $portversion [array get variations]]} result] } {
    2053             global errorInfo
    2054             ui_debug "$errorInfo"
    2055             break_softcontinue "port uncompact failed: $result" 1 status
    2056         }
    2057     }
    2058    
    2059     return $status
    2060 }
    2061 
    2062 
    20632029proc action_dependents { action portlist opts } {
    20642030    if {[require_portlist portlist]} {
     
    29952961    version     [list action_version        [action_args_const none]] \
    29962962    platform    [list action_platform       [action_args_const none]] \
    2997     compact     [list action_compact        [action_args_const ports]] \
    2998     uncompact   [list action_uncompact      [action_args_const ports]] \
    29992963    \
    30002964    uninstall   [list action_uninstall      [action_args_const ports]] \
  • trunk/base/src/registry1.0/portimage.tcl

    r52987 r53660  
    5656# file_map
    5757#
    58 # Compacting and Uncompacting of port images to save space will be implemented
    59 # at some point.
    60 #
    6158# For the creating and removing of links during activation and deactivation,
    6259# code very similar to what is used in portinstall is used.
     
    115112                return -code error "Image error: ${name} @${version}_${revision}${variants} is already active."
    116113        }
    117         if { [registry::property_retrieve $ref compact] != 0 } {
    118                 return -code error "Image error: ${name} @${version}_${revision}${variants} is compactd."
    119         }
    120114
    121115        set imagedir [registry::property_retrieve $ref imagedir]
     
    180174        if { [registry::property_retrieve $ref active] != 1 } {
    181175                return -code error "Image error: ${name} @${fqversion} is not active."
    182         }
    183         if { [registry::property_retrieve $ref compact] != 0 } {
    184                 return -code error "Image error: ${name} @${fqversion} is compactd."
    185         }
     176        }
    186177
    187178        set imagedir [registry::property_retrieve $ref imagedir]
     
    201192
    202193        registry::write_entry $ref
    203 
    204 }
    205 
    206 proc compact {name v} {
    207         global UI_PREFIX
    208 
    209         return -code error "Image error: compact/uncompact not yet implemented."
    210 
    211 }
    212 
    213 proc uncompact {name v} {
    214         global UI_PREFIX
    215 
    216         return -code error "Image error: compact/uncompact not yet implemented."
    217194
    218195}
  • trunk/base/src/registry1.0/registry.tcl

    r51133 r53660  
    6767                        property_store $ref imagedir $imagedir
    6868                        property_store $ref active 0
    69                         property_store $ref compact 0
    7069                }
    7170
  • trunk/base/src/registry2.0/portimage.tcl

    r53280 r53660  
    5757# will also remove all of the references of the files from the registry's
    5858# file_map
    59 #
    60 # Compacting and Uncompacting of port images to save space will be implemented
    61 # at some point.
    6259#
    6360# For the creating and removing of links during activation and deactivation,
     
    115112            return -code error "Image error: ${name} @${version}_${revision}${variants} is already active."
    116113        }
    117 
    118         # compaction is not yet supported
    119         #if { [$requested compact] != 0 } {
    120         #    return -code error "Image error: ${name} @${version}_${revision}${variants} is compacted."
    121         #}
    122114    }
    123115
     
    167159    }
    168160
    169     # compaction not yet supported
    170     #if { [registry::property_retrieve $ref compact] != 0 } {
    171     #    return -code error "Image error: ${name} @${specifier} is compacted."
    172     #}
    173 
    174161    registry::check_dependents $port $force
    175162
     
    179166    _deactivate_contents $requested $force
    180167    $requested state imaged
    181 }
    182 
    183 proc compact {name v} {
    184     global UI_PREFIX
    185 
    186     throw registry::image-error "Image error: compact/uncompact not yet implemented."
    187 }
    188 
    189 proc uncompact {name v} {
    190     global UI_PREFIX
    191 
    192     throw registry::image-error "Image error: compact/uncompact not yet implemented."
    193168}
    194169
Note: See TracChangeset for help on using the changeset viewer.