Merge lp:~jameinel/bzr/2.0.2-make-without-gnu into lp:bzr/2.0

Proposed by John A Meinel
Status: Merged
Approved by: Robert Collins
Approved revision: no longer in the source branch.
Merged at revision: not available
Proposed branch: lp:~jameinel/bzr/2.0.2-make-without-gnu
Merge into: lp:bzr/2.0
Diff against target: 87 lines
1 file modified
Makefile (+14/-14)
To merge this branch: bzr merge lp:~jameinel/bzr/2.0.2-make-without-gnu
Reviewer Review Type Date Requested Status
Robert Collins (community) Approve
Ian Clatworthy Approve
Review via email: mp+13574@code.launchpad.net
To post a comment you must log in.
Revision history for this message
John A Meinel (jameinel) wrote :

This change was made by Bernhard Voelker. I'm not sure what system he was compiling on, but it seems that the default 'make' is not GNU Make. Which means that 'simply expanded variables' (aka :=) was not supported.

This is the GNU documentation that I could find:
  http://www.gnu.org/software/make/manual/make.html#Flavors

I'm not 100% sure if we want to take this patch or not. On the one hand, if it doesn't cause us much overhead to support more than GNU Make, it seems reasonable. Reading the documentation, having to re-expand $(wildcard) substitutions on every reference (rather than at definition time) seems a bit unfortunate.

I don't think it is a correctness thing, so I'm willing to put it up for review.

Thoughts?

Revision history for this message
Ian Clatworthy (ian-clatworthy) wrote :

It's been 15 years since I last looked/cared about the nuances of Makefile syntax so take my vote very lightly. From a risk perspective though, these changes only impact the doc (and one BUILDOUT setting) and look safe enough to a naive reviewer like me.

review: Approve
Revision history for this message
Robert Collins (lifeless) wrote :

 review approve
 merge approve

John: This change is fine, variables will be evaluated once; it changes
from immediate to lazy is all.

-Rob

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Makefile'
2--- Makefile 2009-09-09 13:21:33 +0000
3+++ Makefile 2009-10-19 15:20:25 +0000
4@@ -174,7 +174,7 @@
5 ### Documentation Website ###
6
7 # Where to build the website
8-DOC_WEBSITE_BUILD := build_doc_website
9+DOC_WEBSITE_BUILD = build_doc_website
10
11 # Build and package docs into a website, complete with downloads.
12 doc-website: html-sphinx pdf-sphinx
13@@ -190,13 +190,13 @@
14 # support our "plain" html documentation so that Sphinx is not a hard
15 # dependency for packagers on older platforms.
16
17-rst2html := $(PYTHON) tools/rst2html.py --link-stylesheet --footnote-references=superscript --halt=warning
18+rst2html = $(PYTHON) tools/rst2html.py --link-stylesheet --footnote-references=superscript --halt=warning
19
20 # translate txt docs to html
21-derived_txt_files := \
22+derived_txt_files = \
23 doc/en/user-reference/bzr_man.txt \
24 doc/en/release-notes/NEWS.txt
25-txt_all := \
26+txt_all = \
27 doc/en/tutorials/tutorial.txt \
28 doc/en/tutorials/using_bazaar_with_launchpad.txt \
29 doc/en/tutorials/centralized_workflow.txt \
30@@ -209,14 +209,14 @@
31 doc/en/upgrade-guide/index.txt \
32 doc/index.txt \
33 $(wildcard doc/index.*.txt)
34-txt_nohtml := \
35+txt_nohtml = \
36 doc/en/user-guide/index.txt \
37 doc/es/user-guide/index.txt \
38 doc/ru/user-guide/index.txt
39-txt_files := $(filter-out $(txt_nohtml), $(txt_all))
40-htm_files := $(patsubst %.txt, %.html, $(txt_files))
41+txt_files = $(filter-out $(txt_nohtml), $(txt_all))
42+htm_files = $(patsubst %.txt, %.html, $(txt_files))
43
44-non_txt_files := \
45+non_txt_files = \
46 doc/default.css \
47 $(wildcard doc/*/bzr-en-quick-reference.svg) \
48 $(wildcard doc/*/bzr-en-quick-reference.png) \
49@@ -231,7 +231,7 @@
50
51 # doc/developers/*.txt files that should *not* be individually
52 # converted to HTML
53-dev_txt_nohtml := \
54+dev_txt_nohtml = \
55 doc/developers/add.txt \
56 doc/developers/annotate.txt \
57 doc/developers/bundle-creation.txt \
58@@ -257,9 +257,9 @@
59 doc/developers/status.txt \
60 doc/developers/uncommit.txt
61
62-dev_txt_all := $(wildcard $(addsuffix /*.txt, doc/developers))
63-dev_txt_files := $(filter-out $(dev_txt_nohtml), $(dev_txt_all))
64-dev_htm_files := $(patsubst %.txt, %.html, $(dev_txt_files))
65+dev_txt_all = $(wildcard $(addsuffix /*.txt, doc/developers))
66+dev_txt_files = $(filter-out $(dev_txt_nohtml), $(dev_txt_all))
67+dev_htm_files = $(patsubst %.txt, %.html, $(dev_txt_files))
68
69 doc/en/user-guide/index-plain.html: $(wildcard $(addsuffix /*.txt, doc/en/user-guide))
70 $(rst2html) --stylesheet=../../default.css $(dir $@)index-plain.txt $@
71@@ -301,7 +301,7 @@
72 docs-plain: $(ALL_DOCS)
73
74 # produce a tree containing just the final docs, ready for uploading to the web
75-HTMLDIR := html_docs
76+HTMLDIR = html_docs
77 html-plain: docs-plain
78 $(PYTHON) tools/win32/ostools.py copytree $(WEB_DOCS) $(HTMLDIR)
79
80@@ -327,7 +327,7 @@
81 # These are files that need to be copied into the build location to boostrap
82 # the build process.
83 # Note that the path is relative to tools/win32
84-BUILDOUT_FILES := buildout.cfg \
85+BUILDOUT_FILES = buildout.cfg \
86 buildout-templates/bin/build-installer.bat.in \
87 ostools.py bootstrap.py
88

Subscribers

People subscribed via source and target branches