From owner-freebsd-python@FreeBSD.ORG Fri Feb 4 19:54:07 2011 Return-Path: Delivered-To: freebsd-python@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4AE88106566B for ; Fri, 4 Feb 2011 19:54:07 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id DC8FA8FC13 for ; Fri, 4 Feb 2011 19:54:06 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id p14Js2CS030559 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 4 Feb 2011 21:54:02 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id p14Js2DA071262 for ; Fri, 4 Feb 2011 21:54:02 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id p14Js03W071261 for freebsd-python@freebsd.org; Fri, 4 Feb 2011 21:54:00 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 4 Feb 2011 21:54:00 +0200 From: Kostik Belousov To: freebsd-python@freebsd.org Message-ID: <20110204195400.GP78089@deviant.kiev.zoral.com.ua> References: <20110204051500.GA80820@comcast.net> <20110204100544.GL78089@deviant.kiev.zoral.com.ua> <20110204185512.GB80820@comcast.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="DITGHUV3p5DjDsXt" Content-Disposition: inline In-Reply-To: <20110204185512.GB80820@comcast.net> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Subject: Re: py-numpy build failure, multiple definition of `__i686.get_pc_thunk.bx' X-BeenThere: freebsd-python@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD-specific Python issues List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 04 Feb 2011 19:54:07 -0000 --DITGHUV3p5DjDsXt Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Feb 04, 2011 at 10:55:12AM -0800, Charlie Kester wrote: > On Fri 04 Feb 2011 at 02:05:44 PST Kostik Belousov wrote: > >On Thu, Feb 03, 2011 at 09:15:00PM -0800, Charlie Kester wrote: > >... > >>customize UnixCCompiler > >>customize UnixCCompiler using build_ext > >>customize Gnu95FCompiler > >>customize Gnu95FCompiler using build_ext > >>building 'numpy.core._sort' extension > >>compiling C sources > >>C compiler: gcc45 -DNDEBUG -mtune=3Dgeneric -msse -msse2 -msse3=20 > >>-mfpmath=3Dsse -O2 -fno-strict-aliasing -pipe -D__wchar_t=3Dwchar_t=20 > >>-DTHREAD_STACK_SIZE=3D0x20000 -mtune=3Dgeneric -msse -msse2 -msse3=20 > >>-mfpmath=3Dsse -O2 -fno-strict-aliasing -pipe=20 > >>-Wl,-rpath=3D/usr/local/lib/gcc45 -fPIC > >> > >>compile options: '-Inumpy/core/include=20 > >>-Ibuild/src.freebsd-8.2-PRERELEASE-i386-2.7/numpy/core/include/numpy=20 > >>-Inumpy/core/src/private -Inumpy/core/src -Inumpy/core=20 > >>-Inumpy/core/src/npymath -Inumpy/core/src/multiarray=20 > >>-Inumpy/core/src/umath -Inumpy/core/include=20 > >>-I/usr/local/include/python2.7=20 > >>-Ibuild/src.freebsd-8.2-PRERELEASE-i386-2.7/numpy/core/src/multiarray= =20 > >>-Ibuild/src.freebsd-8.2-PRERELEASE-i386-2.7/numpy/core/src/umath -c' > >>gcc45:=20 > >>build/src.freebsd-8.2-PRERELEASE-i386-2.7/numpy/core/src/_sortmodule.c > >>cc -shared -pthread -mtune=3Dgeneric -msse -msse2 -msse3 -mfpmath=3Dsse= -O2=20 > >>-fno-strict-aliasing -pipe -Wl,-rpath=3D/usr/local/lib/gcc45=20 > >>build/temp.freebsd-8.2-PRERELEASE-i386-2.7/build/src.freebsd-8.2-PREREL= EASE-i386-2.7/numpy/core/src/_sortmodule.o -Lbuild/temp.freebsd-8.2-PRERELE= ASE-i386-2.7 -lm -o build/lib.freebsd-8.2-PRERELEASE-i386-2.7/numpy/core/_s= ort.so > >>build/temp.freebsd-8.2-PRERELEASE-i386-2.7/build/src.freebsd-8.2-PREREL= EASE-i386-2.7/numpy/core/src/_sortmodule.o(.text.__i686.get_pc_thunk.bx+0x0= ): In function `__i686.get_pc_thunk.bx': > >>: multiple definition of `__i686.get_pc_thunk.bx' > >>/usr/lib/crtbeginS.o(.gnu.linkonce.t.__i686.get_pc_thunk.bx+0x0): first= =20 > >>defined here > >>build/temp.freebsd-8.2-PRERELEASE-i386-2.7/build/src.freebsd-8.2-PREREL= EASE-i386-2.7/numpy/core/src/_sortmodule.o(.text.__i686.get_pc_thunk.bx+0x0= ): In function `__i686.get_pc_thunk.bx': > >>: multiple definition of `__i686.get_pc_thunk.bx' > >>/usr/lib/crtbeginS.o(.gnu.linkonce.t.__i686.get_pc_thunk.bx+0x0): first= =20 > >>defined here > >>error: Command "cc -shared -pthread -mtune=3Dgeneric -msse -msse2 -msse= 3=20 > >>-mfpmath=3Dsse -O2 -fno-strict-aliasing -pipe=20 > >>-Wl,-rpath=3D/usr/local/lib/gcc45=20 > >>build/temp.freebsd-8.2-PRERELEASE-i386-2.7/build/src.freebsd-8.2-PREREL= EASE-i386-2.7/numpy/core/src/_sortmodule.o -Lbuild/temp.freebsd-8.2-PRERELE= ASE-i386-2.7 -lm -o build/lib.freebsd-8.2-PRERELEASE-i386-2.7/numpy/core/_s= ort.so" failed with exit status 1 > >>*** Error code 1 >=20 > >Can you show the actual invocation of the compiler driver for linking ? >=20 > Isn't that the line right before the first report of the error? >=20 > cc -shared -pthread -mtune=3Dgeneric -msse -msse2 -msse3 -mfpmath=3Dsse -= O2=20 > -fno-strict-aliasing -pipe -Wl,-rpath=3D/usr/local/lib/gcc45=20 > build/temp.freebsd-8.2-PRERELEASE-i386-2.7/build/src.freebsd-8.2-PRERELEA= SE-i386-2.7/numpy/core/src/_sortmodule.o -Lbuild/temp.freebsd-8.2-PRERELEAS= E-i386-2.7 -lm -o build/lib.freebsd-8.2-PRERELEASE-i386-2.7/numpy/core/_sor= t.so >=20 > FWIW, I tried modifying my make.conf to remove the additional CFLAGS I'd > added, like -fno-strict-aliasing. But the build still failed using only > the CFLAGS provided by the ports system and py-numpy's configtests. >=20 > I also checked for environment variables related to the linker and found > none. (For this build I'm logged into the console, not a terminal > emulator, as root and am not using a custom profile.) >=20 > My PATH looks like this: > /sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/= root/bin >=20 > I do have gcc45 installed, but only as a result of some other port that > required it. I forget which one. Anyway, you can see that it's being > used in the excerpt above. I wanted the confirmation of exact command that failed. If your citation above is right, then port _does not_ use gcc45 to do linkage of the module. Generally, crtbegin/crtend.o come from the compiler installation, so I am suspicious at least to report of use of /usr/lib/crtbegin.So. Can you enter the port build directory and execute the same command manually, substituting "cc" with full path to gcc45 ? --DITGHUV3p5DjDsXt Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk1MWVgACgkQC3+MBN1Mb4g5LwCfdT+JXneiF/A3qcYPvIDCL6NX ixkAnimNk904zVBj/SW89fNmXtukelCy =SC3B -----END PGP SIGNATURE----- --DITGHUV3p5DjDsXt--