From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1JhVYc-0008TC-JN for mharc-grub-devel@gnu.org; Thu, 03 Apr 2008 15:57:10 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JhVYa-0008So-La for grub-devel@gnu.org; Thu, 03 Apr 2008 15:57:08 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JhVYY-0008SP-8j for grub-devel@gnu.org; Thu, 03 Apr 2008 15:57:07 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JhVYY-0008SE-0l for grub-devel@gnu.org; Thu, 03 Apr 2008 15:57:06 -0400 Received: from mailout06.t-online.de ([194.25.134.19]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JhVYX-0007wX-Lx for grub-devel@gnu.org; Thu, 03 Apr 2008 15:57:05 -0400 Received: from fwd28.aul.t-online.de by mailout06.sul.t-online.de with smtp id 1JhVYT-0002eF-01; Thu, 03 Apr 2008 21:57:01 +0200 Received: from [10.3.2.2] (Tz5MEsZbohIBmnq-c5HoKA7tl+sqakEggc0bg1ibsaxA+zHhMm5IBF3d0hEPOMdZmS@[217.235.217.139]) by fwd28.aul.t-online.de with esmtp id 1JhVYL-1ThXCy0; Thu, 3 Apr 2008 21:56:53 +0200 Message-ID: <47F53689.30307@t-online.de> Date: Thu, 03 Apr 2008 21:56:57 +0200 From: Christian Franke User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.11) Gecko/20071128 SeaMonkey/1.1.7 MIME-Version: 1.0 To: The development of GRUB 2 References: <1JhPUa-0XNW4m0@fwd35.aul.t-online.de> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-ID: Tz5MEsZbohIBmnq-c5HoKA7tl+sqakEggc0bg1ibsaxA+zHhMm5IBF3d0hEPOMdZmS X-TOI-MSGID: 9e1f335a-2829-4595-9f23-5a4f56d9c779 X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) Subject: Re: [PATCH] grub2 for Cygwin 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: Thu, 03 Apr 2008 19:57:08 -0000 Bean wrote: > On Thu, Apr 3, 2008 at 9:28 PM, Christian Franke > wrote: > >> ... >> The cygwin distro does not include any cross compilation tools. A >> package that require tools not in the distro would not be accepted. >> >> The package is actually build with native cygwin gcc+binutils. >> >> The related discussion+patches are already on this list, e.g: >> http://lists.gnu.org/archive/html/grub-devel/2007-11/msg00238.html >> http://lists.gnu.org/archive/html/grub-devel/2007-11/msg00237.html >> http://lists.gnu.org/archive/html/grub-devel/2007-11/msg00174.html >> http://lists.gnu.org/archive/html/grub-devel/2007-11/msg00161.html >> http://lists.gnu.org/archive/html/grub-devel/2007-11/msg00160.html >> > > It seems you have spent a lot of effect to make it work, but some > trick is not very appealing. Which trick in particular is not appealing ? The external linker script will be necessary also on other platforms where the builtin "ld -N" script does not work as expected. The hack in the loader is ugly, but was necessary to undo a hack in the PE backend of libbfd. Here the diffstat for the cygwin changes based on the "-D 2008-03-27" CVS release: Makefile.in | 4 + aclocal.m4 | 18 +++++ conf/i386-pc-cygwin-img-ld.sc | 53 +++++++++++++++ conf/i386-pc.rmk | 12 +-- configure.ac | 37 +++++++++++ genkernsyms.sh.in | 7 +- genmk.rb | 8 +- gensymlist.sh.in | 6 + include/grub/dl.h | 5 - include/grub/symbol.h | 6 + kern/dl.c | 40 +++++++++-- kern/i386/dl.c | 30 ++++++++ util/biosdisk.c | 34 +++++++--- util/getroot.c | 141 +++++++++++++++++++++++++++++++++++++++++- util/grub-mkdevicemap.c | 19 ++++- util/grub-probe.c | 25 ++++++- util/i386/pc/grub-install.in | 8 +- util/update-grub.in | 25 +++++-- util/update-grub_lib.in | 22 +----- 19 files changed, 436 insertions(+), 64 deletions(-) These are IMO not so much changes for a rather different platform without native ELF support. > I personally don't mind, but I don't know > if it can be accepted by others. > OK, if there is no chance to get this accepted, grub2 project managers should tell me soon. It does not make much sense to spent time sending cygwin releated patches upstream, when all these are eventually rejected. > ... > Can you make it work with mingw, for example, use the -mno-cygwin compile flag ? > > I have not planned to do this in the near future. Of course, it is possible, but there are more issues to solve: No /dev/... device support, no native shell script support, CR/LF issues, ... And: The PE->elf conversion problem will remain. So a backward compatible fix for mingw would likely be much less appealing than the one for cygwin :-) The cygwin port of grub2 is targeted to users who want a *n[iu]x environment, but (have to) use Windows as main work OS for whatever reason. They likely have already installed cygwin :-) Christian