WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-ia64-devel] cross compiling xen/ia64

To: Alex Williamson <alex.williamson@xxxxxx>
Subject: Re: [Xen-ia64-devel] cross compiling xen/ia64
From: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Date: Mon, 16 Jun 2008 16:22:37 +0100
Cc: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, Keir Fraser <keir@xxxxxxxxxxxxx>, xen-ia64-devel <xen-ia64-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Mon, 16 Jun 2008 08:23:23 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <m2n.s.1JWJRb-000DP2@xxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Newsgroups: chiark.mail.xen.ia64.devel
References: <m2n.s.1JWJRb-000DP2@xxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
Alex Williamson writes ("[Xen-ia64-devel] cross compiling xen/ia64"):
>    With the latest pull of the ia64 tree, it's now possible, and fairly
> easy, to cross compile xen/ia64 on an x86_32/64 system.  Aron Griffis
> has been working on this and has posted detailed instructions on the Xen
> wiki: http://wiki.xensource.com/xenwiki/CrossCompiling  These
> instructions are based on Fedora8, which should be readily available.

I've been looking into this, and with Isaku Yamahata's patch the
hypervisor does build.  I'm hoping we can get that wired into the
staging propagation system very soon.  (Sorry about the delay getting
round to this.)

However, neither the kernel nor the tools build for me.

The kernel build stops asking for a kernel config option:

  mariner:xen-unstable-2.hg> PATH=/usr/local/ia64/bin:$PATH make 
XEN_TARGET_ARCH=ia64 CROSS_COMPILE=ia64-linux-gnu- -j4 dist-kernels
  for i in  linux-2.6-xen  ; do make $i-install || exit 1; done
  ...
  *
  Xen hypervisor support (XEN) [Y/n/?] y
    Xen/IA64 exposure p2m table (XEN_IA64_EXPOSE_P2M) [Y/n/?] (NEW) 

Obviously that's no good for an automatic test system.

The tools build stops with some kind of linker exec format problem
which I admit I don't understand and haven't investigated:

  mariner:xen-unstable-2.hg> PATH=/usr/local/ia64/bin:$PATH make 
XEN_TARGET_ARCH=ia64 CROSS_COMPILE=ia64-linux-gnu- -j4 dist-tools
  make -C tools install
  ...
  make[5]: Entering directory `/u/iwj/work/xen-unstable-2.hg/tools/blktap/lib'
  ia64-linux-gnu-gcc -O2 -fomit-frame-pointer -fno-strict-aliasing -std=gnu99 
-Wall -Wstrict-prototypes -Wno-unused-value -Wdeclaration-after-statement  
-D__XEN_TOOLS__ -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE 
-D_LARGEFILE64_SOURCE  -I. -I../../../tools/libxc -I../../../tools/include 
-I../../../tools/xenstore -I../../../tools/include -Werror -Wno-unused -fPIC -D 
_GNU_SOURCE -Wp,-MD,.libblktap.so.3.0.0.d -Wl,-soname -Wl,libblktap.so.3.0 
-shared \
                   -L../../../tools/xenstore -lxenstore -o libblktap.so.3.0.0 
xenbus.opic blkif.opic xs_api.opic
  
/usr/local/ia64/lib/gcc/ia64-linux-gnu/4.1.1/../../../../ia64-linux-gnu/bin/ld: 
xenbus.opic: Relocations in generic ELF (EM: 3)
  
/usr/local/ia64/lib/gcc/ia64-linux-gnu/4.1.1/../../../../ia64-linux-gnu/bin/ld: 
xenbus.opic: Relocations in generic ELF (EM: 3)
  xenbus.opic: could not read symbols: File in wrong format
  collect2: ld returned 1 exit status
  make[5]: *** [libblktap.so.3.0.0] Error 1
  make[5]: Leaving directory `/u/iwj/work/xen-unstable-2.hg/tools/blktap/lib'

This may be some problem with my cross building installation.  I built
it roughly following the instructions on the wiki.  I used the
prebuilt ia64 sys-root and did a single-stage build of binutils 2.17
and gcc-4.1.1 with the following runes:

After unpacking the sysroot and mkaing a link to it at
/usr/ia64-linux-gnu/sys-root:

  cd binutils-2.17/
  ./configure --with-sysroot=/usr/ia64-linux-gnu/sys-root 
--target=ia64-linux-gnu --prefix=/usr/local/ia64
  PATH=/usr/local/ia64/bin:$PATH make -j4
  PATH=/usr/local/ia64/bin:$PATH make install
  cd ..

  cd gcc-4.1.1/
  ./configure --with-sysroot=/usr/ia64-linux-gnu/sys-root 
--with-headers=/usr/ia64-linux-gnu/sys-root/usr/include --target=ia64-linux-gnu 
--prefix=/usr/local/ia64 --enable-languages=c
  PATH=/usr/local/ia64/bin:$PATH make -j4
  PATH=/usr/local/ia64/bin:$PATH make install

Ian.

_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel