Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 15 Oct 2014 21:11:44 +0200
From:      Dimitry Andric <dim@FreeBSD.org>
To:        FreeBSD Ports <freebsd-ports@freebsd.org>
Subject:   Fix www/squid unexpectedly using -march=native
Message-ID:  <3CB2243B-8124-41BD-9564-3F9AED1B3566@FreeBSD.org>

next in thread | raw e-mail | index | archive | help

--Apple-Mail=_E2EBCF86-EB23-47D4-82CC-16CB229D4EE7
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
	charset=us-ascii

Hi,

Since http://bazaar.launchpad.net/~squid/squid/3-trunk/revision/12842,
Squid's configure script defaults to -march=native, if the flag is
supported by the compiler.  And this even *overrides* your own specified
CPUTYPE or -march= flag!  So I personally experienced Squid 3.4 crashing
on an old Celeron, when it was built on a Core i7. :-(

Proposed fix is to explicitly tell the configure script to *not* enable
-march=native by default:

Index: www/squid/Makefile
===================================================================
--- www/squid/Makefile  (revision 370765)
+++ www/squid/Makefile  (working copy)
@@ -181,7 +181,8 @@
                --disable-epoll \
                --disable-linux-netfilter \
                --disable-linux-tproxy \
-               --disable-translation
+               --disable-translation \
+               --disable-arch-native

 .include <bsd.port.options.mk>

Note that only squid 3.4 suffers from this bug, 3.3 is not affected.

-Dimitry


--Apple-Mail=_E2EBCF86-EB23-47D4-82CC-16CB229D4EE7
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename=signature.asc
Content-Type: application/pgp-signature;
	name=signature.asc
Content-Description: Message signed with OpenPGP using GPGMail

-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.22 (Darwin)

iEYEARECAAYFAlQ+xvgACgkQsF6jCi4glqPUbwCfaMPYoPpFAb2IIE09MLrz7a1R
CPwAnjB8kUA7P+NKdObzJ9C9Dx8WdCxq
=P4jZ
-----END PGP SIGNATURE-----

--Apple-Mail=_E2EBCF86-EB23-47D4-82CC-16CB229D4EE7--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3CB2243B-8124-41BD-9564-3F9AED1B3566>