Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S265198AbUFAVYO (ORCPT ); Tue, 1 Jun 2004 17:24:14 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S265237AbUFAVYN (ORCPT ); Tue, 1 Jun 2004 17:24:13 -0400 Received: from aun.it.uu.se ([130.238.12.36]:25730 "EHLO aun.it.uu.se") by vger.kernel.org with ESMTP id S265198AbUFAVYL (ORCPT ); Tue, 1 Jun 2004 17:24:11 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <16572.62455.771001.123286@alkaid.it.uu.se> Date: Tue, 1 Jun 2004 23:24:07 +0200 From: Mikael Pettersson To: Peter Lundkvist Cc: linux-kernel@vger.kernel.org Subject: Re: 2.6.7-rc2-mm1: compile error in kernel/exit.c In-Reply-To: <20040601193545.GA2516@debian> References: <20040601021539.413a7ad7.akpm@osdl.org> <20040601193545.GA2516@debian> X-Mailer: VM 7.17 under Emacs 20.7.1 Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1541 Lines: 42 Peter Lundkvist writes: > Hello, > > When trying to to build with a non-standard setting of HZ > (to get rid of the noise generated by my Dell Inspiron 4000): > --- linux-2.6.7/include/asm-i386/param.h.org 2004-06-01 20:19:03.000000000 +0200 > +++ linux-2.6.7/include/asm-i386/param.h 2004-06-01 20:50:45.000000000 +0200 > @@ -5 +5 @@ > -# define HZ 1000 /* Internal kernel timer frequency */ > +# define HZ 100 /* Internal kernel timer frequency */ > > I get the following error (with current Debian unstable gcc-3.3): > > In file included from kernel/exit.c:18: > include/linux/acct.h:168:2: invalid preprocessing directive #elseif > make[2]: *** [kernel/exit.o] Error 1 > make[1]: *** [kernel] Error 2 > > corrected by this patch: > > --- linux-2.6.7/include/linux/acct.h.org 2004-06-01 20:19:07.000000000 +0200 > +++ linux-2.6.7/include/linux/acct.h 2004-06-01 19:03:43.000000000 +0200 > @@ -166,5 +166,6 @@ > #if HZ == AHZ > /* do nothing */ > -#elseif (HZ % AHZ)==0 > +#else > +#if (HZ % AHZ)==0 > do_div(x, HZ / AHZ); > #else > @@ -172,4 +173,5 @@ > do_div(x, HZ); > #endif > +#endif The correct fix is to s/#elseif/#elif/, not to nest a new #if-#endif pair. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/