From b0eb18cc89c5d16d2a47d64994bef03b52d087e7 Mon Sep 17 00:00:00 2001 From: Martin Mares Date: Tue, 6 Feb 2007 12:59:03 +0100 Subject: [PATCH] Work-around for Solaris tr. --- ChangeLog | 3 +++ lib/configure | 7 ++++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3e673bb..3ebadcf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2007-02-06 Martin Mares + * lib/configure: tr on Solaris is a bit weird and it requires `[A-Z]' + instead of `A-Z'. Fortunately, the extra brackets don't hurt otherwise. + * lib/types.h, lib/configure: Solaris should use to get precise integer types. diff --git a/lib/configure b/lib/configure index 77393a5..a031ca7 100755 --- a/lib/configure +++ b/lib/configure @@ -27,7 +27,8 @@ then sys=freebsd fi host=${3:-$cpu-$sys} -host=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)$/\1--\2/' | tr 'A-Z' 'a-z'` +# CAVEAT: tr on Solaris is a bit weird and the extra [] is otherwise harmless. +host=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)$/\1--\2/' | tr '[A-Z]' '[a-z]'` cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` sys=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` rel=${4:-$rel} @@ -36,8 +37,8 @@ zlib=$5 c=config.h m=config.mk -echo >$c "#define PCI_ARCH_`echo $cpu | tr 'a-z' 'A-Z'`" -echo >>$c "#define PCI_OS_`echo $sys | tr 'a-z' 'A-Z'`" +echo >$c "#define PCI_ARCH_`echo $cpu | tr '[a-z]' '[A-Z]'`" +echo >>$c "#define PCI_OS_`echo $sys | tr '[a-z]' '[A-Z]'`" rm -f $m echo_n "Looking for access methods..." -- 2.39.5