Commit | Line | Data |
12ae5dfc |
1 | LD = $(CC) |
2f42fcb0 |
2 | DEFINES = -DPERL_CORE -DPERL_MICRO -DSTANDARD_C -DPERL_USE_SAFE_PUTENV |
3 | OPTIMIZE = |
a24ffc0b |
4 | CFLAGS = $(DEFINES) $(OPTIMIZE) |
12ae5dfc |
5 | LIBS = -lm |
6 | _O = .o |
2f42fcb0 |
7 | ENV = env |
2eacba2f |
8 | PERL = perl |
12ae5dfc |
9 | |
10 | all: microperl |
11 | |
12 | O = uav$(_O) udeb$(_O) udoio$(_O) udoop$(_O) udump$(_O) \ |
e1a479c5 |
13 | uglobals$(_O) ugv$(_O) uhv$(_O) umro$(_O)\ |
530ffa68 |
14 | umg$(_O) uperlmain$(_O) uop$(_O) ureentr$(_O) \ |
15 | upad$(_O) uperl$(_O) uperlio$(_O) uperly$(_O) upp$(_O) \ |
84d4ea48 |
16 | upp_ctl$(_O) upp_hot$(_O) upp_sys$(_O) upp_pack$(_O) upp_sort$(_O) \ |
12ae5dfc |
17 | uregcomp$(_O) uregexec$(_O) urun$(_O) \ |
18 | uscope$(_O) usv$(_O) utaint$(_O) utoke$(_O) \ |
7ee2227d |
19 | unumeric$(_O) ulocale$(_O) umathoms$(_O) \ |
2f42fcb0 |
20 | uuniversal$(_O) uutf8$(_O) uutil$(_O) uperlapi$(_O) uxsutils$(_O) |
12ae5dfc |
21 | |
22 | microperl: $(O) |
23 | $(LD) -o $@ $(O) $(LIBS) |
24 | |
25 | H = av.h uconfig.h cop.h cv.h embed.h embedvar.h form.h gv.h handy.h \ |
dd2155a4 |
26 | hv.h intrpvar.h iperlsys.h mg.h op.h opcode.h opnames.h pad.h \ |
27 | patchlevel.h perl.h perlsdio.h perlvars.h perly.h pp.h \ |
907b3e23 |
28 | pp_proto.h proto.h reentr.h regexp.h scope.h sv.h \ |
dd2155a4 |
29 | thread.h unixish.h utf8.h util.h warnings.h |
12ae5dfc |
30 | |
31 | HE = $(H) EXTERN.h |
32 | |
33 | clean: |
34 | -rm -f $(O) microperl |
35 | |
36 | distclean: clean |
12ae5dfc |
37 | |
44914417 |
38 | # The microconfiguration. |
39 | |
2eacba2f |
40 | # Cannot use $$ in the command line itself, so using var expansion instead. |
41 | Config = '$$Config{$$1}' |
42 | patch_uconfig: |
43 | $(PERL) -MConfig -pi -e "s/^((?:short|int|long(?:dbl|long)?|ptr|double|[iun]v|u?quad|[iu]\d+|fpos|lseek)(?:size|type)|byteorder|d_quad|quadkind|use64.+)=.*/\\1='"$(Config)"'/g" uconfig.shx |
44 | |
535ceeb0 |
45 | regen_uconfig uconfig.h: uconfig.sh |
2f42fcb0 |
46 | $(ENV) CONFIG_SH=uconfig.sh CONFIG_H=uconfig.h sh ./config_h.SH |
12ae5dfc |
47 | |
44914417 |
48 | # Do not regenerate perly.c and perly.h. |
49 | |
50 | perly.c: perly.y |
54d0ee51 |
51 | -@echo perly.c is uptodate |
44914417 |
52 | |
53 | perly.h: perly.y |
54d0ee51 |
54 | -@echo perly.h is uptodate |
44914417 |
55 | |
56 | # The microperl objects. |
57 | |
12ae5dfc |
58 | uav$(_O): $(HE) av.c |
59 | $(CC) -c -o $@ $(CFLAGS) av.c |
60 | |
61 | udeb$(_O): $(HE) deb.c |
62 | $(CC) -c -o $@ $(CFLAGS) deb.c |
63 | |
64 | udoio$(_O): $(HE) doio.c |
65 | $(CC) -c -o $@ $(CFLAGS) doio.c |
66 | |
67 | udoop$(_O): $(HE) doop.c |
68 | $(CC) -c -o $@ $(CFLAGS) doop.c |
69 | |
70 | udump$(_O): $(HE) dump.c regcomp.h regnodes.h |
71 | $(CC) -c -o $@ $(CFLAGS) dump.c |
72 | |
73 | uglobals$(_O): $(H) globals.c INTERN.h perlapi.h |
74 | $(CC) -c -o $@ $(CFLAGS) globals.c |
75 | |
76 | ugv$(_O): $(HE) gv.c |
77 | $(CC) -c -o $@ $(CFLAGS) gv.c |
78 | |
e1a479c5 |
79 | umro$(_O): $(HE) mro.c |
80 | $(CC) -c -o $@ $(CFLAGS) mro.c |
81 | |
12ae5dfc |
82 | uhv$(_O): $(HE) hv.c |
83 | $(CC) -c -o $@ $(CFLAGS) hv.c |
84 | |
85 | umg$(_O): $(HE) mg.c |
86 | $(CC) -c -o $@ $(CFLAGS) mg.c |
87 | |
88 | uperlmain$(_O): $(HE) miniperlmain.c |
89 | $(CC) -c -o $@ $(CFLAGS) miniperlmain.c |
90 | |
91 | uop$(_O): $(HE) op.c keywords.h |
2f42fcb0 |
92 | $(CC) -c -o $@ $(CFLAGS) -DPERL_EXTERNAL_GLOB op.c |
12ae5dfc |
93 | |
077a72a9 |
94 | ureentr$(_O): $(HE) reentr.c |
95 | $(CC) -c -o $@ $(CFLAGS) reentr.c |
96 | |
530ffa68 |
97 | upad$(_O): $(HE) pad.c |
98 | $(CC) -c -o $@ $(CFLAGS) pad.c |
99 | |
12ae5dfc |
100 | uperl$(_O): $(HE) perl.c |
101 | $(CC) -c -o $@ $(CFLAGS) perl.c |
102 | |
103 | uperlio$(_O): $(HE) perlio.c |
104 | $(CC) -c -o $@ $(CFLAGS) perlio.c |
105 | |
106 | uperly$(_O): $(HE) perly.c |
107 | $(CC) -c -o $@ $(CFLAGS) perly.c |
108 | |
109 | upp$(_O): $(HE) pp.c |
110 | $(CC) -c -o $@ $(CFLAGS) pp.c |
111 | |
112 | upp_ctl$(_O): $(HE) pp_ctl.c |
113 | $(CC) -c -o $@ $(CFLAGS) pp_ctl.c |
114 | |
115 | upp_hot$(_O): $(HE) pp_hot.c |
116 | $(CC) -c -o $@ $(CFLAGS) pp_hot.c |
117 | |
118 | upp_sys$(_O): $(HE) pp_sys.c |
119 | $(CC) -c -o $@ $(CFLAGS) pp_sys.c |
120 | |
a6ec74c1 |
121 | upp_pack$(_O): $(HE) pp_pack.c |
122 | $(CC) -c -o $@ $(CFLAGS) pp_pack.c |
123 | |
84d4ea48 |
124 | upp_sort$(_O): $(HE) pp_sort.c |
125 | $(CC) -c -o $@ $(CFLAGS) pp_sort.c |
126 | |
12ae5dfc |
127 | uregcomp$(_O): $(HE) regcomp.c regcomp.h regnodes.h INTERN.h |
128 | $(CC) -c -o $@ $(CFLAGS) regcomp.c |
129 | |
130 | uregexec$(_O): $(HE) regexec.c regcomp.h regnodes.h |
131 | $(CC) -c -o $@ $(CFLAGS) regexec.c |
132 | |
133 | urun$(_O): $(HE) run.c |
134 | $(CC) -c -o $@ $(CFLAGS) run.c |
135 | |
136 | uscope$(_O): $(HE) scope.c |
137 | $(CC) -c -o $@ $(CFLAGS) scope.c |
138 | |
139 | usv$(_O): $(HE) sv.c |
140 | $(CC) -c -o $@ $(CFLAGS) sv.c |
141 | |
142 | utaint$(_O): $(HE) taint.c |
143 | $(CC) -c -o $@ $(CFLAGS) taint.c |
144 | |
145 | utoke$(_O): $(HE) toke.c keywords.h |
146 | $(CC) -c -o $@ $(CFLAGS) toke.c |
147 | |
53a62437 |
148 | ulocale$(_O): $(HE) locale.c |
149 | $(CC) -c -o $@ $(CFLAGS) locale.c |
150 | |
151 | unumeric$(_O): $(HE) numeric.c |
152 | $(CC) -c -o $@ $(CFLAGS) numeric.c |
153 | |
7ee2227d |
154 | umathoms$(_O): $(HE) mathoms.c |
155 | $(CC) -c -o $@ $(CFLAGS) mathoms.c |
156 | |
acfe0abc |
157 | uuniversal$(_O): $(HE) universal.c XSUB.h |
12ae5dfc |
158 | $(CC) -c -o $@ $(CFLAGS) universal.c |
159 | |
160 | uutf8$(_O): $(HE) utf8.c |
161 | $(CC) -c -o $@ $(CFLAGS) utf8.c |
162 | |
163 | uutil$(_O): $(HE) util.c |
164 | $(CC) -c -o $@ $(CFLAGS) util.c |
165 | |
166 | uperlapi$(_O): $(HE) perlapi.c perlapi.h |
167 | $(CC) -c -o $@ $(CFLAGS) perlapi.c |
168 | |
2f42fcb0 |
169 | uxsutils$(_O): $(HE) xsutils.c |
170 | $(CC) -c -o $@ $(CFLAGS) xsutils.c |
a1055377 |
171 | |
2f42fcb0 |
172 | # That's it, folks! |