From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1VhJyd-00011C-AI for mharc-grub-devel@gnu.org; Fri, 15 Nov 2013 09:02:27 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50569) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VhJyX-0000yz-OQ for grub-devel@gnu.org; Fri, 15 Nov 2013 09:02:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VhJyT-0005dQ-FF for grub-devel@gnu.org; Fri, 15 Nov 2013 09:02:21 -0500 Received: from mail-ea0-x232.google.com ([2a00:1450:4013:c01::232]:62143) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VhJyT-0005dG-3m for grub-devel@gnu.org; Fri, 15 Nov 2013 09:02:17 -0500 Received: by mail-ea0-f178.google.com with SMTP id d10so797035eaj.23 for ; Fri, 15 Nov 2013 06:02:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type; bh=KmkeOmKo5kxVP/BUMLlG8ktlRwA+LvzEASu1rjKWR08=; b=TDeXDIkP4byhmsg+HfTBUb3HyZ2S3/18XI60yKjaE2+WtCdHXGdoHxjJo8h0s1KzuA x3iHEuiG/ZmZHqdLQn26eNJtEhNQTYol9Nx3cC1tsvYulSYOcmZpPlv1Q6c2Uk9Jo3zV Dqz2XKE0iw0C7Kvs8YWfipPriXruobD/1LNCTcFEXhli/wEkAnh9jdvrlxbzj/k0fgeS qXGiGrtVn6I1Q59cIGtcRt2lFeE9DF62P5d3HwSbxUgoy6W9vMhuSgXLWsMwEc50EHK1 ETynoForEMXvtTlV67qfYmQdDUQkXoQZj2PM/LJIn/UM3Ijgd7WjP+nCGXfGDiOmNhSZ jjFw== X-Received: by 10.15.52.129 with SMTP id p1mr186785eew.95.1384524133420; Fri, 15 Nov 2013 06:02:13 -0800 (PST) Received: from [192.168.1.16] (31-249.1-85.cust.bluewin.ch. [85.1.249.31]) by mx.google.com with ESMTPSA id b42sm6691712eem.9.2013.11.15.06.02.12 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 15 Nov 2013 06:02:12 -0800 (PST) Message-ID: <52862963.2060409@gmail.com> Date: Fri, 15 Nov 2013 15:02:11 +0100 From: =?UTF-8?B?VmxhZGltaXIgJ8+GLWNvZGVyL3BoY29kZXInIFNlcmJpbmVua28=?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131005 Icedove/17.0.9 MIME-Version: 1.0 To: grub-devel@gnu.org Subject: Re: PPC build failure with undefined symbols __ashldi3, _restgpr_14_x, ... References: <20131115091954.2b642e0b@opensuse.site> <5285FEE1.3030601@gmail.com> <20131115162200.2c18d0d0@opensuse.site> <52861483.70807@gmail.com> <20131115174346.3360ac1e@opensuse.site> In-Reply-To: <20131115174346.3360ac1e@opensuse.site> X-Enigmail-Version: 1.5.1 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="----enig2VUMFWERNTRANBRRXWAHE" X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4013:c01::232 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Nov 2013 14:02:26 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2VUMFWERNTRANBRRXWAHE Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 15.11.2013 14:43, Andrey Borzenkov wrote: > =D0=92 Fri, 15 Nov 2013 13:33:07 +0100 > Vladimir '=CF=86-coder/phcoder' Serbinenko =D0=BF=D0= =B8=D1=88=D0=B5=D1=82: >=20 >> On 15.11.2013 13:22, Andrey Borzenkov wrote: >>> =D0=92 Fri, 15 Nov 2013 12:00:49 +0100 >>> Vladimir '=CF=86-coder/phcoder' Serbinenko =D0=BF= =D0=B8=D1=88=D0=B5=D1=82: >>> >>>> On 15.11.2013 06:19, Andrey Borzenkov wrote: >>>>> Sources at 6fcec439545c817fbc8e2f51c667a70037a34a76 >>>>> >>>>> Building RPM for PPC (32 or 64 bits) I get >>>>> >>>>> [ 187s] cat syminfo.lst | sort | gawk -f ../../grub-core/genmoddep= =2Eawk > moddep.lst || (rm -f moddep.lst; exit 1) >>>>> [ 187s] __ashldi3 in affs is not defined >>>>> [ 187s] _restgpr_14_x in affs is not defined >>>>> [ 187s] _restgpr_20_x in affs is not defined >>>>> [ 187s] _restgpr_25_x in affs is not defined >>>>> [ 187s] _restgpr_27_x in affs is not defined >>>>> [ 187s] _restgpr_28_x in affs is not defined >>>>> [ 187s] _restgpr_30_x in affs is not defined >>>>> ... >>>>> >>>>> for a long list of them. >>>>> >>>>> Full build logs are available as >>>>> https://build.opensuse.org/build/home:arvidjaar:grub2-next/openSUSE= _Factory_PowerPC/ppc/grub2/_log >>>>> https://build.opensuse.org/build/home:arvidjaar:grub2-next/openSUSE= _Factory_PowerPC/ppc64/grub2/_log >>>>> >>>>> I do not myself have access to any PPC system nor any experience wi= th >>>>> them. >>>>> >>>> You don't have multilib installed. >>> >>> Could you elaborate? This is native build on PPC system. It has both = 64 >>> and 32 bit of gcc and libgcc installed: >>> >>> [ 12s] libgcc_s1-32bit-4.8.1_20130909-5.1 ######################= ################## >>> [ 10s] libgcc_s1-4.8.1_20130909-5.1 ######################= ################## >>> [ 17s] gcc48-4.8.1_20130909-5.1 ######################= ################## >>> [ 17s] gcc48-32bit-4.8.1_20130909-5.1 ######################= ################## >>> >>> This did build successfully until some recent changes (grub2 *is* par= t >>> of openSUSE for PPC). I compared logs for x86 and ppc and both say >>> >>> [ 119s] checking for __bswapsi2... no >>> [ 119s] checking for __bswapdi2... no >>> [ 119s] checking for __ashldi3... no >>> [ 120s] checking for __ashrdi3... no >>> [ 120s] checking for __lshrdi3... no >>> [ 120s] checking for __ucmpdi2... no >>> [ 120s] checking for _restgpr_14_x... no >>> >>> unfortunately I'm stuck here. For all I can tell it should either fai= l >>> or succeed in both cases. >>> >> It should say all "no" on x86 and almost all "yes" on ppc. This output= >> indicates that link with libgcc failed. You can look how exactly the >> test failed in config.log. Can you send me config.log ? >=20 > Initially it failed due to missing -lc. After adding glibc-devel-static= > to buildrequires it now fails due to redefined abort: >=20 > [ 121s] configure:25260: checking for __bswapsi2 > [ 121s] configure:25260: gcc -o conftest -Os -Wall -W -Wshadow -Wold-= style-definition -Wpointer-arith -Wundef -Wextra -Wattributes -Wchar-subs= cripts -Wcomment -Wdeprecated-declarations -Wdisabled-optimization -Wdiv-= by-zero -Wendif-labels -Wfloat-equal -Wformat-extra-args -Wformat-securit= y -Wformat-y2k -Wimplicit -Wimplicit-function-declaration -Wimplicit-int = -Winit-self -Wint-to-pointer-cast -Winvalid-pch -Wmain -Wmissing-braces -= Wmissing-field-initializers -Wmissing-format-attribute -Wmultichar -Wnonn= ull -Woverflow -Wparentheses -Wpointer-arith -Wpointer-to-int-cast -Wretu= rn-type -Wsequence-point -Wshadow -Wsign-compare -Wstrict-aliasing -Wswit= ch -Wtrigraphs -Wundef -Wunknown-pragmas -Wunused -Wunused-function -Wunu= sed-label -Wunused-parameter -Wunused-value -Wunused-variable -Wvariadic= -macros -Wvolatile-register-var -Wwrite-strings -Wnested-externs -Wstrict= -prototypes -Wpointer-sign -g -Wredundant-decls -Wmissing-prototypes -Wmi= ssing-declarations -Wcast-align -m32 -freg-struct- return -fno-dwarf2-cfi-asm -fno-asynchronous-unwind-tables -fno-stack-pro= tector -Wl,--defsym,abort=3Dmain -Wall -W -I$(top_srcdir)/include -I$(to= p_builddir)/include -DGRUB_MACHINE_IEEE1275=3D1 -DGRUB_MACHINE=3DPOWERPC= _IEEE1275 -DGRUB_TARGET_CPU_POWERPC=3D1 -m32 -static -m32 conftest.c -lgc= c >&5 > [ 121s] conftest.c:385:1: warning: function declaration isn't a protot= ype [-Wstrict-prototypes] > [ 121s] char __bswapsi2 (); > [ 121s] conftest.c:385:1: warning: function declaration isn't a protot= ype [-Wstrict-prototypes] > [ 121s] char __bswapsi2 (); > [ 121s] ^ > [ 121s] /usr/lib/gcc/powerpc64-suse-linux/4.8/../../../../lib/libc.a(a= bort.o): In function `abort': > [ 121s] /home/abuild/rpmbuild/BUILD/glibc-2.18/stdlib/abort.c:51: mult= iple definition of `abort' > [ 121s] collect2: error: ld returned 1 exit status >=20 Try this: diff --git a/configure.ac b/configure.ac index 2c4f019..cd96588 100644 --- a/configure.ac +++ b/configure.ac @@ -821,6 +821,8 @@ CFLAGS=3D"$TARGET_CFLAGS -Wl,--defsym,abort=3Dmain" fi fi +CFLAGS=3D"$CFLAGS -nostdlib" + # Check for libgcc symbols AC_CHECK_FUNCS(__bswapsi2 __bswapdi2 __ashldi3 __ashrdi3 __lshrdi3 __ucmpdi2 _restgpr_14_x) >=20 > -static is added by grub2.spec. I'm not sure, why - is it really needed= ? >=20 >=20 >=20 > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel >=20 ------enig2VUMFWERNTRANBRRXWAHE Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.15 (GNU/Linux) Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iF4EAREKAAYFAlKGKWMACgkQmBXlbbo5nOugiQD/bkgeb53Sq96p0Q7/xm7i83xp co3q5H7Bd/tLuCV0IyUA/iM1UxhmYn/vGtO0VGMWkYiIYh52p/PtfU6tIcyJkIbR =2qak -----END PGP SIGNATURE----- ------enig2VUMFWERNTRANBRRXWAHE--