[ovs-discuss] config/build errors with 2.6.33

Brandon Heller brandonh at stanford.edu
Tue Mar 23 19:07:04 UTC 2010


Hi Ben,

This works on my system and is much cleaner.  Thanks!

-Brandon

On Tue, Mar 23, 2010 at 9:29 AM, Ben Pfaff <blp at nicira.com> wrote:

> On Tue, Mar 23, 2010 at 01:50:52AM -0700, Brandon Heller wrote:
> > I had some trouble configuring and building OVS with a custom 2.6.33
> kernel.
> >  Ugly workaround patch below, which should really use a greater-than
> > comparison in Makefile.main.in.  Somewhere after 2.6.29 autconf.h moved
> > from include/linux to /include/generated.
> >
> > The patch descends from commit 973eab32 (yesterday's OVS master branch).
>
> Thank you for the report.
>
> I think it's easier to just look for the file in both places.  This
> works for me on 2.6.32 and 2.6.33 (and presumably other versions):
>
> --8<--------------------------cut here-------------------------->8--
>
> >From 0ccd7844bbe9f6014d162c573e796c8c6f3f707b Mon Sep 17 00:00:00 2001
> From: Ben Pfaff <blp at nicira.com>
> Date: Tue, 23 Mar 2010 09:27:08 -0700
> Subject: [PATCH] datapath: Support 2.6.33 kernel layout in build system.
>
> The 2.6.33 kernel moves generated header files to include/generated, so
> we need to look for autoconf.h there.
>
> Reported-by: Brandon Heller <brandonh at stanford.edu>
> ---
>  acinclude.m4                        |    5 +++--
>  datapath/linux-2.6/Makefile.main.in |    7 +++++--
>  2 files changed, 8 insertions(+), 4 deletions(-)
>
> diff --git a/acinclude.m4 b/acinclude.m4
> index e38676f..abbc57e 100644
> --- a/acinclude.m4
> +++ b/acinclude.m4
> @@ -70,8 +70,9 @@ AC_DEFUN([OVS_CHECK_LINUX26], [
>          AC_ERROR([Linux kernel in build tree $KBUILD26 (source tree
> $KSRC26) is not version 2.6])
>         fi
>     fi
> -    if ! test -e "$KBUILD26"/include/linux/version.h || \
> -       ! test -e "$KBUILD26"/include/linux/autoconf.h; then
> +    if test ! -e "$KBUILD26"/include/linux/version.h || \
> +       (test ! -e "$KBUILD26"/include/linux/autoconf.h && \
> +        test ! -e "$KBUILD26"/include/generated/autoconf.h); then
>        AC_MSG_ERROR([Linux kernel source in $KBUILD26 is not configured])
>     fi
>      OVS_CHECK_LINUX26_COMPAT
> diff --git a/datapath/linux-2.6/Makefile.main.in b/datapath/linux-2.6/
> Makefile.main.in
> index fd231e6..cb2a042 100644
> --- a/datapath/linux-2.6/Makefile.main.in
> +++ b/datapath/linux-2.6/Makefile.main.in
> @@ -42,9 +42,12 @@ ifeq (,$(wildcard $(VERSION_FILE)))
>    $(error Linux kernel source not configured - missing version.h)
>  endif
>
> -CONFIG_FILE := $(KSRC)/include/linux/autoconf.h
> +CONFIG_FILE := $(KSRC)/include/generated/autoconf.h
>  ifeq (,$(wildcard $(CONFIG_FILE)))
> -  $(error Linux kernel source not configured - missing autoconf.h)
> +  CONFIG_FILE := $(KSRC)/include/linux/autoconf.h
> +  ifeq (,$(wildcard $(CONFIG_FILE)))
> +    $(error Linux kernel source not configured - missing autoconf.h)
> +  endif
>  endif
>
>  default:
> --
> 1.6.6.1
>
>
> _______________________________________________
> discuss mailing list
> discuss at openvswitch.org
> http://openvswitch.org/mailman/listinfo/discuss_openvswitch.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://openvswitch.org/pipermail/ovs-discuss/attachments/20100323/4404acc5/attachment-0001.html>


More information about the discuss mailing list