[Omake] SVN Commit: OMake Build System [0.9.8.x] (Rev. 9376)
Aleksey Nogin
nogin at cs.caltech.edu
Fri Jun 23 14:19:47 PDT 2006
On 23.06.2006 12:59, Jason Hickey wrote:
> Added the bounds-check. Implicit calculations are not guaranteed
> to terminate in general, but simple cycles will be rejected.
> A simple cycle is one where a file depends on itself (through
> some chain of dependencies).
This fix is definitely better than nothing (it will only kill those
cases that would have resulted in an infinite loop before), but it's not
ideal - it's interaction with a cache may result in a "missed opportunity".
$ cat OMakefile
.DEFAULT: file.a
%.e: %.c
cp $< $@
%.d:
touch $@
%.b: %.d
cp $< $@
%.c: %.b
cp $< $@
%.b: %.c
cp $< $@
%.a: %.b %.e
cp $< $@
$ omake
*** omake: reading OMakefiles
*** omake: finished reading OMakefiles (0.1 sec)
*** omake: 7/8 targets are up to date
*** omake: failed (0.1 sec, 0/0 scans, 0/0 rules, 8/33 digests)
*** omake error:
File OMakefile: line 1, characters 0-16
Do not know how to build "file.a" required for "<phony <.DEFAULT>>"
Exit 123
But the file is actually buldable - and if the "%.b: %.c" rule is
deleted, then OMake does not have any problems figuring it out.
The problem here that file.c is examined first as a potential way of
building file.b. Since the only way to build file.c is to use file.b, we
detect a loop and mark file.c as unbuildable. But this is not true - it
is only unbuildable if we do not have _another_ way of building file.b,
not involving file.c, and here we do have such a way.
I am not sure whether it's worth fixing this. But I though that it is
worth pointing out this issue.
--
Aleksey Nogin
Home Page: http://nogin.org/
E-Mail: nogin at cs.caltech.edu (office), aleksey at nogin.org (personal)
Office: Moore 04, tel: (626) 395-2200
More information about the OMake-Devel
mailing list