]> git.lizzy.rs Git - rust.git/blob - mk/snap.mk
Merge pull request #4336 from thestinger/python
[rust.git] / mk / snap.mk
1 # Copyright 2012 The Rust Project Developers. See the COPYRIGHT
2 # file at the top-level directory of this distribution and at
3 # http://rust-lang.org/COPYRIGHT.
4 #
5 # Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6 # http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7 # <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8 # option. This file may not be copied, modified, or distributed
9 # except according to those terms.
10
11 define DEF_SNAP_FOR_STAGE_H
12 # $(1) stage
13 # $(2) triple
14
15 ifdef CFG_INSTALL_SNAP
16 snap-stage$(1)-H-$(2): $$(HSREQ$(1)_H_$(2))
17         $(CFG_PYTHON) $(S)src/etc/make-snapshot.py stage$(1) $(2) install
18 else
19 snap-stage$(1)-H-$(2): $$(HSREQ$(1)_H_$(2))
20         $(CFG_PYTHON) $(S)src/etc/make-snapshot.py stage$(1) $(2)
21 endif
22
23 endef
24
25 $(foreach host,$(CFG_TARGET_TRIPLES),                                           \
26  $(eval $(foreach stage,1 2 3,                                                          \
27   $(eval $(call DEF_SNAP_FOR_STAGE_H,$(stage),$(host))))))
28
29 snap-stage1: snap-stage1-H-$(CFG_HOST_TRIPLE)
30
31 snap-stage2: snap-stage2-H-$(CFG_HOST_TRIPLE)
32
33 snap-stage3: snap-stage3-H-$(CFG_HOST_TRIPLE)