From: "Yoshinori K. Okuji" <okuji@enbug.org>
To: The development of GRUB 2 <grub-devel@gnu.org>
Subject: Re: Grub2 on Mac OS X
Date: Sat, 26 Mar 2005 01:22:10 +0100 [thread overview]
Message-ID: <200503260122.10488.okuji@enbug.org> (raw)
In-Reply-To: <1111616923.4241ed9b706fe@imp5-q.free.fr>
On Wednesday 23 March 2005 11:28 pm, Antoine Terrienne wrote:
> Should be possible I'll take a look. But in most cases i found on the web
> malloc is a good subtitute to memalign.
But you must still check if a pointer returned by malloc is aligned correctly.
> I agree argp is techically superior but adding a library in Grub2 mean
> keeping it up-to-date with the mainstream distribution. This add a little
> anoyng work just to add some functionalities that aren't used. If you
> really want to add it I can do it but I'm not sure it is necessary.
Necessary. It is not a big burden anyway.
> I found another glibc specific function : alloca. Used in cmain in
> boot/powerpc/ieee1275/cmain.c. I repace it by declaring argv as an array of
> 64 elements : char *arg[64] (should be enouth ?). As the variables are
> allocated in the stack just like alloca do it should work just the same.
This kind of functions should be complemented by a library. Look at Gnulib:
http://www.gnu.org/software/gnulib/
I think Gnulib contains argp as well.
> I have another question about -DGRUB_UTIL. Can it be used to distinguish
> the host compiled part and the build compiled part of grub ?
> I have to handle types differenty in host and build as the build part
> doesn't have stdlib.h. But this method fails on
> boot/powerpc/ieee1275/cmain.c that is compiled with powerpc-elf-gcc (build)
> and the -DGRUB_UTIL flag.
I don't understand. Why is stdlib.h related to types?
Okuji
next prev parent reply other threads:[~2005-03-26 0:39 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-23 13:20 Grub2 on Mac OS X antoine terrienne
2005-03-23 20:45 ` Yoshinori K. Okuji
2005-03-23 22:28 ` Antoine Terrienne
2005-03-26 0:22 ` Yoshinori K. Okuji [this message]
2005-03-26 12:09 ` Antoine Terrienne
2005-03-26 13:52 ` Marco Gerards
2005-03-26 14:55 ` Antoine Terrienne
2005-03-26 15:20 ` Marco Gerards
2005-03-26 19:49 ` Antoine Terrienne
2005-03-26 20:09 ` Marco Gerards
2005-03-26 13:40 ` Marco Gerards
-- strict thread matches above, loose matches on Subject: below --
2005-03-21 18:55 Antoine Terrienne
2005-03-22 20:20 ` Yoshinori K. Okuji
2005-03-23 20:42 ` Brian Sammon
2005-03-23 21:09 ` Yoshinori K. Okuji
2005-03-26 13:37 ` Marco Gerards
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=200503260122.10488.okuji@enbug.org \
--to=okuji@enbug.org \
--cc=grub-devel@gnu.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.