src/util/distro-import/importer.py
changeset 2559 244beb5c12be
parent 2550 71fe32689f17
child 2612 7bf2387ebd19
--- a/src/util/distro-import/importer.py	Sat Sep 17 10:17:12 2011 -0700
+++ b/src/util/distro-import/importer.py	Mon Sep 19 02:03:09 2011 -0700
@@ -19,6 +19,7 @@
 #
 # CDDL HEADER END
 #
+
 #
 # Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved.
 #
@@ -1866,11 +1867,14 @@
                 end_package(curpkg)
                 curpkg = None
 
-        # Generate entire consolidation if we're generating any consolidation
+        #
+        # Generate entire incorporation if we're generating any consolidation
         # incorporations
+        #
         if consolidation_incorporations:
                 curpkg = start_package("entire")
-                curpkg.summary = "incorporation to lock all system packages to same build"
+                curpkg.summary = "Incorporation to lock all system packages " \
+                    "to the same build"
                 curpkg.desc = "This package constrains " \
                     "system package versions to the same build.  WARNING: Proper " \
                     "system update and correct package selection depend on the " \
@@ -1887,7 +1891,9 @@
                     "variant.opensolaris.zone=nonglobal"))
 
                 for incorp in consolidation_incorporations:
-                        action = actions.fromstr("depend fmri=%s type=incorporate" % incorp)
+                        action = actions.fromstr(
+                            "depend fmri=%s type=incorporate "
+                            "facet.version-lock.%s=true" % (incorp, incorp))
                         action.attrs["importer.source"] = "auto-generated"
                         curpkg.actions.append(action)
                         action = actions.fromstr("depend fmri=%s type=require" % incorp)
@@ -1896,10 +1902,13 @@
                         curpkg.actions.append(action)
 
                 for extra in extra_entire_contents:
-                        action = actions.fromstr("depend fmri=%s type=incorporate" % extra)
+                        extra_noversion = extra.split("@")[0] # remove version
+                        action = actions.fromstr(
+                            "depend fmri=%s type=incorporate "
+                            "facet.version-lock.%s=true"
+                            % (extra, extra_noversion))
                         action.attrs["importer.source"] = "command-line"
                         curpkg.actions.append(action)
-                        extra_noversion = extra.split("@")[0] # remove version
                         action = actions.fromstr("depend fmri=%s type=require" % extra_noversion)
                         action.attrs["importer.source"] = "command-line"
                         action.attrs["importer.no-version"] = "true"