All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686
@ 2020-03-03 14:10 Martin Jansa
  2020-03-03 14:10 ` [meta-virtualization][PATCH 2/2] xen-python2: add the same COMPATIBLE_HOST restriction as xen-tools Martin Jansa
  2020-03-04  1:03 ` [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686 Bruce Ashfield
  0 siblings, 2 replies; 8+ messages in thread
From: Martin Jansa @ 2020-03-03 14:10 UTC (permalink / raw)
  To: meta-virtualization; +Cc: Martin Jansa

* let TARGET_VENDOR to be set to something else than the default:
  meta/conf/bitbake.conf:TARGET_VENDOR = "-oe"
  like other architectures use
---
 recipes-extended/xen/xen-tools.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc
index 8bdbfec..8b86f7b 100644
--- a/recipes-extended/xen/xen-tools.inc
+++ b/recipes-extended/xen/xen-tools.inc
@@ -1,7 +1,7 @@
 SUMMARY = "Xen hypervisor tools"
 DESCRIPTION = "Tools and utility software for the Xen hypervisor"
 
-COMPATIBLE_HOST = 'i686-oe-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
+COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
 
 inherit setuptools3 update-rc.d systemd deploy
 require xen-blktap.inc
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [meta-virtualization][PATCH 2/2] xen-python2: add the same COMPATIBLE_HOST restriction as xen-tools
  2020-03-03 14:10 [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686 Martin Jansa
@ 2020-03-03 14:10 ` Martin Jansa
  2020-03-09 17:25   ` Christopher Clark
  2020-03-04  1:03 ` [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686 Bruce Ashfield
  1 sibling, 1 reply; 8+ messages in thread
From: Martin Jansa @ 2020-03-03 14:10 UTC (permalink / raw)
  To: meta-virtualization; +Cc: Martin Jansa

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
 recipes-extended/xen/xen-python2.bb | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/recipes-extended/xen/xen-python2.bb b/recipes-extended/xen/xen-python2.bb
index 08d8e92..ad3c1fd 100644
--- a/recipes-extended/xen/xen-python2.bb
+++ b/recipes-extended/xen/xen-python2.bb
@@ -6,6 +6,9 @@ SECTION = "console/tools"
 
 SRCREV ?= "a5fcafbfbee55261853fba07149c1c795f2baf58"
 
+# The same restriction as xen-tools.inc, because of the dependency on xen-tools-xentrace from xen-tools-xentrace-format
+COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
+
 XEN_REL ?= "4.12"
 XEN_BRANCH ?= "stable-4.12"
 
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686
  2020-03-03 14:10 [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686 Martin Jansa
  2020-03-03 14:10 ` [meta-virtualization][PATCH 2/2] xen-python2: add the same COMPATIBLE_HOST restriction as xen-tools Martin Jansa
@ 2020-03-04  1:03 ` Bruce Ashfield
  1 sibling, 0 replies; 8+ messages in thread
From: Bruce Ashfield @ 2020-03-04  1:03 UTC (permalink / raw)
  To: Martin Jansa; +Cc: meta-virtualization


merged.

Bruce

In message: [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686
on 03/03/2020 Martin Jansa wrote:

> * let TARGET_VENDOR to be set to something else than the default:
>   meta/conf/bitbake.conf:TARGET_VENDOR = "-oe"
>   like other architectures use
> ---
>  recipes-extended/xen/xen-tools.inc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc
> index 8bdbfec..8b86f7b 100644
> --- a/recipes-extended/xen/xen-tools.inc
> +++ b/recipes-extended/xen/xen-tools.inc
> @@ -1,7 +1,7 @@
>  SUMMARY = "Xen hypervisor tools"
>  DESCRIPTION = "Tools and utility software for the Xen hypervisor"
>  
> -COMPATIBLE_HOST = 'i686-oe-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> +COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
>  
>  inherit setuptools3 update-rc.d systemd deploy
>  require xen-blktap.inc
> -- 
> 2.20.1
> 

> 


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [meta-virtualization][PATCH 2/2] xen-python2: add the same COMPATIBLE_HOST restriction as xen-tools
  2020-03-03 14:10 ` [meta-virtualization][PATCH 2/2] xen-python2: add the same COMPATIBLE_HOST restriction as xen-tools Martin Jansa
@ 2020-03-09 17:25   ` Christopher Clark
  0 siblings, 0 replies; 8+ messages in thread
From: Christopher Clark @ 2020-03-09 17:25 UTC (permalink / raw)
  To: Martin Jansa; +Cc: meta-virtualization

On Tue, Mar 3, 2020 at 6:10 AM Martin Jansa <Martin.Jansa@gmail.com> wrote:
>
> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
> ---
>  recipes-extended/xen/xen-python2.bb | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/recipes-extended/xen/xen-python2.bb b/recipes-extended/xen/xen-python2.bb
> index 08d8e92..ad3c1fd 100644
> --- a/recipes-extended/xen/xen-python2.bb
> +++ b/recipes-extended/xen/xen-python2.bb
> @@ -6,6 +6,9 @@ SECTION = "console/tools"
>
>  SRCREV ?= "a5fcafbfbee55261853fba07149c1c795f2baf58"
>
> +# The same restriction as xen-tools.inc, because of the dependency on xen-tools-xentrace from xen-tools-xentrace-format
> +COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> +
>  XEN_REL ?= "4.12"
>  XEN_BRANCH ?= "stable-4.12"
>

Reviewed-by: Christopher Clark <christopher.w.clark@gmail.com>

Christopher

> --
> 2.20.1
>
> 

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686
  2020-03-06 23:52     ` Martin Jansa
@ 2020-03-12  0:35       ` Christopher Clark
  0 siblings, 0 replies; 8+ messages in thread
From: Christopher Clark @ 2020-03-12  0:35 UTC (permalink / raw)
  To: Martin Jansa; +Cc: meta-virtualization

On Fri, Mar 6, 2020 at 3:52 PM Martin Jansa <martin.jansa@gmail.com> wrote:
>
> On Wed, Mar 04, 2020 at 03:05:48PM -0800, Christopher Clark wrote:
> > On Wed, Mar 4, 2020 at 7:30 AM Martin Jansa <Martin.Jansa@gmail.com> wrote:
> > >
> > > On Tue, Mar 03, 2020 at 03:10:35PM +0100, Martin Jansa via Lists.Yoctoproject.Org wrote:
> > > > * let TARGET_VENDOR to be set to something else than the default:
> > > >   meta/conf/bitbake.conf:TARGET_VENDOR = "-oe"
> > > >   like other architectures use
> > > > ---
> > > >  recipes-extended/xen/xen-tools.inc | 2 +-
> > > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc
> > > > index 8bdbfec..8b86f7b 100644
> > > > --- a/recipes-extended/xen/xen-tools.inc
> > > > +++ b/recipes-extended/xen/xen-tools.inc
> > > > @@ -1,7 +1,7 @@
> > > >  SUMMARY = "Xen hypervisor tools"
> > > >  DESCRIPTION = "Tools and utility software for the Xen hypervisor"
> > > >
> > > > -COMPATIBLE_HOST = 'i686-oe-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> > > > +COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> > > >
> > > >  inherit setuptools3 update-rc.d systemd deploy
> > > >  require xen-blktap.inc
> > >
> > > Not really caused by this change, but now when the build can be started
> > > it fails for me with:
> > > error: mapfile-GNU:1:9: invalid use of VERSION in input file
> > > Makefile:52: recipe for target 'libxenfsimage.so.4.12.0' failed
> > >
> > > Anyone else seeing this? It's actually raspberrypi4 world build, so the
> > > COMPATIBLE_HOST above isn't related at all in this case.
> >
> > Thanks for the report, Martin. My first pass at repro'ing this did not
> > encounter this failure; but this is my first build with raspberrypi4
> > MACHINE, so it's possible that my config is different in some way. Are
> > you able to give any more guidance on your build configuration to
> > reproduce this? (MACHINE, layers and branches, conf file settings -
> > eg. enabling reproducible builds)
>
> It's reproducible only with gold, so:
> DISTRO_FEATURES_append = " ld-is-gold"
> in your local.conf should be able to reproduce it for any MACHINE (I see
> it with qemux86 as well).
>
> Easiest work around would be to add -fuse-ld=bfd when building xen-tools
> if nobody is interested to fix it properly.
>
> The issue is this file:
> http://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=tools/libfsimage/common/mapfile-GNU;h=26d4d7a69ec7bbd0f7f5e48c61ea7eb61c32a2f6;hb=HEAD
>
> BFD seems to accept slightly different format when the version script is
> provided "as just another input file to the linker" mentioned in older
> documentation:
> https://ftp.gnu.org/old-gnu/Manuals/ld-2.9.1/html_node/ld_25.html
> https://sourceware.org/binutils/docs/ld/VERSION.html
>
> and when passed with --version-script, when bfd complains about the
> syntax exactly like gold does:
>
> with gold:
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-GNU:2:20: syntax error, unexpected '{', expecting ';'
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: fatal error: unable to parse version script file mapfile-GNU
> collect2: error: ld returned 1 exit status
>
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-GNU:1:9: invalid use of VERSION in input file
> collect2: error: ld returned 1 exit status
>
> with -fuse-ld=bfd:
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd
>
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld.bfd:mapfile-GNU:2: syntax error in VERSION script
> collect2: error: ld returned 1 exit status
>
> both bfd and gold will happily accept the mapfile-SunOS version of this file:
> http://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=tools/libfsimage/common/mapfile-SunOS;h=e99b90b65077f9e0e6082e7d2d1fa5aa55e3af7b;hb=HEAD
> in --version-script param:
>
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd
>
> and both will fail without --version-script:
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld.bfd:mapfile-SunOS: file format not recognized; treating as linker script
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld.bfd:mapfile-SunOS:1: syntax error
> collect2: error: ld returned 1 exit status
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-SunOS:1:19: syntax error, unexpected '{'
> /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-SunOS: not an object or archive
> collect2: error: ld returned 1 exit status
>
> Unfortunatelly this isn't the only issue with gold in xen-tools, for qemux86-64 it still fails with:
>
> x86_64-oe-linux-ld --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                                     -melf_x86_64 -melf_x86_64        -melf_x86_64  -T xen.lds -N prelink.o --build-id=sha1 \
>     /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/common/symbols-dummy.o -o /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/.xen-syms.0
> x86_64-oe-linux-ld: error: xen.lds:66:47: syntax error, unexpected '-', expecting ')'
> x86_64-oe-linux-ld: fatal error: unable to parse script file xen.lds
>
> Which is also reproducible only with gold and bfd is happy:
> WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/arch/x86$ x86_64-oe-linux-ld.bfd --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                                     -melf_x86_64 -melf_x86_64        -melf_x86_64  -T xen.lds -N prelink.o --build-id=sha1 /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/common/symbols-dummy.o -o /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/.xen-syms.0
>
> adding:
> echo 'LDFLAGS += "-fuse-ld=bfd"' >> "${S}/tools/libfsimage/Rules.mk"
> in xen-tools.inc:do_configure works for qemux86, but not for qemux86-64.
>
> Feel free to improve it or fix it properly (but with linux kernel also preventing to use gold now it might not be worth spending extra time on gold).

Thanks for the extended details on this. I am interested in pursuing
the full fix but am unclear on my timing for being able to get to it,
so will be looking at your suggestions for the more expedient
workarounds first.

Christopher

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686
  2020-03-04 23:05   ` Christopher Clark
@ 2020-03-06 23:52     ` Martin Jansa
  2020-03-12  0:35       ` Christopher Clark
  0 siblings, 1 reply; 8+ messages in thread
From: Martin Jansa @ 2020-03-06 23:52 UTC (permalink / raw)
  To: Christopher Clark; +Cc: meta-virtualization

[-- Attachment #1: Type: text/plain, Size: 10376 bytes --]

On Wed, Mar 04, 2020 at 03:05:48PM -0800, Christopher Clark wrote:
> On Wed, Mar 4, 2020 at 7:30 AM Martin Jansa <Martin.Jansa@gmail.com> wrote:
> >
> > On Tue, Mar 03, 2020 at 03:10:35PM +0100, Martin Jansa via Lists.Yoctoproject.Org wrote:
> > > * let TARGET_VENDOR to be set to something else than the default:
> > >   meta/conf/bitbake.conf:TARGET_VENDOR = "-oe"
> > >   like other architectures use
> > > ---
> > >  recipes-extended/xen/xen-tools.inc | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc
> > > index 8bdbfec..8b86f7b 100644
> > > --- a/recipes-extended/xen/xen-tools.inc
> > > +++ b/recipes-extended/xen/xen-tools.inc
> > > @@ -1,7 +1,7 @@
> > >  SUMMARY = "Xen hypervisor tools"
> > >  DESCRIPTION = "Tools and utility software for the Xen hypervisor"
> > >
> > > -COMPATIBLE_HOST = 'i686-oe-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> > > +COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> > >
> > >  inherit setuptools3 update-rc.d systemd deploy
> > >  require xen-blktap.inc
> >
> > Not really caused by this change, but now when the build can be started
> > it fails for me with:
> > error: mapfile-GNU:1:9: invalid use of VERSION in input file
> > Makefile:52: recipe for target 'libxenfsimage.so.4.12.0' failed
> >
> > Anyone else seeing this? It's actually raspberrypi4 world build, so the
> > COMPATIBLE_HOST above isn't related at all in this case.
> 
> Thanks for the report, Martin. My first pass at repro'ing this did not
> encounter this failure; but this is my first build with raspberrypi4
> MACHINE, so it's possible that my config is different in some way. Are
> you able to give any more guidance on your build configuration to
> reproduce this? (MACHINE, layers and branches, conf file settings -
> eg. enabling reproducible builds)

It's reproducible only with gold, so:
DISTRO_FEATURES_append = " ld-is-gold"
in your local.conf should be able to reproduce it for any MACHINE (I see
it with qemux86 as well).

Easiest work around would be to add -fuse-ld=bfd when building xen-tools
if nobody is interested to fix it properly.

The issue is this file:
http://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=tools/libfsimage/common/mapfile-GNU;h=26d4d7a69ec7bbd0f7f5e48c61ea7eb61c32a2f6;hb=HEAD

BFD seems to accept slightly different format when the version script is
provided "as just another input file to the linker" mentioned in older
documentation:
https://ftp.gnu.org/old-gnu/Manuals/ld-2.9.1/html_node/ld_25.html
https://sourceware.org/binutils/docs/ld/VERSION.html

and when passed with --version-script, when bfd complains about the
syntax exactly like gold does:

with gold:
WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-GNU:2:20: syntax error, unexpected '{', expecting ';'
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: fatal error: unable to parse version script file mapfile-GNU
collect2: error: ld returned 1 exit status

WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-GNU:1:9: invalid use of VERSION in input file
collect2: error: ld returned 1 exit status

with -fuse-ld=bfd:
WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd

WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-GNU -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld.bfd:mapfile-GNU:2: syntax error in VERSION script
collect2: error: ld returned 1 exit status

both bfd and gold will happily accept the mapfile-SunOS version of this file:
http://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=tools/libfsimage/common/mapfile-SunOS;h=e99b90b65077f9e0e6082e7d2d1fa5aa55e3af7b;hb=HEAD
in --version-script param:

WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,--version-script=mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd

and both will fail without --version-script:
WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic -fuse-ld=bfd
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld.bfd:mapfile-SunOS: file format not recognized; treating as linker script
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld.bfd:mapfile-SunOS:1: syntax error
collect2: error: ld returned 1 exit status
WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/libfsimage/common$ arm-oe-linux-gnueabi-gcc  -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7  --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                             -L../common/ -Wl,mapfile-SunOS -pthread -Wl,-soname -Wl,libxenfsimage.so.4.12 -shared -o libxenfsimage.so.4.12.0 fsimage.opic fsimage_plugin.opic fsimage_grub.opic
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-SunOS:1:19: syntax error, unexpected '{'
/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot-native/usr/bin/arm-oe-linux-gnueabi/../../libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/9.2.0/ld: error: mapfile-SunOS: not an object or archive
collect2: error: ld returned 1 exit status

Unfortunatelly this isn't the only issue with gold in xen-tools, for qemux86-64 it still fails with:

x86_64-oe-linux-ld --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                                     -melf_x86_64 -melf_x86_64        -melf_x86_64  -T xen.lds -N prelink.o --build-id=sha1 \
    /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/common/symbols-dummy.o -o /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/.xen-syms.0
x86_64-oe-linux-ld: error: xen.lds:66:47: syntax error, unexpected '-', expecting ')'
x86_64-oe-linux-ld: fatal error: unable to parse script file xen.lds

Which is also reproducible only with gold and bfd is happy:
WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/arch/x86$ x86_64-oe-linux-ld.bfd --sysroot=/WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/recipe-sysroot                                     -melf_x86_64 -melf_x86_64        -melf_x86_64  -T xen.lds -N prelink.o --build-id=sha1 /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/common/symbols-dummy.o -o /WORKDIR/xen-tools/4.12+gitAUTOINC+a5fcafbfbe-r0/git/tools/firmware/xen-dir/xen-root/xen/.xen-syms.0

adding:
echo 'LDFLAGS += "-fuse-ld=bfd"' >> "${S}/tools/libfsimage/Rules.mk"
in xen-tools.inc:do_configure works for qemux86, but not for qemux86-64.

Feel free to improve it or fix it properly (but with linux kernel also preventing to use gold now it might not be worth spending extra time on gold).

Cheers,

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 201 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686
  2020-03-04 15:29 ` Martin Jansa
@ 2020-03-04 23:05   ` Christopher Clark
  2020-03-06 23:52     ` Martin Jansa
  0 siblings, 1 reply; 8+ messages in thread
From: Christopher Clark @ 2020-03-04 23:05 UTC (permalink / raw)
  To: Martin Jansa; +Cc: meta-virtualization

On Wed, Mar 4, 2020 at 7:30 AM Martin Jansa <Martin.Jansa@gmail.com> wrote:
>
> On Tue, Mar 03, 2020 at 03:10:35PM +0100, Martin Jansa via Lists.Yoctoproject.Org wrote:
> > * let TARGET_VENDOR to be set to something else than the default:
> >   meta/conf/bitbake.conf:TARGET_VENDOR = "-oe"
> >   like other architectures use
> > ---
> >  recipes-extended/xen/xen-tools.inc | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc
> > index 8bdbfec..8b86f7b 100644
> > --- a/recipes-extended/xen/xen-tools.inc
> > +++ b/recipes-extended/xen/xen-tools.inc
> > @@ -1,7 +1,7 @@
> >  SUMMARY = "Xen hypervisor tools"
> >  DESCRIPTION = "Tools and utility software for the Xen hypervisor"
> >
> > -COMPATIBLE_HOST = 'i686-oe-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> > +COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> >
> >  inherit setuptools3 update-rc.d systemd deploy
> >  require xen-blktap.inc
>
> Not really caused by this change, but now when the build can be started
> it fails for me with:
> error: mapfile-GNU:1:9: invalid use of VERSION in input file
> Makefile:52: recipe for target 'libxenfsimage.so.4.12.0' failed
>
> Anyone else seeing this? It's actually raspberrypi4 world build, so the
> COMPATIBLE_HOST above isn't related at all in this case.

Thanks for the report, Martin. My first pass at repro'ing this did not
encounter this failure; but this is my first build with raspberrypi4
MACHINE, so it's possible that my config is different in some way. Are
you able to give any more guidance on your build configuration to
reproduce this? (MACHINE, layers and branches, conf file settings -
eg. enabling reproducible builds)

Christopher

>
> > --
> > 2.20.1
> >
>
> >
>
> 

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686
       [not found] <15F8D09CD90CE2BE.3586@lists.yoctoproject.org>
@ 2020-03-04 15:29 ` Martin Jansa
  2020-03-04 23:05   ` Christopher Clark
  0 siblings, 1 reply; 8+ messages in thread
From: Martin Jansa @ 2020-03-04 15:29 UTC (permalink / raw)
  To: meta-virtualization

[-- Attachment #1: Type: text/plain, Size: 1346 bytes --]

On Tue, Mar 03, 2020 at 03:10:35PM +0100, Martin Jansa via Lists.Yoctoproject.Org wrote:
> * let TARGET_VENDOR to be set to something else than the default:
>   meta/conf/bitbake.conf:TARGET_VENDOR = "-oe"
>   like other architectures use
> ---
>  recipes-extended/xen/xen-tools.inc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc
> index 8bdbfec..8b86f7b 100644
> --- a/recipes-extended/xen/xen-tools.inc
> +++ b/recipes-extended/xen/xen-tools.inc
> @@ -1,7 +1,7 @@
>  SUMMARY = "Xen hypervisor tools"
>  DESCRIPTION = "Tools and utility software for the Xen hypervisor"
>
> -COMPATIBLE_HOST = 'i686-oe-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
> +COMPATIBLE_HOST = 'i686-.*-linux|(x86_64.*).*-linux|aarch64.*-linux|arm-.*-linux-gnueabi'
>
>  inherit setuptools3 update-rc.d systemd deploy
>  require xen-blktap.inc

Not really caused by this change, but now when the build can be started
it fails for me with:
error: mapfile-GNU:1:9: invalid use of VERSION in input file
Makefile:52: recipe for target 'libxenfsimage.so.4.12.0' failed

Anyone else seeing this? It's actually raspberrypi4 world build, so the
COMPATIBLE_HOST above isn't related at all in this case.

> -- 
> 2.20.1
> 

> 


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 201 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-03-12  0:36 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-03 14:10 [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686 Martin Jansa
2020-03-03 14:10 ` [meta-virtualization][PATCH 2/2] xen-python2: add the same COMPATIBLE_HOST restriction as xen-tools Martin Jansa
2020-03-09 17:25   ` Christopher Clark
2020-03-04  1:03 ` [meta-virtualization][PATCH 1/2] xen-tools: fix COMPATIBLE_HOST restriction for i686 Bruce Ashfield
     [not found] <15F8D09CD90CE2BE.3586@lists.yoctoproject.org>
2020-03-04 15:29 ` Martin Jansa
2020-03-04 23:05   ` Christopher Clark
2020-03-06 23:52     ` Martin Jansa
2020-03-12  0:35       ` Christopher Clark

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.