Date: Wed, 19 Feb 2014 18:45:52 +0100 From: Antoine Brodin <antoine@FreeBSD.org> To: python@freebsd.org Subject: Python and clang 3.4 Message-ID: <CAALwa8m9-dpiO4fpA_BG-QeZyo9wsRpDVXHz_CTNUYeFLK7GVA@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hi there, Clang 3.4 was imported in head 3 days ago. A few python extensions are broken because clang now refuses flags it doesn't know. For instance -R is not recognized, which breaks py-sqlite3, py-ldap2 and a few others. Some failure logs are available at http://package21.nyi.freebsd.org/bulk/head-default-baseline/2014-02-18_15h22m08s/logs/errors/py27-sqlite3-2.7.6_3.log and http://package21.nyi.freebsd.org/bulk/head-default-baseline/2014-02-18_15h22m08s/logs/errors/py27-ldap2-2.4.13.log Below is a possible fix for python27: Index: lang/python27/Makefile =================================================================== --- lang/python27/Makefile (revision 345118) +++ lang/python27/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= python27 PORTVERSION= 2.7.6 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= lang python ipv6 MASTER_SITES= PYTHON MASTER_SITE_SUBDIR= ${PYTHON_MASTER_SITE_SUBDIR} Index: lang/python27/files/patch-Lib__distutils__unixccompiler.py =================================================================== --- lang/python27/files/patch-Lib__distutils__unixccompiler.py (revision 0) +++ lang/python27/files/patch-Lib__distutils__unixccompiler.py (working copy) @@ -0,0 +1,11 @@ +--- ./Lib/distutils/unixccompiler.py.orig 2013-11-10 07:36:40.000000000 +0000 ++++ ./Lib/distutils/unixccompiler.py 2014-02-19 15:41:48.000000000 +0000 +@@ -228,6 +228,8 @@ + if sys.platform[:6] == "darwin": + # MacOSX's linker doesn't understand the -R flag at all + return "-L" + dir ++ elif sys.platform[:7] == "freebsd": ++ return "-Wl,-rpath=" + dir + elif sys.platform[:5] == "hp-ux": + if self._is_gcc(compiler): + return ["-Wl,+s", "-L" + dir] Cheers, Antoine
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAALwa8m9-dpiO4fpA_BG-QeZyo9wsRpDVXHz_CTNUYeFLK7GVA>