aboutsummaryrefslogtreecommitdiff
path: root/tools/star/Makefile
blob: 88bc4f0c81ec54b8c9eca2602d20374b1afd1953 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
RAKUDO_VER  = 2012.08
NQP_VER     = 2012.08
PARROT_VER  = 4.6.0
PARROT_REL  = supported/$(PARROT_VER)

SRC_DIR = src

RAKUDO_TGZ = rakudo-$(RAKUDO_VER).tar.gz
RAKUDO_URL = https://github.com/downloads/rakudo/rakudo/$(RAKUDO_TGZ)
RAKUDO_SRC = $(SRC_DIR)/$(RAKUDO_TGZ)
NQP_TGZ    = nqp-$(NQP_VER).tar.gz
NQP_URL    = https://github.com/downloads/perl6/nqp/$(NQP_TGZ)
NQP_SRC    = $(SRC_DIR)/$(NQP_TGZ)
PARROT_TGZ = parrot-$(PARROT_VER).tar.gz
PARROT_URL = http://ftp.parrot.org/releases/$(PARROT_REL)/$(PARROT_TGZ)
PARROT_SRC = $(SRC_DIR)/$(PARROT_TGZ)

PERL   = perl
PREFIX = $(PERL) $(CURDIR)/tools/star/prefix.pl
WGET   = wget --no-check-certificate

all: rakudo nqp parrot MANIFEST

always:

rakudo: nqp $(RAKUDO_SRC)
	tar --xform 's!rakudo-[^/]*!rakudo!' -xvzf $(RAKUDO_SRC)

$(RAKUDO_SRC):
	mkdir -p $(SRC_DIR)
	$(WGET) $(RAKUDO_URL) -O $(RAKUDO_SRC)

nqp: parrot $(NQP_SRC)
	tar --xform 's!nqp-[^/]*!nqp!' -xvzf $(NQP_SRC)

$(NQP_SRC):
	mkdir -p $(SRC_DIR)
	$(WGET) $(NQP_URL) -O $(NQP_SRC)

parrot: $(PARROT_SRC)
	tar --xform 's!parrot-[^/]*!parrot!' -xvzf $(PARROT_SRC)

$(PARROT_SRC):
	mkdir -p $(SRC_DIR)
	$(WGET) $(PARROT_URL) -O $(PARROT_SRC)

MANIFEST: always rakudo/MANIFEST parrot/MANIFEST nqp/MANIFEST
	echo MANIFEST >MANIFEST
	git ls-files >>MANIFEST
	$(PREFIX) rakudo/ rakudo/MANIFEST >>MANIFEST
	$(PREFIX) nqp/ nqp/MANIFEST >>MANIFEST
	cut -d' ' -f1 parrot/MANIFEST | $(PREFIX) parrot/ >>MANIFEST
	git submodule foreach --quiet 'git ls-files | $(PREFIX) $$path/' >>MANIFEST
	sort -o MANIFEST MANIFEST