Patchwork Quickfix for libuser.a drop

login
register
mail settings
Submitter Andreas Färber
Date Dec. 13, 2009, 3:40 p.m.
Message ID <1260718825-23158-1-git-send-email-andreas.faerber@web.de>
Download mbox | patch
Permalink /patch/41039/
State New
Headers show

Comments

Andreas Färber - Dec. 13, 2009, 3:40 p.m.
User emulators did not seem to have a $(HWLIB) directory, so don't try
to include config.mak from there in Makefile.target.

libuser.a included some objects of libqemu_common.a, so fix the paths to
the shared files, to avoid file not found errors while linking.

Signed-off-by: Andreas Färber <andreas.faerber@web.de>
Cc: Juan Quintela <quintela@trasno.org>
Cc: Avi Kivity <avi@redhat.com>
---
 Makefile.objs   |    4 ++--
 Makefile.target |    2 ++
 2 files changed, 4 insertions(+), 2 deletions(-)
Andreas Färber - Dec. 13, 2009, 3:55 p.m.
Am 13.12.2009 um 16:40 schrieb Andreas Färber:

> User emulators did not seem to have a $(HWLIB) directory, so don't try
> to include config.mak from there in Makefile.target.
>
> libuser.a included some objects of libqemu_common.a, so fix the  
> paths to
> the shared files, to avoid file not found errors while linking.

With this add-on patch, ppc-linux-user compiles, and linux-user- 
test-0.3 appears to work.

Andreas

> Signed-off-by: Andreas Färber <andreas.faerber@web.de>
> Cc: Juan Quintela <quintela@trasno.org>
> Cc: Avi Kivity <avi@redhat.com>
> ---
> Makefile.objs   |    4 ++--
> Makefile.target |    2 ++
> 2 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/Makefile.objs b/Makefile.objs
> index fd69717..045d338 100644
> --- a/Makefile.objs
> +++ b/Makefile.objs
> @@ -119,8 +119,8 @@ common-obj-$(CONFIG_XEN) += xen_console.o  
> xenfb.o xen_disk.o xen_nic.o
>
> user-obj-y =
> user-obj-y += envlist.o path.o
> -user-obj-y += tcg-runtime.o host-utils.o
> -user-obj-y += cutils.o cache-utils.o
> +user-obj-y += $(addprefix ../, tcg-runtime.o host-utils.o)
> +user-obj-y += $(addprefix ../, cutils.o cache-utils.o)
>
> ######################################################################
> # libhw
> diff --git a/Makefile.target b/Makefile.target
> index 22a2f1e..d4bb4d6 100644
> --- a/Makefile.target
> +++ b/Makefile.target
> @@ -7,7 +7,9 @@ include ../config-host.mak
> include config-devices.mak
> include config-target.mak
> include $(SRC_PATH)/rules.mak
> +ifneq ($(HWDIR),)
> include $(HWDIR)/config.mak
> +endif
>
> TARGET_PATH=$(SRC_PATH)/target-$(TARGET_BASE_ARCH)
> VPATH=$(SRC_PATH):$(TARGET_PATH):$(SRC_PATH)/hw
> -- 
> 1.6.5.2
>
>
>
Andreas Färber - Dec. 31, 2009, 1:19 p.m.
Am 13.12.2009 um 16:40 schrieb Andreas Färber:

> User emulators did not seem to have a $(HWLIB) directory, so don't try
> to include config.mak from there in Makefile.target.
>
> libuser.a included some objects of libqemu_common.a, so fix the  
> paths to
> the shared files, to avoid file not found errors while linking.

Patch cancelled. The object file path changes have been obsoleted by  
Paolo's "Use vpath directive". Only the config.mak change is still  
needed, I'll send a combined v2 shortly.

> Signed-off-by: Andreas Färber <andreas.faerber@web.de>
> Cc: Juan Quintela <quintela@trasno.org>
> Cc: Avi Kivity <avi@redhat.com>
> ---
> Makefile.objs   |    4 ++--
> Makefile.target |    2 ++
> 2 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/Makefile.objs b/Makefile.objs
> index fd69717..045d338 100644
> --- a/Makefile.objs
> +++ b/Makefile.objs
> @@ -119,8 +119,8 @@ common-obj-$(CONFIG_XEN) += xen_console.o  
> xenfb.o xen_disk.o xen_nic.o
>
> user-obj-y =
> user-obj-y += envlist.o path.o
> -user-obj-y += tcg-runtime.o host-utils.o
> -user-obj-y += cutils.o cache-utils.o
> +user-obj-y += $(addprefix ../, tcg-runtime.o host-utils.o)
> +user-obj-y += $(addprefix ../, cutils.o cache-utils.o)
>
> ######################################################################
> # libhw
> diff --git a/Makefile.target b/Makefile.target
> index 22a2f1e..d4bb4d6 100644
> --- a/Makefile.target
> +++ b/Makefile.target
> @@ -7,7 +7,9 @@ include ../config-host.mak
> include config-devices.mak
> include config-target.mak
> include $(SRC_PATH)/rules.mak
> +ifneq ($(HWDIR),)
> include $(HWDIR)/config.mak
> +endif
>
> TARGET_PATH=$(SRC_PATH)/target-$(TARGET_BASE_ARCH)
> VPATH=$(SRC_PATH):$(TARGET_PATH):$(SRC_PATH)/hw
> -- 
> 1.6.5.2
>
>
>

Patch

diff --git a/Makefile.objs b/Makefile.objs
index fd69717..045d338 100644
--- a/Makefile.objs
+++ b/Makefile.objs
@@ -119,8 +119,8 @@  common-obj-$(CONFIG_XEN) += xen_console.o xenfb.o xen_disk.o xen_nic.o
 
 user-obj-y =
 user-obj-y += envlist.o path.o
-user-obj-y += tcg-runtime.o host-utils.o
-user-obj-y += cutils.o cache-utils.o
+user-obj-y += $(addprefix ../, tcg-runtime.o host-utils.o)
+user-obj-y += $(addprefix ../, cutils.o cache-utils.o)
 
 ######################################################################
 # libhw
diff --git a/Makefile.target b/Makefile.target
index 22a2f1e..d4bb4d6 100644
--- a/Makefile.target
+++ b/Makefile.target
@@ -7,7 +7,9 @@  include ../config-host.mak
 include config-devices.mak
 include config-target.mak
 include $(SRC_PATH)/rules.mak
+ifneq ($(HWDIR),)
 include $(HWDIR)/config.mak
+endif
 
 TARGET_PATH=$(SRC_PATH)/target-$(TARGET_BASE_ARCH)
 VPATH=$(SRC_PATH):$(TARGET_PATH):$(SRC_PATH)/hw