aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordanfe <danfe@FreeBSD.org>2013-06-10 20:07:09 +0800
committerdanfe <danfe@FreeBSD.org>2013-06-10 20:07:09 +0800
commit0e8775861364b8e659c2d9f9e26f3e570a310bcb (patch)
treee3e951b960cc0ba7aabf31d2a40359c2042044ce
parent385ffc03118b5a13593b584f0cfb36262a7339f3 (diff)
downloadfreebsd-ports-gnome-0e8775861364b8e659c2d9f9e26f3e570a310bcb.tar.gz
freebsd-ports-gnome-0e8775861364b8e659c2d9f9e26f3e570a310bcb.tar.zst
freebsd-ports-gnome-0e8775861364b8e659c2d9f9e26f3e570a310bcb.zip
Simplify compiler name and version gathering code.
-rw-r--r--editors/biew/files/patch-configure11
1 files changed, 5 insertions, 6 deletions
diff --git a/editors/biew/files/patch-configure b/editors/biew/files/patch-configure
index b10365953e6d..b62d2908ec45 100644
--- a/editors/biew/files/patch-configure
+++ b/editors/biew/files/patch-configure
@@ -9,7 +9,7 @@
}
# Use this to echo the results of a check
-@@ -493,20 +493,21 @@
+@@ -493,20 +493,20 @@
echores "$_target_system"
@@ -21,8 +21,7 @@
-cc_name=`$_cc -v 2>&1 | tail -n 1 | cut -d ' ' -f 1`
-cc_version=`$_cc -dumpversion`
+eval `$_cc -v 2>&1 | sed -En \
-+ '/version/s,(FreeBSD )?(.*) version ([0-9.]*).*,\2 \3,p' | (read cc_name \
-+ cc_version ; echo cc_name=$cc_name \; cc_version=$cc_version)`
++ '/version/s,(.* )?(.*) version ([0-9.]*).*,cc_name=\2 ; cc_version=\3,p'`
echocheck "C compiler name"
echores $cc_name
@@ -36,7 +35,7 @@
;;
esac
-@@ -583,10 +584,10 @@
+@@ -583,10 +583,10 @@
_osldef="$_debug $_profile $_osldef"
elif test -z "$CFLAGS" ; then
_cdefos="-DNDEBUG=1 -O2 -ffast-math -fomit-frame-pointer $_cdefos"
@@ -48,7 +47,7 @@
test -n "$LDFLAGS" && _osldef="$LDFLAGS $_osldef"
test -n "$LIBS" && _osldef="$LIBS $_osldef"
-@@ -656,10 +657,10 @@
+@@ -656,10 +656,10 @@
echocheck "slang.h"
check_header slang.h
enabled slang_h && _cdefos="-D_SLANG_ -D__OS_NAME__='\"Unix/Slang\"' $_cdefos"
@@ -61,7 +60,7 @@
echocheck "curses.h"
cat > $TMPC << EOF
#include <curses.h>
-@@ -678,8 +679,10 @@
+@@ -678,8 +678,10 @@
fi
echores "$_curses"
fi