--- musl-1.1.19/configure~	2018-02-22 15:39:19.000000000 -0300
+++ musl-1.1.19/configure	2018-03-23 21:11:10.918075969 -0300
@@ -491,7 +491,10 @@
 # check both CC and CFLAGS.
 #
 if test "$ARCH" = "i386" ; then
-fnmatch '-march=*|*\ -march=*' "$CC $CFLAGS" || tryldflag CFLAGS_AUTO -march=i486
+fnmatch '-march=*|*\ -march=*' "$CC $CFLAGS" || tryldflag CFLAGS_AUTO -march=i586
+fnmatch '-mtune=*|*\ -mtune=*' "$CC $CFLAGS" || tryldflag CFLAGS_AUTO -mtune=i686
+fi
+if test "$ARCH" = "x86_64" ; then
 fnmatch '-mtune=*|*\ -mtune=*' "$CC $CFLAGS" || tryldflag CFLAGS_AUTO -mtune=generic
 fi
 
