NameDateSize

..20-Nov-201931

base/H25-Jul-20195

dir1/H25-Jul-20194

dir2/H25-Jul-20194

HolmakefileH A D25-Jul-2019193

intermediate/H25-Jul-20194

README.mdH A D25-Jul-20191.3 KiB

ultimateScript.smlH A D25-Jul-2019151

README.md

1# Buggy behaviour 1
2
3If we have a Holmake called across a bunch of `INCLUDES` (`dir1`, and `dir2` say), and both refer to a `base` then it is possible for the second call not to see `base` when it comes to generating dependency information for things under `dir1`.
4When the system tries to load the corresponding thing, you get a failure.
5
6In the wild, this was seen in CakeML, where it was possible to get files failing to include `lprefix_lub` theory as a dependency.
7
8We set up a dependency graph that looks like
9
10                                 ���������������> dir1 ������������
11       base ���������> intermediate ������������              ������������> ultimate
12                                 ���������������> dir2 ������������
13
14The buggy behaviour fails to give `dir2Theory` its correct dependency on `baseTheory` if `dir1` is built first in the same session, as happens if `Holmake` is called in the directory containing `ultimate`.
15If `dir1` and `dir2` are built independently everything works.
16
17# Buggy behaviour 2
18
19You need to also check that the graph above only recurses into `base` (and `intermediate`) once.
20The test as written checks for this by having a (phony) makefile rule in `base` that fires on every call, and which creates first a file called `one` and then one called `two`. The existence of `base/two` is checked for in the top-level `Holmakefile`.
21