@@ -88,12 +88,11 @@ build: 2
88
88
# These files are regenerated as soon as *any* ml file reachable from
89
89
# stage*/dune changes. This makes sure we trigger dune rebuilds when we
90
90
# modify base ML files. However this will not catch deletion of a file.
91
- .stage1.ml.touch : $(shell find -L stage1/dune/ -name '* .ml' -type f)
92
- touch $@
93
- .stage2.ml.touch : $(shell find -L stage2/dune/ -name '* .ml' -type f)
94
- touch $@
91
+ .src.ml.touch : .force
92
+ [ -e $@ ] || touch $@
93
+ find -L src/ml -newer $@ -exec touch $@ \; -quit
95
94
96
- $(FSTAR1_BARE_EXE ) : .bare1.src.touch .stage1 .ml.touch $(MAYBEFORCE )
95
+ $(FSTAR1_BARE_EXE ) : .bare1.src.touch .src .ml.touch $(MAYBEFORCE )
97
96
$(call bold_msg, "BUILD", "STAGE 1 FSTARC-BARE")
98
97
$(MAKE ) -C stage1 fstarc-bare
99
98
touch -c $@
@@ -111,7 +110,7 @@ $(FSTAR1_BARE_EXE): .bare1.src.touch .stage1.ml.touch $(MAYBEFORCE)
111
110
TOUCH=$@ \
112
111
$(MAKE ) -f mk/plugins.mk ocaml
113
112
114
- $(FSTAR1_FULL_EXE ) : .bare1.src.touch .full1.src.touch .stage1 .ml.touch $(MAYBEFORCE )
113
+ $(FSTAR1_FULL_EXE ) : .bare1.src.touch .full1.src.touch .src .ml.touch $(MAYBEFORCE )
115
114
$(call bold_msg, "BUILD", "STAGE 1 FSTARC")
116
115
$(MAKE ) -C stage1 fstarc-full
117
116
touch -c $@
@@ -129,7 +128,7 @@ $(FSTAR1_FULL_EXE): .bare1.src.touch .full1.src.touch .stage1.ml.touch $(MAYBEFO
129
128
$(MAKE ) -f mk/lib.mk ocaml verify
130
129
# ^ NB: also verify files we don't extract
131
130
132
- .alib1.touch : .alib1.src.touch .stage1 .ml.touch $(MAYBEFORCE )
131
+ .alib1.touch : .alib1.src.touch .src .ml.touch $(MAYBEFORCE )
133
132
$(call bold_msg, "BUILD", "STAGE 1 LIB")
134
133
$(MAKE ) -C stage1/ libapp
135
134
touch $@
@@ -149,7 +148,7 @@ $(FSTAR1_FULL_EXE): .bare1.src.touch .full1.src.touch .stage1.ml.touch $(MAYBEFO
149
148
TOUCH=$@ \
150
149
$(MAKE ) -f mk/lib.mk ocaml
151
150
152
- .plib1.touch : .plib1.src.touch .stage1 .ml.touch $(MAYBEFORCE )
151
+ .plib1.touch : .plib1.src.touch .src .ml.touch $(MAYBEFORCE )
153
152
$(call bold_msg, "BUILD", "STAGE 1 PLUGLIB")
154
153
$(MAKE ) -C stage1/ libplugin
155
154
touch $@
@@ -168,7 +167,7 @@ $(FSTAR1_FULL_EXE): .bare1.src.touch .full1.src.touch .stage1.ml.touch $(MAYBEFO
168
167
TOUCH=$@ \
169
168
$(MAKE ) -f mk/fstar-12.mk ocaml
170
169
171
- $(FSTAR2_BARE_EXE ) : .bare2.src.touch .stage2 .ml.touch $(MAYBEFORCE )
170
+ $(FSTAR2_BARE_EXE ) : .bare2.src.touch .src .ml.touch $(MAYBEFORCE )
172
171
$(call bold_msg, "BUILD", "STAGE 2 FSTARC-BARE")
173
172
$(MAKE ) -C stage2 fstarc-bare FSTAR_DUNE_RELEASE=1
174
173
touch -c $@
@@ -189,7 +188,7 @@ $(FSTAR2_BARE_EXE): .bare2.src.touch .stage2.ml.touch $(MAYBEFORCE)
189
188
TOUCH=$@ \
190
189
$(MAKE ) -f mk/plugins.mk ocaml
191
190
192
- $(FSTAR2_FULL_EXE ) : .bare2.src.touch .full2.src.touch .stage2 .ml.touch $(MAYBEFORCE )
191
+ $(FSTAR2_FULL_EXE ) : .bare2.src.touch .full2.src.touch .src .ml.touch $(MAYBEFORCE )
193
192
$(call bold_msg, "BUILD", "STAGE 2 FSTARC")
194
193
$(MAKE ) -C stage2 fstarc-full FSTAR_DUNE_RELEASE=1
195
194
touch -c $@
@@ -207,7 +206,7 @@ $(FSTAR2_FULL_EXE): .bare2.src.touch .full2.src.touch .stage2.ml.touch $(MAYBEFO
207
206
$(MAKE ) -f mk/lib.mk ocaml verify
208
207
# ^ NB: also verify files we don't extract
209
208
210
- .alib2.touch : .alib2.src.touch .stage2 .ml.touch $(MAYBEFORCE )
209
+ .alib2.touch : .alib2.src.touch .src .ml.touch $(MAYBEFORCE )
211
210
$(call bold_msg, "BUILD", "STAGE 2 LIB")
212
211
$(MAKE ) -C stage2/ libapp FSTAR_DUNE_RELEASE=1
213
212
touch $@
@@ -227,7 +226,7 @@ $(FSTAR2_FULL_EXE): .bare2.src.touch .full2.src.touch .stage2.ml.touch $(MAYBEFO
227
226
TOUCH=$@ \
228
227
$(MAKE ) -f mk/lib.mk ocaml
229
228
230
- .plib2.touch : .plib2.src.touch .stage2 .ml.touch $(MAYBEFORCE )
229
+ .plib2.touch : .plib2.src.touch .src .ml.touch $(MAYBEFORCE )
231
230
$(call bold_msg, "BUILD", "STAGE 2 PLUGLIB")
232
231
$(MAKE ) -C stage2/ libplugin FSTAR_DUNE_RELEASE=1
233
232
touch $@
@@ -282,10 +281,10 @@ else
282
281
LINK_OK =0
283
282
endif
284
283
285
- .stage1.src.touch : .bare1.src.touch .full1.src.touch .alib1.src.touch .plib1.src.touch .stage1 .ml.touch
284
+ .stage1.src.touch : .bare1.src.touch .full1.src.touch .alib1.src.touch .plib1.src.touch .src .ml.touch
286
285
touch $@
287
286
288
- .stage2.src.touch : .bare2.src.touch .full2.src.touch .alib2.src.touch .plib2.src.touch .stage2 .ml.touch
287
+ .stage2.src.touch : .bare2.src.touch .full2.src.touch .alib2.src.touch .plib2.src.touch .src .ml.touch
289
288
touch $@
290
289
291
290
.install-stage1.touch : export FSTAR_LINK_LIBDIRS=$(LINK_OK )
0 commit comments