From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH] fix include paths when the kernel source and build directory are different Date: Mon, 08 Jun 2009 12:33:49 +0300 Message-ID: <4A2CDAFD.2000801@redhat.com> References: <20090603125840.GA16209@dupont.ts-a> <4A2CCEDD.6000006@redhat.com> <4A2CD414.2030401@siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: James Pike , kvm@vger.kernel.org To: Jan Kiszka Return-path: Received: from mx2.redhat.com ([66.187.237.31]:58124 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751003AbZFHJdv (ORCPT ); Mon, 8 Jun 2009 05:33:51 -0400 In-Reply-To: <4A2CD414.2030401@siemens.com> Sender: kvm-owner@vger.kernel.org List-ID: Jan Kiszka wrote: > Avi Kivity wrote: > >> James Pike wrote: >> >>> Use correct architecture includes when kernel source and build directory >>> are different. >>> Signed-off-by: James Pike >>> --- a/Makefile >>> +++ b/Makefile >>> @@ -27,8 +27,9 @@ all:: prerequisite >>> # include header priority 1) $LINUX 2) $KERNELDIR 3) include-compat >>> $(MAKE) -C $(KERNELDIR) M=`pwd` \ >>> LINUXINCLUDE="-I`pwd`/include -Iinclude \ >>> - $(if $(KERNELSOURCEDIR),-Iinclude2 >>> -I$(KERNELSOURCEDIR)/include) \ >>> - -Iarch/${ARCH_DIR}/include -I`pwd`/include-compat \ >>> + $(if $(KERNELSOURCEDIR),\ >>> + -Iinclude2 -I$(KERNELSOURCEDIR)/include >>> -I$(KERNELSOURCEDIR)/arch/${ARCH_DIR}/include, \ >>> + -Iarch/${ARCH_DIR}/include) -I`pwd`/include-compat \ >>> -include include/linux/autoconf.h \ >>> -include `pwd`/$(ARCH_DIR)/external-module-compat.h >>> $(module_defines)" \ >>> "$$@" >>> >>> >> This removes -Iarch/${ARCH_DIR}/include when KERNELSOURCEDIR is not >> defined. What is the reason for this change? >> >> > > As far as I can see (I do wear my glasses today...), > -Iarch/${ARCH_DIR}/include is present in the else part of $(if). > Yeah, I missed the comma. Maybe I need to visit your optometrist. > The reason for this change is the missing arch include from the source > directory in case it's separate from the build dir (yeah, the changelog > has room for improvements). > > I ran into the same issue after building and installing a recent kernel > tree with O=. The split trees SUSE leaves behind do not suffer from > this, but they also still work after the change. Same for classic > unified trees. > Okay, will apply the patch. -- error compiling committee.c: too many arguments to function