From 0bce60b8b6b980b6fd3e2987ed7cfc8e3dc0daeb Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Thu, 27 Mar 2003 05:18:10 +0000 Subject: [PATCH] Really minor tweaks [SVN r18099] --- new/boostbook.jam | 48 +++++++++++++++++++++-------------------------- v2/boostbook.jam | 48 +++++++++++++++++++++-------------------------- 2 files changed, 42 insertions(+), 54 deletions(-) diff --git a/new/boostbook.jam b/new/boostbook.jam index e3e6490f5..93c3ac055 100644 --- a/new/boostbook.jam +++ b/new/boostbook.jam @@ -229,7 +229,7 @@ rule boostbook-target-class ( name : project : sources * : requirements * basic-target.__init__ $(name) : $(project) : $(sources) : $(requirements) : $(default-build) ; self.catalog-entries = $(catalog-entries) ; - + rule construct ( source-targets * : property-set ) { local path = [ project.attribute $(self.project) location ] ; @@ -267,37 +267,31 @@ rule boostbook-target-class ( name : project : sources * : requirements * case pdf : type = PDF ; case ps : type = PS ; } - + if $(manifest) { - for local i in $(source-targets) - { - local base-target = [ generators.construct $(self.project) - : DOCBOOK : $(property-set) : $(i) ] ; - $(base-target).depends $(catalog) ; + local base-target = [ generators.construct $(self.project) + : DOCBOOK : $(property-set) : $(source-targets) ] ; + $(base-target).depends $(catalog) ; - local target = [ generators.construct $(self.project) $(manifest) - : $(type) : $(property-set) : $(base-target) ] ; - $(target).set-path $(format) ; + local target = [ generators.construct $(self.project) $(manifest) + : $(type) : $(property-set) : $(base-target) ] ; + $(target).set-path $(format) ; - targets += $(target) ; - } + targets += $(target) ; } else { - for local i in $(source-targets) - { - local target = [ generators.construct $(self.project) - : $(type) : $(property-set) : $(i) ] ; + local target = [ generators.construct $(self.project) + : $(type) : $(property-set) : $(source-targets) ] ; - if ! $(target) - { - errors.error "Cannot build documentation type '$(format)'" ; - } - else - { - $(target).depends $(catalog) ; - targets += $(target) ; - } + if ! $(target) + { + errors.error "Cannot build documentation type '$(format)'" ; + } + else + { + $(target).depends $(catalog) ; + targets += $(target) ; } } @@ -307,12 +301,12 @@ rule boostbook-target-class ( name : project : sources * : requirements * class boostbook-target-class : basic-target ; -rule boostbook ( target-name : source : requirements * : default-build * ) +rule boostbook ( target-name : sources * : requirements * : default-build * ) { local project = [ CALLER_MODULE ] ; targets.main-target-alternative - [ new boostbook-target-class $(target-name) : $(project) : $(source) + [ new boostbook-target-class $(target-name) : $(project) : $(sources) : [ targets.main-target-requirements $(requirements) : $(project) ] : [ targets.main-target-default-build $(default-build) : $(project) ] : $(.docbook-xsl-dir) $(.docbook-dtd-dir) diff --git a/v2/boostbook.jam b/v2/boostbook.jam index e3e6490f5..93c3ac055 100644 --- a/v2/boostbook.jam +++ b/v2/boostbook.jam @@ -229,7 +229,7 @@ rule boostbook-target-class ( name : project : sources * : requirements * basic-target.__init__ $(name) : $(project) : $(sources) : $(requirements) : $(default-build) ; self.catalog-entries = $(catalog-entries) ; - + rule construct ( source-targets * : property-set ) { local path = [ project.attribute $(self.project) location ] ; @@ -267,37 +267,31 @@ rule boostbook-target-class ( name : project : sources * : requirements * case pdf : type = PDF ; case ps : type = PS ; } - + if $(manifest) { - for local i in $(source-targets) - { - local base-target = [ generators.construct $(self.project) - : DOCBOOK : $(property-set) : $(i) ] ; - $(base-target).depends $(catalog) ; + local base-target = [ generators.construct $(self.project) + : DOCBOOK : $(property-set) : $(source-targets) ] ; + $(base-target).depends $(catalog) ; - local target = [ generators.construct $(self.project) $(manifest) - : $(type) : $(property-set) : $(base-target) ] ; - $(target).set-path $(format) ; + local target = [ generators.construct $(self.project) $(manifest) + : $(type) : $(property-set) : $(base-target) ] ; + $(target).set-path $(format) ; - targets += $(target) ; - } + targets += $(target) ; } else { - for local i in $(source-targets) - { - local target = [ generators.construct $(self.project) - : $(type) : $(property-set) : $(i) ] ; + local target = [ generators.construct $(self.project) + : $(type) : $(property-set) : $(source-targets) ] ; - if ! $(target) - { - errors.error "Cannot build documentation type '$(format)'" ; - } - else - { - $(target).depends $(catalog) ; - targets += $(target) ; - } + if ! $(target) + { + errors.error "Cannot build documentation type '$(format)'" ; + } + else + { + $(target).depends $(catalog) ; + targets += $(target) ; } } @@ -307,12 +301,12 @@ rule boostbook-target-class ( name : project : sources * : requirements * class boostbook-target-class : basic-target ; -rule boostbook ( target-name : source : requirements * : default-build * ) +rule boostbook ( target-name : sources * : requirements * : default-build * ) { local project = [ CALLER_MODULE ] ; targets.main-target-alternative - [ new boostbook-target-class $(target-name) : $(project) : $(source) + [ new boostbook-target-class $(target-name) : $(project) : $(sources) : [ targets.main-target-requirements $(requirements) : $(project) ] : [ targets.main-target-default-build $(default-build) : $(project) ] : $(.docbook-xsl-dir) $(.docbook-dtd-dir)