Xen-unstable "make clean" error on a freshly cloned tree
Hi Wei / Ian,
I'm getting this error on a "make clean" on a freshly cloned xen-unstable staging tree. It's probably because the make script can't handle a make clean on a tree which hasn't cloned the mini-os tree at least once as part of a build.
make[2]: Entering directory `/usr/src/new/xen-unstable/tools' make -C python clean
make[3]: Entering directory `/usr/src/new/xen-unstable/tools/python' find . \( -name "*.py[ocd]" -o -name "*~" -o -name "_*.[hc]" \) -delete rm -rf build/
rm -f .*.d
make[3]: Leaving directory /usr/src/new/xen-unstable/tools/python' make[2]: Leaving directory /usr/src/new/xen-unstable/tools' make[2]: Entering directory `/usr/src/new/xen-unstable/tools' make -C pygrub clean
make[3]: Entering directory `/usr/src/new/xen-unstable/tools/pygrub' rm -rf build tmp *.pyc *.pyo *.o *.a *~ a.out .*.d
make[3]: Leaving directory /usr/src/new/xen-unstable/tools/pygrub' make[2]: Leaving directory /usr/src/new/xen-unstable/tools' make[1]: Leaving directory `/usr/src/new/xen-unstable/tools' make -C stubdom crossclean
make[1]: Entering directory /usr/src/new/xen-unstable/stubdom' Makefile:5: *** Please run make mini-os-dir' in top-level directory. Stop. make[1]: Leaving directory `/usr/src/new/xen-unstable/stubdom'
make: *** [clean-stubdom] Error 2
--
Sander
Quoted 6 lines · Sander Eikelenboom
Hi Wei / Ian,
I'm getting this error on a "make clean" on a freshly cloned xen-unstable staging tree. It's probably because the make script can't handle a make clean on a tree which hasn't cloned the mini-os tree at least once as part of a build.
Yes. I thought we had addressed that during review, but it seems we only caught one of the two places.
Wei,
I think this bit of stubdom/Makefile:
ifeq ($(wildcard $(MINI_OS)/Config.mk),)
$(error Please run `make mini-os-dir' in top-level directory)
endifNeeds something like this pattern from the end of tools/Rules.mk, combined with the wildcard stuff (or switching to a dependency on Config.mk):
ifeq (,$(findstring clean,$(MAKECMDGOALS)))
$(XEN_ROOT)/config/Tools.mk:
$(error You have to run ./configure before building or installing the tools)
endifI think that'll catch clean and distclean.
Can you whip up a patch please.
Ian.