From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1JK5q3-0000bf-5E for mharc-grub-devel@gnu.org; Wed, 30 Jan 2008 00:50:23 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JK5q1-0000at-4r for grub-devel@gnu.org; Wed, 30 Jan 2008 00:50:21 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JK5pz-0000Zo-JP for grub-devel@gnu.org; Wed, 30 Jan 2008 00:50:19 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JK5pz-0000ZW-0T for grub-devel@gnu.org; Wed, 30 Jan 2008 00:50:19 -0500 Received: from smtp6-g19.free.fr ([212.27.42.36]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JK5py-0001Lh-NX for grub-devel@gnu.org; Wed, 30 Jan 2008 00:50:18 -0500 Received: from smtp6-g19.free.fr (localhost.localdomain [127.0.0.1]) by smtp6-g19.free.fr (Postfix) with ESMTP id 1D1CD5FE34; Wed, 30 Jan 2008 06:50:18 +0100 (CET) Received: from saphi (boi78-1-82-232-198-173.fbx.proxad.net [82.232.198.173]) by smtp6-g19.free.fr (Postfix) with ESMTP id 01BCB5FDD3; Wed, 30 Jan 2008 06:50:18 +0100 (CET) Received: from gingold by saphi with local (Exim 3.36 #1 (Debian)) id 1JK5x0-0001Du-00; Wed, 30 Jan 2008 06:57:34 +0100 Date: Wed, 30 Jan 2008 06:57:34 +0100 To: Marco Gerards Message-ID: <20080130055734.GD4665@saphi> References: <20080128160905.GA2739@saphi> <20080128165504.GB9715@thorin> <20080129051252.GA2504@saphi> <20080129095922.GA31756@thorin> <1201602926.479f016e27f08@imp.free.fr> <20080129113219.GA22894@thorin> <1201611409.479f22918bed6@imp.free.fr> <20080129131934.GB26291@thorin> <871w80adut.fsf@xs4all.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <871w80adut.fsf@xs4all.nl> User-Agent: Mutt/1.5.9i From: Tristan Gingold X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) Cc: tgingold@free.fr, The development of GRUB 2 Subject: Re: IA64 port 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: Wed, 30 Jan 2008 05:50:21 -0000 On Tue, Jan 29, 2008 at 03:46:50PM +0100, Marco Gerards wrote: > Robert suggested some changes. I also noticed in the discussion that > you didn't follow common practise (like an existing grub-mkimage > implementation). Personally, as maintainer, I am against maintaining > two different approaches of the same problem. It costs us time to > maintain this and both case have separate bugs. So I rather see the > code shared, one way or the other. To safe time, it might save you > some work if you initiate a discussion about this. The facts: util/i386/efi/grub-mkimage.c and elf2pe.c do almost the same thing: converting an ELF file to a PE file. But: * the input format is slightly different (Elf32 vs Elf64) * the output format is slightly different (PE vs PE+) * the relocating work is different (x86 vs ia64, Rel vs Rela) * The entry point is a descriptor on ia64 * grub-mkimage.c can insert modules in a section. I propose to extend grub-mkimage.c so that it can handle ia64. I propose to select at compile time which convertion to do through macro (see beginning of elf2pe file to see an example). I don't think it is worth making a generic grub-mkimage binary that can do any convertion: it's too much code duplication. Ok for this approach ? Tristan.