# HG changeset patch # User Norm Jacobs # Date 1375379636 25200 # Node ID a87a9e85090e5c96bc120327e009f95284f44762 # Parent cbda05bf5f9d6c03a06d4a2aa69a2b7812fe3d07 17231570 full userland build sporadically fails during 'pkgsend publish' diff -r cbda05bf5f9d -r a87a9e85090e components/Makefile --- a/components/Makefile Wed Jul 31 09:36:35 2013 -0600 +++ b/components/Makefile Thu Aug 01 10:53:56 2013 -0700 @@ -66,6 +66,13 @@ publish: MAKEFLAGS += PKGLINT=/bin/true endif +# In order to work around an IPS simultaneous publication issue and to improve +# top level build performance, we postpone catalog and index updates until the +# end of the build. Individual component builds postpone the updates until +# they have published all of their packages. +publish: MAKEFLAGS += DISABLE_IPS_CATALOG_AND_INDEX_UPDATES=yes + + .DEFAULT: publish build install publish test: $(COMPONENT_DIRS) @@ -125,7 +132,7 @@ $(@:%=--component %) --make $(TARGET) $(LOG) publish: - $(PKGREPO) rebuild -s $(PKG_REPO) + $(PKGREPO) refresh -s $(PKG_REPO) $(WS_TOOLS)/userland-incorporator --repository $(PKG_REPO) \ -p pkg:/consolidation/$(CONSOLIDATION)/$(CONSOLIDATION)-incorporation@0.$(OS_VERSION),$(BUILD_VERSION) \ -s "$(CONSOLIDATION) consolidation incorporation" \ @@ -133,6 +140,7 @@ -c $(CONSOLIDATION) >$(WS_LOGS)/$(CONSOLIDATION)-incorporation.p5m $(PKGSEND) -s $(PKG_REPO) publish --fmri-in-manifest \ $(WS_LOGS)/$(CONSOLIDATION)-incorporation.p5m + $(PKGREPO) refresh -s $(PKG_REPO) # pkglint all of the published manifests in one batch. ifdef CANONICAL_REPO @echo 'pkglinting all package manifests...' diff -r cbda05bf5f9d -r a87a9e85090e components/meta-packages/history/Makefile --- a/components/meta-packages/history/Makefile Wed Jul 31 09:36:35 2013 -0600 +++ b/components/meta-packages/history/Makefile Thu Aug 01 10:53:56 2013 -0700 @@ -18,7 +18,7 @@ # # CDDL HEADER END # -# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. # include ../../../make-rules/shared-macros.mk @@ -54,7 +54,7 @@ $(PKGMOGRIFY) -D CONSOLIDATION=$(CONSOLIDATION) $< > $@ $(MANIFEST_BASE)-%.published: $(MANIFEST_BASE)-%.mogrified $(BUILD_DIR) - $(PKGSEND) -s $(PKG_REPO) publish --fmri-in-manifest $< + $(PKGSEND) -s $(PKG_REPO) publish --fmri-in-manifest --no-catalog $< $(CP) $< $@ $(BUILD_DIR)/.linted-$(MACH): $(MOGRIFIED) $(BUILD_DIR) @@ -64,6 +64,9 @@ $(TOUCH) $@ $(BUILD_DIR)/.published-$(MACH): $(BUILD_DIR)/.linted-$(MACH) $(PUBLISHED) +ifndef DISABLE_IPS_CATALOG_AND_INDEX_UPDATES + $(PKGREPO) refresh -s $(PKG_REPO) +endif $(TOUCH) $@ publish: $(BUILD_DIR)/.published-$(MACH) diff -r cbda05bf5f9d -r a87a9e85090e make-rules/ips.mk --- a/make-rules/ips.mk Wed Jul 31 09:36:35 2013 -0600 +++ b/make-rules/ips.mk Thu Aug 01 10:53:56 2013 -0700 @@ -286,14 +286,19 @@ # published -PKGSEND_PUBLISH_OPTIONS = -s $(WS_REPO) publish --fmri-in-manifest +PKGSEND_PUBLISH_OPTIONS = -s $(PKG_REPO) publish --fmri-in-manifest +PKGSEND_PUBLISH_OPTIONS += --no-catalog PKGSEND_PUBLISH_OPTIONS += $(PKG_PROTO_DIRS:%=-d %) PKGSEND_PUBLISH_OPTIONS += -T \*.py + $(MANIFEST_BASE)-%.published: $(MANIFEST_BASE)-%.depend.res $(BUILD_DIR)/.linted-$(MACH) $(PKGSEND) $(PKGSEND_PUBLISH_OPTIONS) $< $(PKGFMT) <$< >$@ $(BUILD_DIR)/.published-$(MACH): $(PUBLISHED) +ifndef DISABLE_IPS_CATALOG_AND_INDEX_UPDATES + $(PKGREPO) refresh -s $(PKG_REPO) +endif $(TOUCH) $@ print-package-names: canonical-manifests