# Patch Makefile to patch insource newlib, # Prevent internal downloading of external packages diff -ur xen-4.2.0.orig/stubdom/Makefile xen-4.2.0/stubdom/Makefile --- stubdom/Makefile 2012-09-17 18:21:17.000000000 +0800 +++ stubdom/Makefile 2012-12-05 14:01:10.694260256 +0800 @@ -95,12 +95,13 @@ ############## newlib-$(NEWLIB_VERSION).tar.gz: - $(WGET) $(NEWLIB_URL)/$@ +# $(WGET) $(NEWLIB_URL)/$@ newlib-$(NEWLIB_VERSION): newlib-$(NEWLIB_VERSION).tar.gz tar xzf $< patch -d $@ -p0 < newlib.patch patch -d $@ -p0 < newlib-chk.patch + patch -d $@ -p0 < newlib-implicits.patch patch -d $@ -p1 < newlib-stdint-size_max-fix-from-1.17.0.patch find $@ -type f | xargs perl -i.bak \ -pe 's/\b_(tzname|daylight|timezone)\b/$$1/g' @@ -110,7 +110,7 @@ $(NEWLIB_STAMPFILE): mk-headers-$(XEN_TARGET_ARCH) newlib-$(NEWLIB_VERSION) mkdir -p newlib-$(XEN_TARGET_ARCH) ( cd newlib-$(XEN_TARGET_ARCH) && \ - 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 && \ + CC_FOR_TARGET="$(CC) $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) $(NEWLIB_CFLAGS)" AR_FOR_TARGET=$(AR) LD_FOR_TARGET=$(LD) LDFLAGS= 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 && \ $(MAKE) DESTDIR= && \ $(MAKE) DESTDIR= install ) @@ -121,7 +122,7 @@ ############ zlib-$(ZLIB_VERSION).tar.gz: - $(WGET) $(ZLIB_URL)/$@ +# $(WGET) $(ZLIB_URL)/$@ zlib-$(XEN_TARGET_ARCH): zlib-$(ZLIB_VERSION).tar.gz tar xzf $< @@ -141,7 +142,7 @@ ############## pciutils-$(LIBPCI_VERSION).tar.bz2: - $(WGET) $(LIBPCI_URL)/$@ +# $(WGET) $(LIBPCI_URL)/$@ pciutils-$(XEN_TARGET_ARCH): pciutils-$(LIBPCI_VERSION).tar.bz2 tar xjf $< @@ -169,7 +170,7 @@ ###### lwip-$(LWIP_VERSION).tar.gz: - $(WGET) $(LWIP_URL)/$@ +# $(WGET) $(LWIP_URL)/$@ lwip-$(XEN_TARGET_ARCH): lwip-$(LWIP_VERSION).tar.gz tar xzf $< @@ -325,7 +326,7 @@ ###### grub-$(GRUB_VERSION).tar.gz: - $(WGET) $(GRUB_URL)/$@ +#$(WGET) $(GRUB_URL)/$@ grub-upstream: grub-$(GRUB_VERSION).tar.gz tar xzf $< @@ -392,7 +393,7 @@ $(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)" $(INSTALL_DATA) mini-os-$(XEN_TARGET_ARCH)-ioemu/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/ioemu-stubdom.gz" -install-grub: pv-grub +install-grub: $(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)" $(INSTALL_DATA) mini-os-$(XEN_TARGET_ARCH)-grub/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/pv-grub-$(XEN_TARGET_ARCH).gz"