Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 84 lines (62 sloc) 1.657 kb
fbb061dc »
2009-11-27 Convert over to PIR-based Configure and build system
1 #! /usr/local/bin/parrot
2 # $Id$
3
4 =head1 NAME
5
6 setup.pir - Python distutils style
7
8 =head1 DESCRIPTION
9
10 No Configure step, no Makefile generated.
11
12 =head1 USAGE
13
14 $ parrot setup.pir build
15 $ parrot setup.pir test
16 $ sudo parrot setup.pir install
17
18 =cut
19
20 .sub 'main' :main
21 .param pmc args
22 $S0 = shift args
23 load_bytecode 'distutils.pbc'
24
25 $P0 = new 'Hash'
26 $P0['name'] = 'nqptap'
27 $P0['abstract'] = 'the nqptap compiler'
28 $P0['description'] = 'the nqptap for Parrot VM.'
29
30 # build
31 # $P1 = new 'Hash'
32 # $P1['nqptap_ops'] = 'src/ops/nqptap.ops'
33 # $P0['dynops'] = $P1
34
35 # $P2 = new 'Hash'
36 # $P3 = split ' ', 'src/pmc/nqptap.pmc'
37 # $P2['nqptap_group'] = $P3
38 # $P0['dynpmc'] = $P2
39
40 $P4 = new 'Hash'
41 $P5 = split ' ', 'src/parser/grammar.pg src/parser/grammar-oper.pg'
42 $P4['src/gen_grammar.pir'] = $P5
43 $P0['pir_pge'] = $P4
44
45 $P6 = new 'Hash'
46 $P6['src/gen_actions.pir'] = 'src/parser/actions.pm'
47 $P0['pir_nqp'] = $P6
48
49 $P7 = new 'Hash'
50 $P8 = split "\n", <<'SOURCES'
51 src/nqptap.pir
52 src/gen_grammar.pir
53 src/gen_actions.pir
54 src/builtins.pir
55 src/builtins/say.pir
56 SOURCES
57 $S0 = pop $P8
58 $P7['nqptap/nqptap.pbc'] = $P8
59 $P7['nqptap.pbc'] = 'nqptap.pir'
60 $P0['pbc_pir'] = $P7
61
62 $P9 = new 'Hash'
63 $P9['parrot-nqptap'] = 'nqptap.pbc'
64 $P0['installable_pbc'] = $P9
65
66 # test
67 $S0 = get_parrot()
68 $S0 .= ' nqptap.pbc'
69 $P0['prove_exec'] = $S0
70
71 # install
72 $P0['inst_lang'] = 'nqptap/nqptap.pbc'
73
74 .tailcall setup(args :flat, $P0 :flat :named)
75 .end
76
77
78 # Local Variables:
79 # mode: pir
80 # fill-column: 100
81 # End:
82 # vim: expandtab shiftwidth=4 ft=pir:
83
Something went wrong with that request. Please try again.