Ticket #9433: deps.2

File deps.2, 22.4 KB (added by vbraun, 9 years ago)

Updated spkg/standard/deps

Line 
1###############################################################################
2# SAGE_ROOT/spkg/standard/deps - the "real" Sage Makefile (for building)
3###############################################################################
4
5INST = installed
6# Let e.g. SAGE_ROOT/spkg/install pass options to sage-spkg, i.e. currently
7# "-f", to force rebuilding dependent packages during an upgrade (#9896):
8SAGE_SPKG = sage-spkg $${SAGE_SPKG_OPTS}
9INSTALL = $(SAGE_ROOT)/spkg/pipestatus
10
11###############################################################################
12# The base system; required in order to run sage-spkg
13###############################################################################
14BASE = $(INST)/$(PREREQ) $(INST)/$(DIR) $(INST)/$(SAGE_BZIP2)
15
16# The following is obsolete (#9896):
17#
18# # Also install scripts before we continue with other spkgs (cf. #8306)
19# BASE += $(INST)/$(SAGE_SCRIPTS)
20#
21# Rather than making *all* standard packages depend on SAGE_SCRIPTS (which
22# triggers the rebuild of *every* package on an upgrade), add SAGE_SCRIPTS
23# to the dependencies of only those packages that rely on them.
24# These are (as of Sage 4.6.alpha3):
25# - The Sage library, $(SAGE)
26# - sagetex, but this in turn depends on $(SAGE)
27
28# Tell make not to look for files with these (base)names:
29.PHONY: all base scripts
30
31# Targets
32all: $(BASE) \
33     $(INST)/$(ATLAS) \
34     $(INST)/$(BLAS) \
35     $(INST)/$(BOEHM_GC) \
36     $(INST)/$(BOOST_CROPPED) \
37     $(INST)/$(CDDLIB) \
38     $(INST)/$(CEPHES) \
39     $(INST)/$(CLIQUER) \
40     $(INST)/$(CONWAY) \
41     $(INST)/$(CVXOPT) \
42     $(INST)/$(CYTHON) \
43     $(INST)/$(DOCUTILS) \
44     $(INST)/$(ECL) \
45     $(INST)/$(ECLIB) \
46     $(INST)/$(ECM) \
47     $(INST)/$(ELLIPTIC_CURVES) \
48     $(INST)/$(EXAMPLES) \
49     $(INST)/$(EXTCODE) \
50     $(INST)/$(F2C) \
51     $(INST)/$(FLINT) \
52     $(INST)/$(FLINTQS) \
53     $(INST)/$(FORTRAN) \
54     $(INST)/$(FPLLL) \
55     $(INST)/$(FREETYPE) \
56     $(INST)/$(G2RED) \
57     $(INST)/$(GAP) \
58     $(INST)/$(GD) \
59     $(INST)/$(GDMODULE) \
60     $(INST)/$(GFAN) \
61     $(INST)/$(GIVARO) \
62     $(INST)/$(GLPK) \
63     $(INST)/$(GNUTLS) \
64     $(INST)/$(GRAPHS) \
65     $(INST)/$(GSL) \
66     $(INST)/$(ICONV) \
67     $(INST)/$(IML) \
68     $(INST)/$(IPYTHON) \
69     $(INST)/$(JINJA2) \
70     $(INST)/$(LAPACK) \
71     $(INST)/$(LCALC) \
72     $(INST)/$(LIBGCRYPT) \
73     $(INST)/$(LIBGPG_ERROR) \
74     $(INST)/$(LIBM4RI) \
75     $(INST)/$(LIBPNG) \
76     $(INST)/$(LINBOX) \
77     $(INST)/$(MATPLOTLIB) \
78     $(INST)/$(MAXIMA) \
79     $(INST)/$(MERCURIAL) \
80     $(INST)/$(MOIN) \
81     $(INST)/$(MPFI) \
82     $(INST)/$(MPFR) \
83     $(INST)/$(MPIR) \
84     $(INST)/$(MPMATH) \
85     $(INST)/$(NETWORKX) \
86     $(INST)/$(NTL) \
87     $(INST)/$(NUMPY) \
88     $(INST)/$(OPENCDK) \
89     $(INST)/$(PALP) \
90     $(INST)/$(PARI) \
91     $(INST)/$(PATCH) \
92     $(INST)/$(PEXPECT) \
93     $(INST)/$(PIL) \
94     $(INST)/$(POLYBORI) \
95     $(INST)/$(POLYTOPES_DB) \
96     $(INST)/$(PYCRYPTO) \
97     $(INST)/$(PYGMENTS) \
98     $(INST)/$(PYNAC) \
99     $(INST)/$(PYTHON) \
100     $(INST)/$(PYTHON_GNUTLS) \
101     $(INST)/$(RATPOINTS) \
102     $(INST)/$(R) \
103     $(INST)/$(READLINE) \
104     $(INST)/$(RUBIKS) \
105     $(INST)/$(SAGE) \
106     $(INST)/$(SAGE_ROOT_REPO) \
107     $(INST)/$(SAGE_SCRIPTS) \
108     $(INST)/$(SAGENB) \
109     $(INST)/$(SAGETEX) \
110     $(INST)/$(SCIPY) \
111     $(INST)/$(SCIPY_SANDBOX) \
112     $(INST)/$(SCONS) \
113     $(INST)/$(SETUPTOOLS) \
114     $(INST)/$(SINGULAR) \
115     $(INST)/$(SPHINX) \
116     $(INST)/$(SQLALCHEMY) \
117     $(INST)/$(SQLITE) \
118     $(INST)/$(SYMMETRICA) \
119     $(INST)/$(SYMPOW) \
120     $(INST)/$(SYMPY) \
121     $(INST)/$(TACHYON) \
122     $(INST)/$(TERMCAP) \
123     $(INST)/$(TWISTED) \
124     $(INST)/$(WEAVE) \
125     $(INST)/$(ZLIB) \
126     $(INST)/$(ZNPOLY) \
127     $(INST)/$(ZODB)
128# Necessary when #9906 gets merged:
129#     $(INST)/$(RPY) \
130# (But move this up; it's just here because 'make' doesn't support comments
131# within line continuations.)
132
133base: $(BASE)
134
135scripts: $(INST)/$(SAGE_SCRIPTS) # depends on $(BASE)
136
137###############################################################################
138# Building the base system
139###############################################################################
140$(INST)/$(DIR):
141        $(INSTALL) "base/$(DIR)-install 2>&1" "tee -a $(SAGE_LOGS)/$(DIR).log"
142
143$(INST)/$(PREREQ): $(INST)/$(DIR)
144        $(INSTALL) "base/$(PREREQ)-install 2>&1" "tee -a $(SAGE_LOGS)/$(PREREQ).log"
145
146$(INST)/$(SAGE_BZIP2): $(INST)/$(PREREQ) $(INST)/$(DIR)
147        $(INSTALL) "base/$(SAGE_BZIP2)-install 2>&1" "tee -a $(SAGE_LOGS)/$(SAGE_BZIP2).log"
148
149$(INST)/$(SAGE_SCRIPTS): $(BASE)
150        $(INSTALL) "$(SAGE_SPKG) $(SAGE_SCRIPTS) 2>&1" "tee -a $(SAGE_LOGS)/$(SAGE_SCRIPTS).log"
151
152###############################################################################
153# Building normal packages
154###############################################################################
155$(INST)/$(ATLAS): $(BASE) $(INST)/$(LAPACK) $(INST)/$(PYTHON) $(INST)/$(PATCH)
156        $(INSTALL) "$(SAGE_SPKG) $(ATLAS) 2>&1" "tee -a $(SAGE_LOGS)/$(ATLAS).log"
157
158$(INST)/$(BOEHM_GC): $(BASE) $(INST)/$(PATCH)
159        $(INSTALL) "$(SAGE_SPKG) $(BOEHM_GC) 2>&1" "tee -a $(SAGE_LOGS)/$(BOEHM_GC).log"
160
161$(INST)/$(BOOST_CROPPED): $(BASE) $(INST)/$(PATCH)
162        $(INSTALL) "$(SAGE_SPKG) $(BOOST_CROPPED) 2>&1" "tee -a $(SAGE_LOGS)/$(BOOST_CROPPED).log"
163
164$(INST)/$(CLIQUER): $(BASE) $(INST)/$(PATCH)
165        $(INSTALL) "$(SAGE_SPKG) $(CLIQUER) 2>&1" "tee -a $(SAGE_LOGS)/$(CLIQUER).log"
166
167$(INST)/$(TERMCAP): $(BASE) $(INST)/$(PATCH)
168        $(INSTALL) "$(SAGE_SPKG) $(TERMCAP) 2>&1" "tee -a $(SAGE_LOGS)/$(TERMCAP).log"
169
170$(INST)/$(READLINE): $(BASE) $(INST)/$(PATCH)
171        $(INSTALL) "$(SAGE_SPKG) $(READLINE) 2>&1" "tee -a $(SAGE_LOGS)/$(READLINE).log"
172
173$(INST)/$(ICONV): $(BASE) $(INST)/$(PATCH)
174        $(INSTALL) "$(SAGE_SPKG) $(ICONV) 2>&1" "tee -a $(SAGE_LOGS)/$(ICONV).log"
175
176$(INST)/$(DOCUTILS): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
177        $(INSTALL) "$(SAGE_SPKG) $(DOCUTILS) 2>&1" "tee -a $(SAGE_LOGS)/$(DOCUTILS).log"
178
179$(INST)/$(ELLIPTIC_CURVES): $(BASE) $(INST)/$(PATCH)
180        $(INSTALL) "$(SAGE_SPKG) $(ELLIPTIC_CURVES) 2>&1" "tee -a $(SAGE_LOGS)/$(ELLIPTIC_CURVES).log"
181
182$(INST)/$(CONWAY): $(BASE) $(INST)/$(PATCH)
183        $(INSTALL) "$(SAGE_SPKG) $(CONWAY) 2>&1" "tee -a $(SAGE_LOGS)/$(CONWAY).log"
184
185$(INST)/$(GRAPHS): $(BASE) $(INST)/$(PATCH)
186        $(INSTALL) "$(SAGE_SPKG) $(GRAPHS) 2>&1" "tee -a $(SAGE_LOGS)/$(GRAPHS).log"
187
188$(INST)/$(GLPK): $(BASE) $(INST)/$(MPIR) $(INST)/$(ZLIB) $(INST)/$(PATCH)
189        $(INSTALL) "$(SAGE_SPKG) $(GLPK) 2>&1" "tee -a $(SAGE_LOGS)/$(GLPK).log"
190
191$(INST)/$(PYTHON): $(BASE) $(INST)/$(ZLIB) $(INST)/$(TERMCAP) \
192                   $(INST)/$(READLINE) $(INST)/$(SQLITE) \
193                   $(INST)/$(GNUTLS) $(INST)/$(LIBPNG) $(INST)/$(PATCH)
194        $(INSTALL) "$(SAGE_SPKG) $(PYTHON) 2>&1" "tee -a $(SAGE_LOGS)/$(PYTHON).log"
195
196$(INST)/$(PATCH): $(BASE)
197        $(INSTALL) "$(SAGE_SPKG) $(PATCH) 2>&1" "tee -a $(SAGE_LOGS)/$(PATCH).log"
198
199$(INST)/$(MPIR): $(BASE) $(INST)/$(ICONV) $(INST)/$(PATCH)
200        $(INSTALL) "$(SAGE_SPKG) $(MPIR) 2>&1" "tee -a $(SAGE_LOGS)/$(MPIR).log"
201
202$(INST)/$(GSL): $(BASE) $(INST)/$(ATLAS) $(INST)/$(PATCH)
203        $(INSTALL) "$(SAGE_SPKG) $(GSL) 2>&1" "tee -a $(SAGE_LOGS)/$(GSL).log"
204
205$(INST)/$(NTL): $(BASE) $(INST)/$(MPIR) $(INST)/$(PATCH)
206        $(INSTALL) "$(SAGE_SPKG) $(NTL) 2>&1" "tee -a $(SAGE_LOGS)/$(NTL).log"
207
208$(INST)/$(FPLLL): $(BASE) $(INST)/$(MPIR) $(INST)/$(MPFR) $(INST)/$(PATCH)
209        $(INSTALL) "$(SAGE_SPKG) $(FPLLL) 2>&1" "tee -a $(SAGE_LOGS)/$(FPLLL).log"
210
211$(INST)/$(PARI): $(BASE) $(INST)/$(TERMCAP) $(INST)/$(READLINE) \
212                 $(INST)/$(MPIR) $(INST)/$(PATCH)
213        $(INSTALL) "$(SAGE_SPKG) $(PARI) 2>&1" "tee -a $(SAGE_LOGS)/$(PARI).log"
214
215$(INST)/$(POLYBORI): $(BASE) $(INST)/$(PYTHON) $(INST)/$(SCONS) \
216                     $(INST)/$(BOOST_CROPPED) $(INST)/$(LIBM4RI) \
217                     $(INST)/$(GD) $(INST)/$(PATCH)
218        $(INSTALL) "$(SAGE_SPKG) $(POLYBORI) 2>&1" "tee -a $(SAGE_LOGS)/$(POLYBORI).log"
219
220$(INST)/$(POLYTOPES_DB): $(BASE) $(INST)/$(PATCH)
221        $(INSTALL) "$(SAGE_SPKG) $(POLYTOPES_DB) 2>&1" "tee -a $(SAGE_LOGS)/$(POLYTOPES_DB).log"
222
223$(INST)/$(MPFR): $(BASE) $(INST)/$(MPIR) $(INST)/$(PATCH)
224        $(INSTALL) "$(SAGE_SPKG) $(MPFR) 2>&1" "tee -a $(SAGE_LOGS)/$(MPFR).log"
225
226$(INST)/$(MPFI): $(BASE) $(INST)/$(MPIR) $(INST)/$(MPFR) $(INST)/$(PATCH)
227        $(INSTALL) "$(SAGE_SPKG) $(MPFI) 2>&1" "tee -a $(SAGE_LOGS)/$(MPFI).log"
228
229$(INST)/$(GIVARO): $(BASE) $(INST)/$(MPIR) $(INST)/$(PATCH)
230        $(INSTALL) "$(SAGE_SPKG) $(GIVARO) 2>&1" "tee -a $(SAGE_LOGS)/$(GIVARO).log"
231
232$(INST)/$(LINBOX): $(BASE) $(INST)/$(MPIR) $(INST)/$(NTL) $(INST)/$(GIVARO) \
233                   $(INST)/$(GSL) $(INST)/$(ATLAS) $(INST)/$(PATCH)
234        $(INSTALL) "$(SAGE_SPKG) $(LINBOX) 2>&1" "tee -a $(SAGE_LOGS)/$(LINBOX).log"
235
236$(INST)/$(IML): $(BASE) $(INST)/$(MPIR) $(INST)/$(GSL) $(INST)/$(PATCH)
237        $(INSTALL) "$(SAGE_SPKG) $(IML) 2>&1" "tee -a $(SAGE_LOGS)/$(IML).log"
238
239$(INST)/$(ECLIB): $(BASE) $(INST)/$(MPIR) $(INST)/$(PARI) $(INST)/$(NTL) $(INST)/$(PATCH)
240        $(INSTALL) "$(SAGE_SPKG) $(ECLIB) 2>&1" "tee -a $(SAGE_LOGS)/$(ECLIB).log"
241
242$(INST)/$(G2RED): $(BASE) $(INST)/$(PARI) $(INST)/$(PATCH)
243        $(INSTALL) "$(SAGE_SPKG) $(G2RED) 2>&1" "tee -a $(SAGE_LOGS)/$(G2RED).log"
244
245$(INST)/$(PALP): $(BASE) $(INST)/$(PATCH)
246        $(INSTALL) "$(SAGE_SPKG) $(PALP) 2>&1" "tee -a $(SAGE_LOGS)/$(PALP).log"
247
248$(INST)/$(LCALC): $(BASE) $(INST)/$(PARI) $(INST)/$(MPFR) $(INST)/$(PATCH)
249        $(INSTALL) "$(SAGE_SPKG) $(LCALC) 2>&1" "tee -a $(SAGE_LOGS)/$(LCALC).log"
250
251$(INST)/$(PYNAC): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
252        $(INSTALL) "$(SAGE_SPKG) $(PYNAC) 2>&1" "tee -a $(SAGE_LOGS)/$(PYNAC).log"
253
254$(INST)/$(SYMPOW): $(BASE) $(INST)/$(PATCH)
255        $(INSTALL) "$(SAGE_SPKG) $(SYMPOW) 2>&1" "tee -a $(SAGE_LOGS)/$(SYMPOW).log"
256
257$(INST)/$(SYMMETRICA): $(BASE) $(INST)/$(PATCH)
258        $(INSTALL) "$(SAGE_SPKG) $(SYMMETRICA) 2>&1" "tee -a $(SAGE_LOGS)/$(SYMMETRICA).log"
259
260# GAP requires Sage so that gap_reset_workspace works:
261$(INST)/$(GAP): $(BASE) $(INST)/$(TERMCAP) $(INST)/$(READLINE) $(INST)/$(SAGE) $(INST)/$(PATCH)
262        $(INSTALL) "$(SAGE_SPKG) $(GAP) 2>&1" "tee -a $(SAGE_LOGS)/$(GAP).log"
263
264$(INST)/$(IPYTHON): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
265        $(INSTALL) "$(SAGE_SPKG) $(IPYTHON) 2>&1" "tee -a $(SAGE_LOGS)/$(IPYTHON).log"
266
267$(INST)/$(PEXPECT): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
268        $(INSTALL) "$(SAGE_SPKG) $(PEXPECT) 2>&1" "tee -a $(SAGE_LOGS)/$(PEXPECT).log"
269
270$(INST)/$(GD): $(BASE) $(INST)/$(LIBPNG) $(INST)/$(FREETYPE) $(INST)/$(ICONV) $(INST)/$(PATCH)
271        $(INSTALL) "$(SAGE_SPKG) $(GD) 2>&1" "tee -a $(SAGE_LOGS)/$(GD).log"
272
273$(INST)/$(GDMODULE): $(BASE) $(INST)/$(PYTHON) $(INST)/$(GD) $(INST)/$(ICONV) $(INST)/$(PATCH)
274        $(INSTALL) "$(SAGE_SPKG) $(GDMODULE) 2>&1" "tee -a $(SAGE_LOGS)/$(GDMODULE).log"
275
276$(INST)/$(OPENCDK): $(BASE) $(INST)/$(ZLIB) $(INST)/$(LIBGCRYPT) $(INST)/$(PATCH)
277        $(INSTALL) "$(SAGE_SPKG) $(OPENCDK) 2>&1" "tee -a $(SAGE_LOGS)/$(OPENCDK).log"
278
279$(INST)/$(LIBGPG_ERROR): $(BASE) $(INST)/$(ICONV)  $(INST)/$(PATCH)
280        $(INSTALL) "$(SAGE_SPKG) $(LIBGPG_ERROR) 2>&1" "tee -a $(SAGE_LOGS)/$(LIBGPG_ERROR).log"
281
282$(INST)/$(LIBGCRYPT): $(BASE) $(INST)/$(LIBGPG_ERROR) $(INST)/$(PATCH)
283        $(INSTALL) "$(SAGE_SPKG) $(LIBGCRYPT) 2>&1" "tee -a $(SAGE_LOGS)/$(LIBGCRYPT).log"
284
285$(INST)/$(GNUTLS): $(BASE) $(INST)/$(ZLIB) $(INST)/$(OPENCDK) \
286                   $(INST)/$(LIBGCRYPT) $(INST)/$(LIBGPG_ERROR)  $(INST)/$(PATCH)
287        $(INSTALL) "$(SAGE_SPKG) $(GNUTLS) 2>&1" "tee -a $(SAGE_LOGS)/$(GNUTLS).log"
288
289$(INST)/$(PYTHON_GNUTLS): $(BASE) $(INST)/$(GNUTLS) $(INST)/$(PYTHON) $(INST)/$(PATCH)
290        $(INSTALL) "$(SAGE_SPKG) $(PYTHON_GNUTLS) 2>&1" "tee -a $(SAGE_LOGS)/$(PYTHON_GNUTLS).log"
291
292$(INST)/$(SCONS): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
293        $(INSTALL) "$(SAGE_SPKG) $(SCONS) 2>&1" "tee -a $(SAGE_LOGS)/$(SCONS).log"
294
295$(INST)/$(RUBIKS): $(BASE) $(INST)/$(PATCH)
296        $(INSTALL) "$(SAGE_SPKG) $(RUBIKS) 2>&1" "tee -a $(SAGE_LOGS)/$(RUBIKS).log"
297
298# extcode must be built before MoinMoin because it has jsmath in it:
299$(INST)/$(MOIN): $(BASE) $(INST)/$(PYTHON) $(INST)/$(EXTCODE) \
300                 $(INST)/$(SAGENB) $(INST)/$(PATCH)
301        $(INSTALL) "$(SAGE_SPKG) $(MOIN) 2>&1" "tee -a $(SAGE_LOGS)/$(MOIN).log"
302
303$(INST)/$(SQLITE): $(BASE) $(INST)/$(TERMCAP) $(INST)/$(READLINE) $(INST)/$(PATCH)
304        $(INSTALL) "$(SAGE_SPKG) $(SQLITE) 2>&1" "tee -a $(SAGE_LOGS)/$(SQLITE).log"
305
306$(INST)/$(MERCURIAL): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
307        $(INSTALL) "$(SAGE_SPKG) $(MERCURIAL) 2>&1" "tee -a $(SAGE_LOGS)/$(MERCURIAL).log"
308
309# Make Sage and GAP prerequisites for sagetex so that as much of Sage
310# is installed as possible: this is so that spkg-check works for
311# sagetex.  (To build sagetex, you just need Python, but to test it,
312# you need a full Sage installation.)
313$(INST)/$(SAGETEX): $(BASE) $(INST)/$(SAGE_SCRIPTS) \
314                    $(INST)/$(PYTHON) $(INST)/$(SAGE) $(INST)/$(GAP) $(INST)/$(PATCH)
315        $(INSTALL) "$(SAGE_SPKG) $(SAGETEX) 2>&1" "tee -a $(SAGE_LOGS)/$(SAGETEX).log"
316
317$(INST)/$(SETUPTOOLS): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
318        $(INSTALL) "$(SAGE_SPKG) $(SETUPTOOLS) 2>&1" "tee -a $(SAGE_LOGS)/$(SETUPTOOLS).log"
319
320$(INST)/$(SINGULAR): $(BASE) $(INST)/$(MPIR) $(INST)/$(NTL) \
321                     $(INST)/$(TERMCAP) $(INST)/$(READLINE) $(INST)/$(MPFR)  $(INST)/$(PATCH)
322        $(INSTALL) "$(SAGE_SPKG) $(SINGULAR) 2>&1" "tee -a $(SAGE_LOGS)/$(SINGULAR).log"
323
324$(INST)/$(PYCRYPTO): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
325        $(INSTALL) "$(SAGE_SPKG) $(PYCRYPTO) 2>&1" "tee -a $(SAGE_LOGS)/$(PYCRYPTO).log"
326
327$(INST)/$(WEAVE): $(BASE) $(INST)/$(NUMPY) $(INST)/$(PATCH)
328        $(INSTALL) "$(SAGE_SPKG) $(WEAVE) 2>&1" "tee -a $(SAGE_LOGS)/$(WEAVE).log"
329
330$(INST)/$(NETWORKX): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
331        $(INSTALL) "$(SAGE_SPKG) $(NETWORKX) 2>&1" "tee -a $(SAGE_LOGS)/$(NETWORKX).log"
332
333$(INST)/$(MPMATH): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
334        $(INSTALL) "$(SAGE_SPKG) $(MPMATH) 2>&1" "tee -a $(SAGE_LOGS)/$(MPMATH).log"
335
336$(INST)/$(ZLIB): $(BASE) $(INST)/$(PATCH)
337        $(INSTALL) "$(SAGE_SPKG) $(ZLIB) 2>&1" "tee -a $(SAGE_LOGS)/$(ZLIB).log"
338
339##  << NON-GUI matplotlib >>
340$(INST)/$(FREETYPE): $(BASE) $(INST)/$(PATCH)
341        $(INSTALL) "$(SAGE_SPKG) $(FREETYPE) 2>&1" "tee -a $(SAGE_LOGS)/$(FREETYPE).log"
342
343$(INST)/$(LIBPNG): $(BASE) $(INST)/$(ZLIB) $(INST)/$(PATCH)
344        $(INSTALL) "$(SAGE_SPKG) $(LIBPNG) 2>&1" "tee -a $(SAGE_LOGS)/$(LIBPNG).log"
345
346$(INST)/$(MATPLOTLIB): $(BASE) $(INST)/$(PYTHON) $(INST)/$(NUMPY) \
347                       $(INST)/$(FREETYPE) $(INST)/$(LIBPNG) \
348                       $(INST)/$(GDMODULE) $(INST)/$(PATCH)
349        $(INSTALL) "$(SAGE_SPKG) $(MATPLOTLIB) 2>&1" "tee -a $(SAGE_LOGS)/$(MATPLOTLIB).log"
350####
351
352$(INST)/$(CDDLIB): $(BASE) $(INST)/$(MPIR) $(INST)/$(PATCH)
353        $(INSTALL) "$(SAGE_SPKG) $(CDDLIB) 2>&1" "tee -a $(SAGE_LOGS)/$(CDDLIB).log"
354
355$(INST)/$(GFAN): $(BASE) $(INST)/$(MPIR) $(INST)/$(CDDLIB) $(INST)/$(PATCH)
356        $(INSTALL) "$(SAGE_SPKG) $(GFAN) 2>&1" "tee -a $(SAGE_LOGS)/$(GFAN).log"
357
358$(INST)/$(TACHYON): $(BASE) $(INST)/$(LIBPNG) $(INST)/$(PATCH)
359        $(INSTALL) "$(SAGE_SPKG) $(TACHYON) 2>&1" "tee -a $(SAGE_LOGS)/$(TACHYON).log"
360
361$(INST)/$(ECM): $(BASE) $(INST)/$(MPIR) $(INST)/$(PATCH)
362        $(INSTALL) "$(SAGE_SPKG) $(ECM) 2>&1" "tee -a $(SAGE_LOGS)/$(ECM).log"
363
364$(INST)/$(RATPOINTS): $(BASE) $(INST)/$(MPIR) $(INST)/$(PATCH)
365        $(INSTALL) "$(SAGE_SPKG) $(RATPOINTS) 2>&1" "tee -a $(SAGE_LOGS)/$(RATPOINTS).log"
366
367$(INST)/$(ECL): $(BASE) $(INST)/$(MPIR) $(INST)/$(TERMCAP) \
368                $(INST)/$(READLINE) $(INST)/$(BOEHM_GC) $(INST)/$(PATCH)
369        $(INSTALL) "$(SAGE_SPKG) $(ECL) 2>&1" "tee -a $(SAGE_LOGS)/$(ECL).log"
370
371$(INST)/$(MAXIMA): $(BASE) $(INST)/$(ECL) $(INST)/$(PATCH)
372        $(INSTALL) "$(SAGE_SPKG) $(MAXIMA) 2>&1" "tee -a $(SAGE_LOGS)/$(MAXIMA).log"
373
374# Note that even with a separate RPy spkg (#9906), Sage's R will still depend on
375# Python (but does no longer on SAGE_SCRIPTS, #10016):
376$(INST)/$(R): $(BASE) $(INST)/$(PYTHON) $(INST)/$(ATLAS) $(INST)/$(ICONV) $(INST)/$(FORTRAN) $(INST)/$(PATCH)
377        $(INSTALL) "$(SAGE_SPKG) $(R) 2>&1" "tee -a $(SAGE_LOGS)/$(R).log"
378
379# Needed when #9906 gets merged (moving RPy out of R's spkg):
380# $(INST)/$(RPY): $(BASE) $(INST)/$(PYTHON) $(INST)/$(R) $(INST)/$(PATCH)
381#       $(INSTALL) "$(SAGE_SPKG) $(RPY) 2>&1" "tee -a $(SAGE_LOGS)/$(RPY).log"
382
383$(INST)/$(SYMPY): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
384        $(INSTALL) "$(SAGE_SPKG) $(SYMPY) 2>&1" "tee -a $(SAGE_LOGS)/$(SYMPY).log"
385
386$(INST)/$(CYTHON): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
387        $(INSTALL) "$(SAGE_SPKG) $(CYTHON) 2>&1" "tee -a $(SAGE_LOGS)/$(CYTHON).log"
388
389$(INST)/$(FLINTQS): $(BASE) $(INST)/$(MPIR) $(INST)/$(PATCH)
390        $(INSTALL) "$(SAGE_SPKG) $(FLINTQS) 2>&1" "tee -a $(SAGE_LOGS)/$(FLINTQS).log"
391
392$(INST)/$(FLINT): $(BASE) $(INST)/$(MPIR) $(INST)/$(NTL) $(INST)/$(PATCH)
393        $(INSTALL) "$(SAGE_SPKG) $(FLINT) 2>&1" "tee -a $(SAGE_LOGS)/$(FLINT).log"
394
395# Mercurial must be built before building extcode. See trac ticket #6508.
396$(INST)/$(EXTCODE): $(BASE) $(INST)/$(MERCURIAL) $(INST)/$(PATCH)
397        $(INSTALL) "$(SAGE_SPKG) $(EXTCODE) 2>&1" "tee -a $(SAGE_LOGS)/$(EXTCODE).log"
398
399$(INST)/$(EXAMPLES): $(BASE) $(INST)/$(PATCH)
400        $(INSTALL) "$(SAGE_SPKG) $(EXAMPLES) 2>&1" "tee -a $(SAGE_LOGS)/$(EXAMPLES).log"
401
402$(INST)/$(LIBM4RI): $(BASE) $(INST)/$(PATCH)
403        $(INSTALL) "$(SAGE_SPKG) $(LIBM4RI) 2>&1" "tee -a $(SAGE_LOGS)/$(LIBM4RI).log"
404
405# zn_poly really does depend on Python, despite this is far from obvious.
406# The 'configure' script in zn_poly calls Python to make a 'makefile'.
407$(INST)/$(ZNPOLY): $(BASE) $(INST)/$(MPIR) $(INST)/$(PYTHON) $(INST)/$(PATCH)
408        $(INSTALL) "$(SAGE_SPKG) $(ZNPOLY) 2>&1" "tee -a $(SAGE_LOGS)/$(ZNPOLY).log"
409
410# the spkg-install file for the root repo uses many 'hg' commands, so
411# build mercurial first.
412$(INST)/$(SAGE_ROOT_REPO): $(BASE) $(INST)/$(MERCURIAL) $(INST)/$(PATCH)
413        $(INSTALL) "$(SAGE_SPKG) $(SAGE_ROOT_REPO) 2>&1" "tee -a $(SAGE_LOGS)/$(SAGE_ROOT_REPO).log"
414
415 # setuptools forgets to update easy-install.pth during parallel# setuptools forgets to update easy-install.pth during parallel
416# builds, so we build the relevant packages serially.  Note: To avoid
417# branching, we haven't given explicit dependencies, but the chain's
418# order is important.
419$(INST)/$(SAGENB): $(BASE) $(INST)/$(SQLALCHEMY) $(INST)/$(PATCH)
420        $(INSTALL) "$(SAGE_SPKG) $(SAGENB) 2>&1" "tee -a $(SAGE_LOGS)/$(SAGENB).log"
421
422$(INST)/$(SQLALCHEMY): $(BASE) $(INST)/$(SPHINX) $(INST)/$(PATCH)
423        $(INSTALL) "$(SAGE_SPKG) $(SQLALCHEMY) 2>&1" "tee -a $(SAGE_LOGS)/$(SQLALCHEMY).log"
424
425$(INST)/$(SPHINX): $(BASE) $(INST)/$(JINJA2) $(INST)/$(PATCH)
426        $(INSTALL) "$(SAGE_SPKG) $(SPHINX) 2>&1" "tee -a $(SAGE_LOGS)/$(SPHINX).log"
427
428$(INST)/$(JINJA2): $(BASE) $(INST)/$(PYGMENTS) $(INST)/$(PATCH)
429        $(INSTALL) "$(SAGE_SPKG) $(JINJA2) 2>&1" "tee -a $(SAGE_LOGS)/$(JINJA2).log"
430
431$(INST)/$(PYGMENTS): $(BASE) $(INST)/$(ZODB) $(INST)/$(PATCH)
432        $(INSTALL) "$(SAGE_SPKG) $(PYGMENTS) 2>&1" "tee -a $(SAGE_LOGS)/$(PYGMENTS).log"
433
434$(INST)/$(ZODB): $(BASE) $(INST)/$(TWISTED) $(INST)/$(PATCH)
435        $(INSTALL) "$(SAGE_SPKG) $(ZODB) 2>&1" "tee -a $(SAGE_LOGS)/$(ZODB).log"
436
437$(INST)/$(TWISTED): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PYTHON_GNUTLS) \
438                    $(INST)/$(PEXPECT) $(INST)/$(DOCUTILS) \
439                    $(INST)/$(SETUPTOOLS) $(INST)/$(PATCH)
440        $(INSTALL) "$(SAGE_SPKG) $(TWISTED) 2>&1" "tee -a $(SAGE_LOGS)/$(TWISTED).log"
441
442# For reference and for when the setuptools problem is solved, here
443# are the actual dependencies:
444#
445# sagenb: python pexpect twisted jinja2 sphinx docutils setuptools
446# sqlalchemy: python setuptools
447# sphinx: docutils jinja2 pygments
448# jinja2: python docutils setuptools
449# pygments: python setuptools
450# twisted: python python_gnutls setuptools
451# zodb: python setuptools
452
453###############################################################################
454# All components that are linked against extensions need to be listed here:
455###############################################################################
456$(INST)/$(SAGE): $(BASE) \
457                 $(INST)/$(SAGE_SCRIPTS) \
458                 $(INST)/$(ATLAS) \
459                 $(INST)/$(CEPHES) \
460                 $(INST)/$(CLIQUER) \
461                 $(INST)/$(CONWAY) \
462                 $(INST)/$(CYTHON) \
463                 $(INST)/$(DOCUTILS) \
464                 $(INST)/$(ECL) \
465                 $(INST)/$(ECLIB) \
466                 $(INST)/$(ECM) \
467                 $(INST)/$(ELLIPTIC_CURVES) \
468                 $(INST)/$(EXTCODE) \
469                 $(INST)/$(FLINT) \
470                 $(INST)/$(FPLLL) \
471                 $(INST)/$(GDMODULE) \
472                 $(INST)/$(GRAPHS) \
473                 $(INST)/$(GIVARO) \
474                 $(INST)/$(GLPK) \
475                 $(INST)/$(GSL) \
476                 $(INST)/$(IML) \
477                 $(INST)/$(IPYTHON) \
478                 $(INST)/$(LCALC) \
479                 $(INST)/$(LIBM4RI) \
480                 $(INST)/$(LINBOX) \
481                 $(INST)/$(MATPLOTLIB) \
482                 $(INST)/$(MERCURIAL) \
483                 $(INST)/$(MPFI) \
484                 $(INST)/$(MPFR) \
485                 $(INST)/$(MPIR) \
486                 $(INST)/$(MPMATH) \
487                 $(INST)/$(NETWORKX) \
488                 $(INST)/$(NTL) \
489                 $(INST)/$(NUMPY) \
490                 $(INST)/$(PARI) \
491                 $(INST)/$(PEXPECT) \
492                 $(INST)/$(POLYBORI) \
493                 $(INST)/$(PYCRYPTO) \
494                 $(INST)/$(PYNAC) \
495                 $(INST)/$(PYTHON) \
496                 $(INST)/$(R) \
497                 $(INST)/$(RATPOINTS) \
498                 $(INST)/$(RUBIKS) \
499                 $(INST)/$(SAGENB) \
500                 $(INST)/$(SCONS) \
501                 $(INST)/$(SETUPTOOLS) \
502                 $(INST)/$(SINGULAR) \
503                 $(INST)/$(SYMMETRICA) \
504                 $(INST)/$(SYMPY) \
505                 $(INST)/$(ZNPOLY)
506        $(INSTALL) "$(SAGE_SPKG) $(SAGE) 2>&1" "tee -a $(SAGE_LOGS)/$(SAGE).log"
507# Needed when #9906 gets merged:
508#                $(INST)/$(RPY) \
509# (But move this up; it's just here because 'make' doesn't support comments
510# within line continuations.)
511
512###############################################################################
513# Further receipts for normal packages:
514###############################################################################
515
516# Do not remove PYTHON below -- see trac 9368
517$(INST)/$(FORTRAN): $(BASE)  $(INST)/$(PYTHON) $(INST)/$(PATCH)
518        $(INSTALL) "$(SAGE_SPKG) $(FORTRAN) 2>&1" "tee -a $(SAGE_LOGS)/$(FORTRAN).log"
519
520$(INST)/$(F2C): $(BASE) $(INST)/$(FORTRAN) $(INST)/$(PATCH)
521        $(INSTALL) "$(SAGE_SPKG) $(F2C) 2>&1" "tee -a $(SAGE_LOGS)/$(F2C).log"
522
523$(INST)/$(PIL): $(BASE) $(INST)/$(PYTHON) $(INST)/$(PATCH)
524        $(INSTALL) "$(SAGE_SPKG) $(PIL) 2>&1" "tee -a $(SAGE_LOGS)/$(PIL).log"
525
526$(INST)/$(LAPACK): $(BASE) $(INST)/$(FORTRAN) $(INST)/$(PATCH)
527        $(INSTALL) "$(SAGE_SPKG) $(LAPACK) 2>&1" "tee -a $(SAGE_LOGS)/$(LAPACK).log"
528
529$(INST)/$(BLAS): $(BASE) $(INST)/$(FORTRAN) $(INST)/$(PATCH)
530        $(INSTALL) "$(SAGE_SPKG) $(BLAS) 2>&1" "tee -a $(SAGE_LOGS)/$(BLAS).log"
531
532$(INST)/$(NUMPY): $(BASE) $(INST)/$(PYTHON) $(INST)/$(FORTRAN) $(INST)/$(F2C) \
533                  $(INST)/$(LAPACK) $(INST)/$(BLAS) $(INST)/$(ATLAS) $(INST)/$(PATCH)
534        $(INSTALL) "$(SAGE_SPKG) $(NUMPY) 2>&1" "tee -a $(SAGE_LOGS)/$(NUMPY).log"
535
536$(INST)/$(SCIPY): $(BASE) $(INST)/$(FORTRAN) $(INST)/$(F2C) \
537                  $(INST)/$(LAPACK) $(INST)/$(BLAS) $(INST)/$(NUMPY) $(INST)/$(PATCH)
538        $(INSTALL) "$(SAGE_SPKG) $(SCIPY) 2>&1" "tee -a $(SAGE_LOGS)/$(SCIPY).log"
539
540$(INST)/$(SCIPY_SANDBOX): $(BASE) $(INST)/$(SCIPY) $(INST)/$(PATCH)
541        $(INSTALL) "$(SAGE_SPKG) $(SCIPY_SANDBOX) 2>&1" "tee -a $(SAGE_LOGS)/$(SCIPY_SANDBOX).log"
542
543$(INST)/$(CVXOPT): $(BASE) $(INST)/$(FORTRAN) $(INST)/$(F2C) \
544                   $(INST)/$(LAPACK) $(INST)/$(BLAS) $(INST)/$(NUMPY) \
545                   $(INST)/$(ATLAS) $(INST)/$(CEPHES) $(INST)/$(PATCH) \
546                   $(INST)/$(GSL) $(INST)/$(GLPK)
547        $(INSTALL) "$(SAGE_SPKG) $(CVXOPT) 2>&1" "tee -a $(SAGE_LOGS)/$(CVXOPT).log"
548
549$(INST)/$(CEPHES): $(BASE) $(INST)/$(PATCH)
550        $(INSTALL) "$(SAGE_SPKG) $(CEPHES) 2>&1" "tee -a $(SAGE_LOGS)/$(CEPHES).log"
551
552###############################################################################