From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1KJWso-0005t7-1v for mharc-grub-devel@gnu.org; Thu, 17 Jul 2008 13:03:10 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KJWsm-0005se-Da for grub-devel@gnu.org; Thu, 17 Jul 2008 13:03:08 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KJWsk-0005s5-Bo for grub-devel@gnu.org; Thu, 17 Jul 2008 13:03:07 -0400 Received: from [199.232.76.173] (port=58996 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KJWsk-0005rn-1L for grub-devel@gnu.org; Thu, 17 Jul 2008 13:03:06 -0400 Received: from ug-out-1314.google.com ([66.249.92.169]:4246) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KJWsj-0001Sj-7w for grub-devel@gnu.org; Thu, 17 Jul 2008 13:03:05 -0400 Received: by ug-out-1314.google.com with SMTP id l31so757289ugc.48 for ; Thu, 17 Jul 2008 10:03:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:subject:from:to:in-reply-to :references:content-type:date:message-id:mime-version:x-mailer; bh=/o6Z1XB5XCF1KI+5un1flFgkQBrdAbLBr9jA7GizJpU=; b=TPxI7M1gloojveq8RZN/FceeBGiiOLGGZSmgOWH388WLxHBWFFpkedUWaiUZxD6zME apl6zr3HoX0+lrbWxuAX2xqemAShtCWD5egUrLx+WxiWJCdF6gIP0gW3IJQMAlmsttW2 vXYD0eOeGMSMJFoY71eVf+SkvITf8eInpe82k= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:from:to:in-reply-to:references:content-type:date:message-id :mime-version:x-mailer; b=ioeph+JGkmcXOxUMFSANNavThtmH5lJpXXgRgk9J32AwT85p4yKtCnbGFC5yNBHKRd +t2aqt/pW1y0/BNsETJRAMMR9rpFHIGC0oPFSphJ/QfRDUF7Eg4djl6WwyxVjzABj3qW mt4D9BRvsLQHxmmw0nXH+JH5CouoUjVxhaYGg= Received: by 10.66.248.5 with SMTP id v5mr4044539ugh.76.1216314183861; Thu, 17 Jul 2008 10:03:03 -0700 (PDT) Received: from ?192.168.1.100? ( [213.37.137.93]) by mx.google.com with ESMTPS id 30sm14502785ugf.63.2008.07.17.10.02.56 (version=SSLv3 cipher=RC4-MD5); Thu, 17 Jul 2008 10:02:57 -0700 (PDT) From: Javier =?ISO-8859-1?Q?Mart=EDn?= To: The development of GRUB 2 In-Reply-To: <1216313442.16120.29.camel@dv> References: <1216313442.16120.29.camel@dv> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-LU0TVfhtcvvmX2eLD2bW" Date: Thu, 17 Jul 2008 19:03:18 +0200 Message-Id: <1216314198.21767.36.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.22.3.1 X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 2) Subject: Re: [PATCH] Simplify target and platform checks 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, 17 Jul 2008 17:03:08 -0000 --=-LU0TVfhtcvvmX2eLD2bW Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable El jue, 17-07-2008 a las 12:50 -0400, Pavel Roskin escribi=C3=B3: > ChangeLog: >=20 > * configure.ac: Default to efi platform for x86_64-apple. Allow > powerpc64 CPU, default to ieee1275 platform for it. Split CPU > adjustments from the rest, only do them if target is not > explicitly given. Merge other adjustments with the final sanity > check. Remove an extraneous check for supported CPU. Be > specific which CPU and which platform is not supported. >=20 > Index: configure.ac > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- configure.ac (revision 1716) > +++ configure.ac (working copy) > @@ -61,46 +61,37 @@ > case "$target_cpu"-"$target_vendor" in > i386-apple) platform=3Defi ;; > i386-*) platform=3Dpc ;; > + x86_64-apple) platform=3Defi ;; > x86_64-*) platform=3Dpc ;; > powerpc-*) platform=3Dieee1275 ;; > + powerpc64-*) platform=3Dieee1275 ;; > sparc64-*) platform=3Dieee1275 ;; > - *) AC_MSG_ERROR([unsupported machine type]) ;; > + *) AC_MSG_ERROR([unsupported CPU: "$target_cpu"]) ;; > esac > else > platform=3D"$with_platform" > fi > =20 > -case "$platform" in > - linuxbios) platform=3Dcoreboot ;; > -esac > - > -if test "x$platform" =3D "xefi" ; then > - case "$target_cpu" in > - i386) ;; > - x86_64) target_m64=3D1 ;; > - *) AC_MSG_ERROR([unsupported CPU type for EFI]) ;; > +# Adjust CPU unless target was explicitly specified. > +if test -z "$target_alias"; then > + case "$target_cpu"-"$platform" in > + x86_64-efi) ;; > + x86_64-*) target_cpu=3Di386 target_m32=3D1 ;; > + powerpc64-ieee1275) target_cpu=3Dpowerpc target_m32=3D1 ;; > esac > -else > - case "$target_cpu" in > - i386) ;; > - x86_64) target_cpu=3Di386 target_m32=3D1 ;; > - powerpc) ;; > - powerpc64) target_cpu=3Dpowerpc target_m32=3D1;; > - sparc64) ;; > - *) AC_MSG_ERROR([unsupported CPU type]) ;; > - esac > fi > =20 > -# Sanity check. > +# Check if the platform is supported, make final adjustments. > case "$target_cpu"-"$platform" in > i386-efi) ;; > - x86_64-efi) ;; > + x86_64-efi) target_m64=3D1 ;; > i386-pc) ;; > i386-coreboot) ;; > + i386-linuxbios) platform=3Dcoreboot ;; > i386-ieee1275) ;; > powerpc-ieee1275) ;; > sparc64-ieee1275) ;; > - *) AC_MSG_ERROR([unsupported machine type]) ;; > + *) AC_MSG_ERROR([platform "$platform" is not supported for target CPU = "$target_cpu"]) ;; > esac > =20 > AC_SUBST(target_cpu) >=20 Confirmed to work on amd64 PC with Ubuntu Hardy (default system type from config.guess is x86_64-unknown-linux-gnu) --=-LU0TVfhtcvvmX2eLD2bW Content-Type: application/pgp-signature; name=signature.asc Content-Description: Esta parte del mensaje =?ISO-8859-1?Q?est=E1?= firmada digitalmente -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iQIVAwUASH97VqSl+Fbdeo72AQLzPA/9G2C97SbJfFNckD5qtGIORRJknZEzmZNY 5oFVxP2VgwkmBsYt8/GCIHhCXUewdd+t+qdru6QDO6Py4xjZRaP4yj4JxzPgLzaI 5ZakLFWCNmcGYXeDeJ0KX86AL8JvjHvkThPF1NCWi2t21G1HSKhcmwJqnxuhHoGg FjwPXMU9l2krgL7ougBPTMmlLG2M4gR+Z85JcVlYOP9lW5Y740QeF06/uV1No8Ai LKz+WRZtbsA++N1rYeoaVzdlVfu1psuW9l/Go56CxpNArevRiYH7imixj/rKZr7M NV9Xso4rpaNOGB6kcFt6CuY4+7Iac0iFR3+lYPzfeSS4gUHbZD0mHOAyAzaWMyVO M7DBf4eMFJ7uk/hGxoN+KfnQ/pAh4083WAG3fhd3gh9YOaPasdWMoPCu4DG7mNW2 cGAUADfFqpXJOg7B/TlFaFLvAbxnpzroN1yw5fH9F6B+KNXZFUwT2W/TD5jIYX/B 8pq8XgGeE5kljBjXIGTGL9KZ5fcGfUl1Jldb3rYDfL+5TUYTXgM9031dzfxP+6LN vbo9fPew6a8uUwu4STSGOhKAKsMYFe3V57UZ3Hj2sxqtec8ufBff0fr6Ylcff+hs +LQXZrDRaE7Hx1SpS/2e4FCuEli7B4k0Ab+2mYjvUcHDdtc6rQuT8uFCZCDJj0ik gEQBSEOs4ZY= =9FNH -----END PGP SIGNATURE----- --=-LU0TVfhtcvvmX2eLD2bW--