debuggers.hg

view stubdom/Makefile @ 22465:a4e3051f811b

Revert 61c0c52a8c6c "qemu-xen: build adjustments"

It appears that the changeset
qemu-xen: build adjustments to support out-of-tree builds
broke the build.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
author Ian Jackson <Ian.Jackson@eu.citrix.com>
date Tue Nov 23 18:38:16 2010 +0000 (2010-11-23)
parents 61c0c52a8c6c
children de125ae8415d
line source
1 XEN_ROOT = ..
2 MINI_OS = $(XEN_ROOT)/extras/mini-os
4 export XEN_OS=MiniOS
6 export stubdom=y
7 export debug=y
8 include $(XEN_ROOT)/Config.mk
10 #ZLIB_URL?=http://www.zlib.net
11 ZLIB_URL=$(XEN_EXTFILES_URL)
12 ZLIB_VERSION=1.2.3
14 #LIBPCI_URL?=http://www.kernel.org/pub/software/utils/pciutils
15 LIBPCI_URL?=$(XEN_EXTFILES_URL)
16 LIBPCI_VERSION=2.2.9
18 #NEWLIB_URL?=ftp://sources.redhat.com/pub/newlib
19 NEWLIB_URL?=$(XEN_EXTFILES_URL)
20 NEWLIB_VERSION=1.16.0
22 #LWIP_URL?=http://download.savannah.gnu.org/releases/lwip
23 LWIP_URL?=$(XEN_EXTFILES_URL)
24 LWIP_VERSION=1.3.0
26 #GRUB_URL?=http://alpha.gnu.org/gnu/grub
27 GRUB_URL?=$(XEN_EXTFILES_URL)
28 GRUB_VERSION=0.97
30 #OCAML_URL?=$(XEN_EXTFILES_URL)
31 OCAML_URL?=http://caml.inria.fr/pub/distrib/ocaml-3.11
32 OCAML_VERSION=3.11.0
34 WGET=wget -c
36 GNU_TARGET_ARCH:=$(XEN_TARGET_ARCH)
37 ifeq ($(XEN_TARGET_ARCH),x86_32)
38 GNU_TARGET_ARCH:=i686
39 endif
41 ifeq ($(GNU_TARGET_ARCH), i686)
42 TARGET_CFLAGS=
43 NEWLIB_CFLAGS+=-D_I386MACH_ALLOW_HW_INTERRUPTS
44 STUBDOM_SUPPORTED=1
45 endif
46 ifeq ($(GNU_TARGET_ARCH), x86_64)
47 TARGET_CFLAGS=-mno-red-zone
48 NEWLIB_CFLAGS+=-D_I386MACH_ALLOW_HW_INTERRUPTS
49 STUBDOM_SUPPORTED=1
50 endif
51 ifeq ($(GNU_TARGET_ARCH), ia64)
52 TARGET_CFLAGS=-mconstant-gp
53 endif
55 CROSS_ROOT=cross-root-$(GNU_TARGET_ARCH)
56 CROSS_PREFIX=$(CURDIR)/$(CROSS_ROOT)
58 # Disable PIE/SSP if GCC supports them. They can break us.
59 TARGET_CFLAGS += $(CFLAGS)
60 TARGET_CPPFLAGS += $(CPPFLAGS)
61 $(call cc-options-add,TARGET_CFLAGS,CC,$(EMBEDDED_EXTRA_CFLAGS))
63 # Do not use host headers and libs
64 GCC_INSTALL = $(shell LANG=C gcc -print-search-dirs | sed -n -e 's/install: \(.*\)/\1/p')
65 TARGET_CPPFLAGS += -U __linux__ -U __FreeBSD__ -U __sun__
66 TARGET_CPPFLAGS += -nostdinc
67 TARGET_CPPFLAGS += -isystem $(CURDIR)/$(MINI_OS)/include/posix
68 TARGET_CPPFLAGS += -isystem $(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf/include
69 TARGET_CPPFLAGS += -isystem $(GCC_INSTALL)include
70 TARGET_CPPFLAGS += -isystem $(CURDIR)/lwip-$(XEN_TARGET_ARCH)/src/include
71 TARGET_CPPFLAGS += -isystem $(CURDIR)/lwip-$(XEN_TARGET_ARCH)/src/include/ipv4
72 TARGET_CPPFLAGS += -I$(CURDIR)/include
73 TARGET_CPPFLAGS += -I$(XEN_ROOT)/xen/include
75 TARGET_LDFLAGS += -nostdlib -L$(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf/lib
77 TARGETS=ioemu c caml grub
79 CROSS_MAKE := $(MAKE) DESTDIR=
81 .PHONY: all
82 all: build
83 ifeq ($(STUBDOM_SUPPORTED),1)
84 build: genpath ioemu-stubdom c-stubdom pv-grub
85 else
86 build: genpath
87 endif
89 STUBDOMPATH="stubdompath.sh"
90 genpath-target = $(call buildmakevars2file,$(STUBDOMPATH))
91 $(eval $(genpath-target))
93 ##############
94 # Cross-newlib
95 ##############
97 newlib-$(NEWLIB_VERSION).tar.gz:
98 $(WGET) $(NEWLIB_URL)/$@
100 newlib-$(NEWLIB_VERSION): newlib-$(NEWLIB_VERSION).tar.gz
101 tar xzf $<
102 patch -d $@ -p0 < newlib.patch
103 patch -d $@ -p0 < newlib-chk.patch
104 patch -d $@ -p1 < newlib-stdint-size_max-fix-from-1.17.0.patch
105 find $@ -type f | xargs perl -i.bak \
106 -pe 's/\b_(tzname|daylight|timezone)\b/$$1/g'
107 touch $@
109 NEWLIB_STAMPFILE=$(CROSS_ROOT)/$(GNU_TARGET_ARCH)-xen-elf/lib/libc.a
110 .PHONY: cross-newlib
111 cross-newlib: $(NEWLIB_STAMPFILE)
112 $(NEWLIB_STAMPFILE): mk-headers-$(XEN_TARGET_ARCH) newlib-$(NEWLIB_VERSION)
113 mkdir -p newlib-$(XEN_TARGET_ARCH)
114 ( cd newlib-$(XEN_TARGET_ARCH) && \
115 CC_FOR_TARGET="$(CC) $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) $(NEWLIB_CFLAGS)" AR_FOR_TARGET=$(AR) LD_FOR_TARGET=$(LD) RANLIB_FOR_TARGET=$(RANLIB) ../newlib-$(NEWLIB_VERSION)/configure --prefix=$(CROSS_PREFIX) --verbose --target=$(GNU_TARGET_ARCH)-xen-elf --enable-newlib-io-long-long --disable-multilib && \
116 $(CROSS_MAKE) && \
117 $(CROSS_MAKE) install )
119 ############
120 # Cross-zlib
121 ############
123 zlib-$(ZLIB_VERSION).tar.gz:
124 $(WGET) $(ZLIB_URL)/$@
126 zlib-$(XEN_TARGET_ARCH): zlib-$(ZLIB_VERSION).tar.gz
127 tar xzf $<
128 mv zlib-$(ZLIB_VERSION) $@
130 ZLIB_STAMPFILE=$(CROSS_ROOT)/$(GNU_TARGET_ARCH)-xen-elf/lib/libz.a
131 .PHONY: cross-zlib
132 cross-zlib: $(ZLIB_STAMPFILE)
133 $(ZLIB_STAMPFILE): zlib-$(XEN_TARGET_ARCH) $(NEWLIB_STAMPFILE)
134 ( cd $< && \
135 CFLAGS="$(TARGET_CPPFLAGS) $(TARGET_CFLAGS)" CC=$(CC) ./configure --prefix=$(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf && \
136 $(CROSS_MAKE) libz.a && \
137 $(CROSS_MAKE) install )
139 ##############
140 # Cross-libpci
141 ##############
143 pciutils-$(LIBPCI_VERSION).tar.bz2:
144 $(WGET) $(LIBPCI_URL)/$@
146 pciutils-$(XEN_TARGET_ARCH): pciutils-$(LIBPCI_VERSION).tar.bz2
147 tar xjf $<
148 mv pciutils-$(LIBPCI_VERSION) $@
149 patch -d $@ -p1 < pciutils.patch
150 touch $@
152 LIBPCI_STAMPFILE=$(CROSS_ROOT)/$(GNU_TARGET_ARCH)-xen-elf/lib/libpci.a
153 .PHONY: cross-libpci
154 cross-libpci: $(LIBPCI_STAMPFILE)
155 $(LIBPCI_STAMPFILE): pciutils-$(XEN_TARGET_ARCH) $(NEWLIB_STAMPFILE) $(ZLIB_STAMPFILE)
156 ( cd $< && \
157 cp ../libpci.config.h lib/config.h && \
158 chmod u+w lib/config.h && \
159 echo '#define PCILIB_VERSION "$(LIBPCI_VERSION)"' >> lib/config.h && \
160 ln -sf ../../libpci.config.mak lib/config.mk && \
161 $(CROSS_MAKE) CC="$(CC) $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) -I$(realpath $(MINI_OS)/include)" lib/libpci.a && \
162 $(INSTALL_DATA) lib/libpci.a $(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf/lib/ && \
163 $(INSTALL_DIR) $(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf/include/pci && \
164 $(INSTALL_DATA) lib/config.h lib/header.h lib/pci.h lib/types.h $(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf/include/pci/ \
165 )
167 ######
168 # lwIP
169 ######
171 lwip-$(LWIP_VERSION).tar.gz:
172 $(WGET) $(LWIP_URL)/$@
174 lwip-$(XEN_TARGET_ARCH): lwip-$(LWIP_VERSION).tar.gz
175 tar xzf $<
176 mv lwip $@
177 patch -d $@ -p0 < lwip.patch-cvs
178 touch $@
180 #############
181 # Cross-ocaml
182 #############
184 CAMLLIB = $(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf/lib/ocaml
185 OCAML_STAMPFILE=$(CAMLLIB)/.dirstamp
187 ocaml-$(OCAML_VERSION).tar.gz:
188 $(WGET) $(OCAML_URL)/$@
190 ocaml-$(XEN_TARGET_ARCH)/.dirstamp: ocaml-$(OCAML_VERSION).tar.gz ocaml.patch
191 tar xzf $<
192 cd ocaml-$(OCAML_VERSION) && patch -p0 < ../ocaml.patch
193 rm -rf ocaml-$(XEN_TARGET_ARCH)
194 mv ocaml-$(OCAML_VERSION) ocaml-$(XEN_TARGET_ARCH)
195 touch $@
197 MINIOS_HASNOT=IPV6 INET_ATON
199 .PHONY: cross-ocaml
200 cross-ocaml: $(OCAML_STAMPFILE)
201 $(OCAML_STAMPFILE): ocaml-$(XEN_TARGET_ARCH)/.dirstamp
202 cd ocaml-$(XEN_TARGET_ARCH) && ./configure -prefix $(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf \
203 -no-pthread -no-shared-libs -no-tk -no-curses \
204 -cc "$(CC) -U_FORTIFY_SOURCE -fno-stack-protector -mno-red-zone"
205 $(foreach i,$(MINIOS_HASNOT),sed -i 's,^\(#define HAS_$(i)\),//\1,' ocaml-$(XEN_TARGET_ARCH)/config/s.h ; )
206 $(CROSS_MAKE) -C ocaml-$(XEN_TARGET_ARCH) world
207 $(CROSS_MAKE) -C ocaml-$(XEN_TARGET_ARCH) opt
208 $(MAKE) -C ocaml-$(XEN_TARGET_ARCH) install
209 touch $@
211 #######
212 # Links
213 #######
215 .PHONY: $(CROSS_ROOT)
216 $(CROSS_ROOT): cross-newlib cross-zlib cross-libpci
218 $(XEN_ROOT)/tools/ioemu-dir:
219 $(CROSS_MAKE) -C $(XEN_ROOT)/tools ioemu-dir-find
221 ioemu/linkfarm.stamp: $(XEN_ROOT)/tools/ioemu-dir
222 mkdir -p ioemu
223 set -e; \
224 $(absolutify_xen_root); \
225 cd ioemu; \
226 src="$$XEN_ROOT/tools/ioemu-dir"; export src; \
227 (cd $$src && find * -type d -print) | xargs mkdir -p; \
228 (cd $$src && find * ! -type l -type f $(addprefix ! -name , \
229 '*.[oda1]' 'config-*' config.mak qemu-dm qemu-img-xen \
230 '*.html' '*.pod' \
231 )) | \
232 while read f; do rm -f "$$f"; ln -s "$$src/$$f" "$$f"; done
233 touch ioemu/linkfarm.stamp
235 mk-headers-$(XEN_TARGET_ARCH): ioemu/linkfarm.stamp
236 mkdir -p include/xen && \
237 ln -sf $(addprefix ../../,$(wildcard $(XEN_ROOT)/xen/include/public/*.h)) include/xen && \
238 ln -sf $(addprefix ../../$(XEN_ROOT)/xen/include/public/,arch-ia64 arch-x86 hvm io xsm) include/xen && \
239 ( [ -h include/xen/sys ] || ln -sf ../../$(XEN_ROOT)/tools/include/xen-sys/MiniOS include/xen/sys ) && \
240 ( [ -h include/xen/libelf ] || ln -sf ../../$(XEN_ROOT)/tools/include/xen/libelf include/xen/libelf ) && \
241 mkdir -p include/xen-foreign && \
242 ln -sf $(addprefix ../../,$(wildcard $(XEN_ROOT)/tools/include/xen-foreign/*)) include/xen-foreign/ && \
243 $(CROSS_MAKE) -C include/xen-foreign/ && \
244 ( [ -h include/xen/foreign ] || ln -sf ../xen-foreign include/xen/foreign )
245 mkdir -p libxc-$(XEN_TARGET_ARCH)
246 [ -h libxc-$(XEN_TARGET_ARCH)/Makefile ] || ( cd libxc-$(XEN_TARGET_ARCH) && \
247 ln -sf ../$(XEN_ROOT)/tools/libxc/*.h . && \
248 ln -sf ../$(XEN_ROOT)/tools/libxc/*.c . && \
249 ln -sf ../$(XEN_ROOT)/tools/libxc/Makefile . )
250 mkdir -p libxc-$(XEN_TARGET_ARCH)/$(XEN_TARGET_ARCH)
251 [ -h libxc-$(XEN_TARGET_ARCH)/$(XEN_TARGET_ARCH) ] || ( cd libxc-$(XEN_TARGET_ARCH)/$(XEN_TARGET_ARCH) && \
252 ln -sf ../$(XEN_ROOT)/tools/libxc/$(XEN_TARGET_ARCH)/*.c . && \
253 ln -sf ../$(XEN_ROOT)/tools/libxc/$(XEN_TARGET_ARCH)/*.h . && \
254 ln -sf ../$(XEN_ROOT)/tools/libxc/$(XEN_TARGET_ARCH)/Makefile . )
255 $(CROSS_MAKE) -C $(MINI_OS) links
256 touch mk-headers-$(XEN_TARGET_ARCH)
258 TARGETS_MINIOS=$(addprefix mini-os-$(XEN_TARGET_ARCH)-,$(TARGETS))
259 $(TARGETS_MINIOS): mini-os-%:
260 [ -d $@ ] || \
261 for i in $$(cd $(MINI_OS) ; find . -type d) ; do \
262 mkdir -p $@/$$i ; \
263 done
265 #######
266 # libxc
267 #######
269 .PHONY: libxc
270 libxc: libxc-$(XEN_TARGET_ARCH)/libxenctrl.a libxc-$(XEN_TARGET_ARCH)/libxenguest.a
271 libxc-$(XEN_TARGET_ARCH)/libxenctrl.a: cross-zlib
272 CPPFLAGS="$(TARGET_CPPFLAGS)" CFLAGS="$(TARGET_CFLAGS)" $(CROSS_MAKE) -C libxc-$(XEN_TARGET_ARCH)
274 libxc-$(XEN_TARGET_ARCH)/libxenguest.a: libxc-$(XEN_TARGET_ARCH)/libxenctrl.a
276 #######
277 # ioemu
278 #######
280 .PHONY: ioemu
281 ioemu: cross-zlib cross-libpci libxc
282 [ -f ioemu/config-host.mak ] || \
283 ( $(absolutify_xen_root); \
284 $(buildmakevars2shellvars); \
285 cd ioemu ; \
286 LWIPDIR=$(CURDIR)/lwip-$(XEN_TARGET_ARCH) \
287 TARGET_CPPFLAGS="$(TARGET_CPPFLAGS)" \
288 TARGET_CFLAGS="$(TARGET_CFLAGS)" \
289 TARGET_LDFLAGS="$(TARGET_LDFLAGS)" \
290 ./xen-setup-stubdom )
291 $(CROSS_MAKE) -C ioemu
293 ######
294 # caml
295 ######
297 .PHONY: caml
298 caml: $(CROSS_ROOT)
299 CPPFLAGS="$(TARGET_CPPFLAGS)" CFLAGS="$(TARGET_CFLAGS)" $(CROSS_MAKE) -C $@ LWIPDIR=$(CURDIR)/lwip-$(XEN_TARGET_ARCH) OCAMLC_CROSS_PREFIX=$(CROSS_PREFIX)/$(GNU_TARGET_ARCH)-xen-elf/bin/
301 ###
302 # C
303 ###
305 .PHONY: c
306 c: $(CROSS_ROOT)
307 CPPFLAGS="$(TARGET_CPPFLAGS)" CFLAGS="$(TARGET_CFLAGS)" $(CROSS_MAKE) -C $@ LWIPDIR=$(CURDIR)/lwip-$(XEN_TARGET_ARCH)
309 ######
310 # Grub
311 ######
313 grub-$(GRUB_VERSION).tar.gz:
314 $(WGET) $(GRUB_URL)/$@
316 grub-upstream: grub-$(GRUB_VERSION).tar.gz
317 tar xzf $<
318 mv grub-$(GRUB_VERSION) $@
319 for i in grub.patches/* ; do \
320 patch -d $@ -p1 < $$i ; \
321 done
323 .PHONY: grub
324 grub: grub-upstream $(CROSS_ROOT)
325 mkdir -p grub-$(XEN_TARGET_ARCH)
326 CPPFLAGS="$(TARGET_CPPFLAGS)" CFLAGS="$(TARGET_CFLAGS)" $(CROSS_MAKE) -C $@ OBJ_DIR=$(CURDIR)/grub-$(XEN_TARGET_ARCH)
328 ########
329 # minios
330 ########
332 .PHONY: ioemu-stubdom
333 ioemu-stubdom: APP_OBJS=$(CURDIR)/ioemu/i386-stubdom/qemu.a $(CURDIR)/ioemu/i386-stubdom/libqemu.a $(CURDIR)/ioemu/libqemu_common.a
334 ioemu-stubdom: mini-os-$(XEN_TARGET_ARCH)-ioemu lwip-$(XEN_TARGET_ARCH) libxc ioemu
335 DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="-DCONFIG_QEMU $(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" $(CROSS_MAKE) -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< LWIPDIR=$(CURDIR)/lwip-$(XEN_TARGET_ARCH) APP_OBJS="$(APP_OBJS)"
337 .PHONY: caml-stubdom
338 caml-stubdom: mini-os-$(XEN_TARGET_ARCH)-caml lwip-$(XEN_TARGET_ARCH) libxc cross-ocaml caml
339 DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="-DCONFIG_CAML $(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" $(CROSS_MAKE) -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< LWIPDIR=$(CURDIR)/lwip-$(XEN_TARGET_ARCH) APP_OBJS="$(CURDIR)/caml/main-caml.o $(CURDIR)/caml/caml.o $(CAMLLIB)/libasmrun.a"
341 .PHONY: c-stubdom
342 c-stubdom: mini-os-$(XEN_TARGET_ARCH)-c lwip-$(XEN_TARGET_ARCH) libxc c
343 DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="-DCONFIG_C $(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" $(CROSS_MAKE) -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< LWIPDIR=$(CURDIR)/lwip-$(XEN_TARGET_ARCH) APP_OBJS=$(CURDIR)/c/main.a
345 .PHONY: pv-grub
346 pv-grub: mini-os-$(XEN_TARGET_ARCH)-grub libxc grub
347 DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="-DCONFIG_GRUB $(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" $(CROSS_MAKE) -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/grub-$(XEN_TARGET_ARCH)/main.a
349 #########
350 # install
351 #########
353 ifeq ($(STUBDOM_SUPPORTED),1)
354 install: genpath install-readme install-ioemu install-grub
355 else
356 install: genpath
357 endif
359 install-readme:
360 $(INSTALL_DIR) $(DESTDIR)$(DOCDIR)
361 $(INSTALL_DATA) README $(DESTDIR)$(DOCDIR)/README.stubdom
363 install-ioemu: ioemu-stubdom
364 $(INSTALL_DIR) "$(DESTDIR)$(LIBEXEC)"
365 $(INSTALL_PROG) stubdompath.sh stubdom-dm "$(DESTDIR)$(LIBEXEC)"
366 $(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)"
367 $(INSTALL_DATA) mini-os-$(XEN_TARGET_ARCH)-ioemu/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/ioemu-stubdom.gz"
369 install-grub: pv-grub
370 $(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)"
371 $(INSTALL_DATA) mini-os-$(XEN_TARGET_ARCH)-grub/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/pv-grub-$(XEN_TARGET_ARCH).gz"
373 #######
374 # clean
375 #######
377 # Only clean the libxc/ioemu/mini-os part
378 .PHONY: clean
379 clean:
380 rm -fr mini-os-$(XEN_TARGET_ARCH)-ioemu
381 rm -fr mini-os-$(XEN_TARGET_ARCH)-c
382 rm -fr mini-os-$(XEN_TARGET_ARCH)-caml
383 rm -fr mini-os-$(XEN_TARGET_ARCH)-grub
384 $(CROSS_MAKE) -C caml clean
385 $(CROSS_MAKE) -C c clean
386 rm -fr grub-$(XEN_TARGET_ARCH)
387 rm -f $(STUBDOMPATH)
388 [ ! -d libxc-$(XEN_TARGET_ARCH) ] || $(CROSS_MAKE) -C libxc-$(XEN_TARGET_ARCH) clean
389 -[ ! -d ioemu ] || $(CROSS_MAKE) -C ioemu clean
391 # clean the cross-compilation result
392 .PHONY: crossclean
393 crossclean: clean
394 rm -fr $(CROSS_ROOT)
395 rm -fr newlib-$(XEN_TARGET_ARCH)
396 rm -fr zlib-$(XEN_TARGET_ARCH) pciutils-$(XEN_TARGET_ARCH)
397 rm -fr libxc-$(XEN_TARGET_ARCH) ioemu
398 rm -f mk-headers-$(XEN_TARGET_ARCH)
399 rm -fr ocaml-$(XEN_TARGET_ARCH)
400 rm -fr include
402 # clean patched sources
403 .PHONY: patchclean
404 patchclean: crossclean
405 rm -fr newlib-$(NEWLIB_VERSION)
406 rm -fr lwip-$(XEN_TARGET_ARCH)
407 rm -fr grub-upstream
409 # clean downloads
410 .PHONY: downloadclean
411 downloadclean: patchclean
412 rm -f newlib-$(NEWLIB_VERSION).tar.gz
413 rm -f zlib-$(ZLIB_VERSION).tar.gz
414 rm -f pciutils-$(LIBPCI_VERSION).tar.bz2
415 rm -f grub-$(GRUB_VERSION).tar.gz
416 rm -f lwip-$(LWIP_VERSION).tar.gz
417 rm -f ocaml-$(OCAML_VERSION).tar.gz
419 .PHONY: distclean
420 distclean: downloadclean