Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1FqGo2-0002vg-0D for mharc-grub-devel@gnu.org; Tue, 13 Jun 2006 17:52:14 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FqGo0-0002te-De for grub-devel@gnu.org; Tue, 13 Jun 2006 17:52:12 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FqGny-0002ql-2F for grub-devel@gnu.org; Tue, 13 Jun 2006 17:52:11 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FqGnx-0002qb-Sl for grub-devel@gnu.org; Tue, 13 Jun 2006 17:52:09 -0400 Received: from [207.152.70.127] (helo=baz.foobar-qux.org) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1FqGwz-0005gL-Ei for grub-devel@gnu.org; Tue, 13 Jun 2006 18:01:29 -0400 Received: from baz.foobar-qux.org (localhost.foobar-qux.org [127.0.0.1]) by baz.foobar-qux.org (8.13.3/8.13.3) with ESMTP id k5DLq6mZ055323 for ; Tue, 13 Jun 2006 16:52:06 -0500 (CDT) (envelope-from hde@foobar-qux.org) Received: (from hde@localhost) by baz.foobar-qux.org (8.13.3/8.13.3/Submit) id k5DLq54Y055318; Tue, 13 Jun 2006 16:52:05 -0500 (CDT) (envelope-from hde@foobar-qux.org) X-Authentication-Warning: baz.foobar-qux.org: hde set sender to hde@foobar-qux.org using -f Sender: hde@baz.foobar-qux.org Mail-Copies-To: hde@gnu.org To: The development of GRUB 2 References: <868xo2tmpl.fsf@baz.foobar-qux.org> <200606132001.34248.okuji@enbug.org> From: hde@foobar-qux.org (Harley D. Eades III) Date: 13 Jun 2006 16:52:04 -0500 In-Reply-To: <200606132001.34248.okuji@enbug.org> Message-ID: <86r71sraez.fsf@baz.foobar-qux.org> User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Re: Patch for successful compilation on FreeBSD Release-6.1 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Jun 2006 21:52:12 -0000 "Yoshinori K. Okuji" writes: > On Monday 12 June 2006 17:31, Harley D. Eades III wrote: > > --- grub2/configure.ac Sun Jun 11 17:49:23 2006 > > +++ grub2Hacked/configure.ac Sun Jun 11 17:55:34 2006 > > @@ -121,6 +121,15 @@ > > AC_CHECK_SIZEOF(void *) > > AC_CHECK_SIZEOF(long) > > > > +# BSD checks. > > +AC_CHECK_HEADER([malloc.h], > > + [AC_DEFINE(HAVE_MALLOC_H, [], > > + [Define to 1 if you have the malloc.h header file.])], > > ,) > > + > > Please use AC_CHECK_HEADERS instead. Usually, you don't have to use > AC_CHECK_HEADER. See the autoconf manual for more details. ok > > > +AC_CHECK_FUNC([memalign], > > + [AC_DEFINE(HAVE_MEMALIGN, [], > > + [Define to 1 if you have the memalign function.])], ,) > > + ok > Likewise, please use AC_CHECK_FUNCS instead. > > > --- grub2/include/grub/util/misc.h Mon Feb 14 18:07:01 2005 > > +++ grub2Hacked/include/grub/util/misc.h Mon Jun 5 15:25:38 > > 2006 > > @@ -23,6 +23,7 @@ > > #include > > #include > > #include > > +#include > > Can you tell me why it is necessary to include unistd.h here? off_t is defined here on FreeBSD. > > --- grub2/util/grub-emu.c Wed Apr 26 16:58:36 2006 > > +++ grub2Hacked/util/grub-emu.c Mon Jun 5 15:26:30 2006 > > @@ -18,7 +18,11 @@ > > */ > > > > #include > > + > > +#ifdef HAVE_MALLOC_H > > #include > > +#endif > > + > > I don't know why it is necessary to include malloc.h. IIRC, FreeBSD does not > use malloc.h since 4.2 or something. In fact, other projects, such as KDE, > stop including malloc.h in all platforms. Can you elaborate on this change? I am not adding the include. All I added was the #if statement so this is not included on FreeBSD. So you are correct about the header file not being used on FreeBSD, because it's not. :) IIRC, GNU/Linux does define memalign in malloc.h though, so this could be the reason it has been included already. Cheers Harley