public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Anthony Liguori <anthony@codemonkey.ws>
To: Jerone Young <jyoung5@us.ibm.com>
Cc: kvm-devel@lists.sourceforge.net,
	kvm-ppc-devel@lists.sourceforge.net, hollisb@us.ibm.com
Subject: Re: [PATCH 1 of 4] Add "make sync" to sync need kernel headers to	kvm-userspace
Date: Mon, 14 Apr 2008 09:18:39 -0500	[thread overview]
Message-ID: <480367BF.3000305@codemonkey.ws> (raw)
In-Reply-To: <5b1798e467ce791db9ae.1208162224@thinkpadL>

Jerone Young wrote:
> 2 files changed, 25 insertions(+), 4 deletions(-)
> Makefile  |   21 ++++++++++++++++++++-
> configure |    8 +++++---
>
>
> This patch adds ability for kvm-userspace build system to sync needed kernel headers locally without the need of compiled kernel source.
>   

make sync in kernel/ already does this.  Why not just add PPC support there.

Regards,

Anthony Liguori

> Signed-off-by: Jerone Young <jyoung5@us.ibm.com>
>
> diff --git a/Makefile b/Makefile
> --- a/Makefile
> +++ b/Makefile
> @@ -7,7 +7,7 @@ rpmrelease = devel
>  
>  .PHONY: kernel user libkvm qemu bios vgabios extboot clean libfdt
>  
> -all: libkvm qemu
> +all: sync libkvm qemu
>  ifneq '$(filter $(ARCH), x86_64 i386 ia64)' ''
>      all: $(if $(WANT_MODULE), kernel) user
>  endif
> @@ -69,6 +69,24 @@ install:
>  	make -C libkvm DESTDIR="$(DESTDIR)" install
>  	make -C qemu DESTDIR="$(DESTDIR)" install
>  
> +
> +ASM_DIR=$(ARCH)
> +ifneq '$(filter $(ARCH), i386 x86_64)' ''
> +	ASM_DIR=x86
> +endif
> +
> +sync:
> +	mkdir -p $(INCLUDES_DIR)
> +	mkdir -p $(INCLUDES_DIR)/asm-$(ASM_DIR)
> +	mkdir -p $(INCLUDES_DIR)/linux
> +	cp -f $(KERNELDIR)/include/asm-$(ASM_DIR)/kvm*.h \
> +		$(INCLUDES_DIR)/asm-$(ASM_DIR)/
> +	cp -f $(KERNELDIR)/include/linux/kvm*.h \
> +		$(KERNELDIR)/include/linux/compiler*.h \
> +		$(INCLUDES_DIR)/linux
> +	ln -sf  $(INCLUDES_DIR)/asm-$(ASM_DIR) $(INCLUDES_DIR)/asm
> +
> +
>  tmpspec = .tmp.kvm.spec
>  RPMTOPDIR = $$(pwd)/rpmtop
>  
> @@ -99,3 +117,4 @@ clean:
>  
>  distclean: clean
>  	rm -f config.mak user/config.mak
> +	rm -rf $(INCLUDES_DIR)
> diff --git a/configure b/configure
> --- a/configure
> +++ b/configure
> @@ -10,6 +10,7 @@ cross_prefix=
>  cross_prefix=
>  arch=`uname -m`
>  target_exec=
> +local_kernel_includes_dir=$PWD/includes
>  
>  usage() {
>      cat <<-EOF
> @@ -108,16 +109,16 @@ fi
>  fi
>  
>  #configure user dir
> -(cd user; ./configure --prefix="$prefix" --kerneldir="$libkvm_kerneldir" \
> +(cd user; ./configure --prefix="$prefix" \
>            --arch="$arch" \
>            ${cross_prefix:+"--cross-prefix=$cross_prefix"})
>  
>  #configure qemu
>  (cd qemu; ./configure --target-list=$target_exec \
>      --disable-kqemu \
> -    --extra-cflags="-I $PWD/../libkvm $qemu_cflags" \
> +    --extra-cflags="-I $PWD/../libkvm $qemu_cflags \
> +               -I $local_kernel_includes_dir" \
>      --extra-ldflags="-L $PWD/../libkvm $qemu_ldflags" \
> -    --kernel-path="$libkvm_kerneldir" \
>      --prefix="$prefix" \
>      ${qemu_cc:+"--cc=$qemu_cc"} \
>      ${cross_prefix:+"--cross-prefix=$cross_prefix"} \
> @@ -131,4 +132,5 @@ KERNELDIR=$kerneldir
>  KERNELDIR=$kerneldir
>  WANT_MODULE=$want_module
>  CROSS_COMPILE=$cross_prefix
> +INCLUDES_DIR=$local_kernel_includes_dir
>  EOF
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
> Don't miss this year's exciting event. There's still time to save $100. 
> Use priority code J8TL2D2. 
> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
> _______________________________________________
> kvm-devel mailing list
> kvm-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/kvm-devel
>   


-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

  parent reply	other threads:[~2008-04-14 14:18 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-14  8:37 [PATCH 0 of 4] Sync kernel headers to kvm-userspace Jerone Young
2008-04-14  8:37 ` [PATCH 1 of 4] Add "make sync" to sync need " Jerone Young
2008-04-14  8:50   ` Christoph Hellwig
2008-04-14 11:47     ` Avi Kivity
2008-04-14 11:54       ` Christoph Hellwig
2008-04-14 12:04         ` Avi Kivity
2008-04-14 14:23           ` Anthony Liguori
2008-04-14 14:43             ` Avi Kivity
2008-04-14 14:20     ` Anthony Liguori
2008-04-14 14:18   ` Anthony Liguori [this message]
2008-04-15  7:29   ` Avi Kivity
2008-04-14  8:37 ` [PATCH 2 of 4] Fix libfdt to include synced headers Jerone Young
2008-04-14  8:37 ` [PATCH 3 of 4] Fix user to include synced headers & remove kerneldir option Jerone Young
2008-04-14  8:37 ` [PATCH 4 of 4] Remove kvm kernel-path option from qemu Jerone Young
2008-04-15  8:38   ` Avi Kivity

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=480367BF.3000305@codemonkey.ws \
    --to=anthony@codemonkey.ws \
    --cc=hollisb@us.ibm.com \
    --cc=jyoung5@us.ibm.com \
    --cc=kvm-devel@lists.sourceforge.net \
    --cc=kvm-ppc-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox