Fix www/squid unexpectedly using -march=native

Dimitry Andric dim at FreeBSD.org
Wed Oct 15 19:12:09 UTC 2014


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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 203 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20141015/e6805693/attachment.sig>


More information about the freebsd-ports mailing list