From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1MOXx0-0000Cs-Gp for mharc-grub-devel@gnu.org; Wed, 08 Jul 2009 10:16:46 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MOXwy-0000BV-Gs for grub-devel@gnu.org; Wed, 08 Jul 2009 10:16:44 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MOXwt-00007L-DG for grub-devel@gnu.org; Wed, 08 Jul 2009 10:16:43 -0400 Received: from [199.232.76.173] (port=45318 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MOXwt-00006z-7o for grub-devel@gnu.org; Wed, 08 Jul 2009 10:16:39 -0400 Received: from moutng.kundenserver.de ([212.227.17.9]:64751) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MOXws-0000g1-Ny for grub-devel@gnu.org; Wed, 08 Jul 2009 10:16:39 -0400 Received: from [85.180.27.50] (e180027050.adsl.alicedsl.de [85.180.27.50]) by mrelayeu.kundenserver.de (node=mrbap0) with ESMTP (Nemesis) id 0MKsym-1MOXwm3hc0-000ouT; Wed, 08 Jul 2009 16:16:33 +0200 From: Felix Zielcke To: The development of GRUB 2 In-Reply-To: <20090704200908.GA27480@thorin> References: <1241620317.3746.8.camel@fz.local> <1243885166.3417.11.camel@fz.local> <1246458805.3454.1.camel@fz.local> <20090704200908.GA27480@thorin> Content-Type: text/plain Date: Wed, 08 Jul 2009 16:16:33 +0200 Message-Id: <1247062593.10027.0.camel@fz.local> Mime-Version: 1.0 X-Mailer: Evolution 2.26.1.1 Content-Transfer-Encoding: 7bit X-Provags-ID: V01U2FsdGVkX19hUOy4g9heVhdOhFjbAygZ2Bl8Kl0Kus+lrZG oFbvHyO2cPwR/ycbBGnd+cAIKadRAk54bHMz3awAIhbJS22F14 /EoU90x7HxBC/oxMBcvMtVQAcv2j9uK X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Subject: Re: grub-install --root-directory=/mnt /dev/sda1 fails 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, 08 Jul 2009 14:16:44 -0000 Am Samstag, den 04.07.2009, 22:09 +0200 schrieb Robert Millan: > On Wed, Jul 01, 2009 at 04:33:25PM +0200, Felix Zielcke wrote: > > Am Montag, den 01.06.2009, 21:39 +0200 schrieb Felix Zielcke: > > > Am Mittwoch, den 06.05.2009, 17:12 +0200 schrieb Vladimir 'phcoder' > > > Serbinenko: > > > > Don't we already have a function which transforms host directory into > > > > grub > > > > directory? AFAIR we have. > > > > > > There's just the shell function in grub-mkconfig_lib.in > > > Here's now a patch wich implements it in util/hostdisk.c and gets used > > > for core_path_dev in setup (). > > > But it doestn't work with symlinks. > > > readlink () can only be used if the file pointed to is a symlink, not if > > > a symlink is somewhere in between. > > > coreutils where the readlink binary is from is GPL 3+ but the function > > > for it uses hash tables and it seems like it would be too much code to > > > copy just for this. > > > > So what do we do know about this problem? > > We could just assume that the directory given with grub-setup > > --directory is already the real absolute path and just use the stat > > magic to make it relative. > > Or we use realpath() if avaible to get the real one. > > And on systems not having it, like mingw we could just assume that it's > > already relative and just return the path given. > > Or is there some other way this bug can be fixed? > > I just looked into this, and I don't think there's any real problem that > needs fixing. The "workaround" is just a red herring, it works for him by > pure chance. > > See: > > http://savannah.gnu.org/bugs/index.php?26924 I think I tested this and the root device was set correctly, so it looked at the right device for the core.img -- Felix Zielcke