[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 4/4] Allow tool chain to be specified for bios build
From: |
Anthony Liguori |
Subject: |
[Qemu-devel] [PATCH 4/4] Allow tool chain to be specified for bios build |
Date: |
Sun, 17 May 2009 10:29:01 -0500 |
Signed-off-by: Anthony Liguori <address@hidden>
---
Makefile.target | 8 ++++++--
configure | 46 ++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 52 insertions(+), 2 deletions(-)
diff --git a/Makefile.target b/Makefile.target
index 567618b..7f67734 100644
--- a/Makefile.target
+++ b/Makefile.target
@@ -715,8 +715,12 @@ endif
# Per architecture ROMS
ROMS=
ifeq ($(TARGET_BASE_ARCH),i386)
+ifneq ($(BCC),)
+ifneq ($(GCC_I386),)
ROMS+=gplbios vgabios
endif
+endif
+endif
vl.o: qemu-options.h
@@ -742,7 +746,7 @@ qemu-options.h: $(SRC_PATH)/qemu-options.hx
roms:
@if test "$(ROMS)" ; then \
for subdir in $(ROMS); do \
- $(MAKE) -C roms/$${subdir} VPATH=$(SRC_PATH)/roms/$${subdir} ;\
+ $(MAKE) -C roms/$${subdir} VPATH=$(SRC_PATH)/roms/$${subdir}
"BCC=$(BCC)" "GCC32=$(GCC_I386)";\
done; \
fi
@@ -750,7 +754,7 @@ clean:
rm -f *.o *.a *~ $(PROGS) nwfpe/*.o fpu/*.o qemu-options.h gdbstub-xml.c
rm -f *.d */*.d tcg/*.o
for subdir in $(ROMS); do \
- $(MAKE) -C $${subdir} clean \
+ $(MAKE) -C roms/$${subdir} clean; \
done
install: all
diff --git a/configure b/configure
index 29a13ca..6f9a152 100755
--- a/configure
+++ b/configure
@@ -194,6 +194,10 @@ fdt="yes"
sdl_x11="no"
xen="yes"
pkgversion=""
+have_bcc="yes"
+bcc="bcc"
+have_gcc_i386="yes"
+gcc_i386="gcc -m32 -fno-stack-protector"
# OS specific
if check_define __linux__ ; then
@@ -1262,6 +1266,40 @@ if test "$rt" = "yes" ; then
CLOCKLIBS="-lrt"
fi
+# FIXME
+# check for iasl and as86
+
+#########################################
+# Check for BCC
+cat > $TMPC <<EOF
+int main(argc, argv) int argc; char **argv; { return 0; }
+EOF
+
+if test "$have_bcc" = "yes" ; then
+ if $bcc -o $TMPE $TMPC > /dev/null 2> /dev/null ; then
+ :
+ else
+ have_bcc="no"
+ fi
+fi
+
+#########################################
+# Check for GCC on i386
+cat > $TMPC <<EOF
+#ifndef __i386__
+#error Not i386
+#endif
+int main(void) { return 0; }
+EOF
+
+if test "$have_gcc_i386" = "yes" ; then
+ if $gcc_i386 -o $TMPE $TMPC > /dev/null 2> /dev/null ; then
+ :
+ else
+ have_gcc_i386="no"
+ fi
+fi
+
if test "$mingw32" = "yes" ; then
if test -z "$prefix" ; then
prefix="c:\\\\Program Files\\\\Qemu"
@@ -1714,6 +1752,14 @@ else
exit 1
fi
+if test "$have_bcc" = "yes" ; then
+ echo "BCC=$bcc" >> $config_mak
+fi
+
+if test "$have_gcc_i386" = "yes" ; then
+ echo "GCC_I386=$gcc_i386" >> $config_mak
+fi
+
tools=
if test `expr "$target_list" : ".*softmmu.*"` != 0 ; then
tools="qemu-img\$(EXESUF) $tools"
--
1.6.2.5
- Re: [Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, (continued)
- Re: [Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, Anthony Liguori, 2009/05/17
- Re: [Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, Avi Kivity, 2009/05/17
- Re: [Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, Anthony Liguori, 2009/05/17
- Re: [Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, Avi Kivity, 2009/05/17
- Re: [Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, Anthony Liguori, 2009/05/17
- Re: [Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, Avi Kivity, 2009/05/18
[Qemu-devel] Re: [PATCH 1/4] Add GPL bios as a submodule, Sebastian Herbszt, 2009/05/17
[Qemu-devel] [PATCH 4/4] Allow tool chain to be specified for bios build,
Anthony Liguori <=
[Qemu-devel] [PATCH 2/4] Add submodule for VGABios, Anthony Liguori, 2009/05/17
[Qemu-devel] [PATCH 3/4] Update makefile to build roms, Anthony Liguori, 2009/05/17