devtool.func

Thu, 06 Aug 2009 13:21:30 +0200

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 06 Aug 2009 13:21:30 +0200
changeset 15
0e0eb7c91312
permissions
-rw-r--r--

Remove seemingly declarations unnecessary according to Qt 4.5.2 headers.

michael@1 1 ##
michael@1 2 ## devtool.func -- Development Tool Functions
michael@1 3 ## Copyright (c) 2001-2002 Ralf S. Engelschall <rse@engelschall.com>
michael@1 4 ##
michael@1 5
michael@1 6 devtool_require () {
michael@1 7 t="$1"; o="$2"; p="$3"; e="$4"; a="$5"
michael@1 8 v=`($t $o | head -1 | awk "{ print \\\$$p; }") 2>/dev/null`
michael@1 9 if [ ".$v" = . ]; then
michael@1 10 echo "devtool:ERROR: unable to determine version of $t" 1>&2
michael@1 11 exit 1
michael@1 12 fi
michael@1 13 case "$v" in
michael@1 14 $e )
michael@1 15 ;;
michael@1 16 $a )
michael@1 17 echo "devtool:WARNING: $t version $v still accepted, although expected $e." 1>&2
michael@1 18 ;;
michael@1 19 * )
michael@1 20 echo "devtool:ERROR: $t version $e expected, but found $v." 1>&2
michael@1 21 exit 1
michael@1 22 ;;
michael@1 23 esac
michael@1 24 echo "$v"
michael@1 25 }
michael@1 26
michael@1 27 devtool_autogen () {
michael@1 28 tool=$1
michael@1 29 shift
michael@1 30 case $tool in
michael@1 31 autoconf )
michael@1 32 autoconf_version=`devtool_require autoconf --version 4 "$1" "$2"`
michael@1 33 echo "generating (GNU Autoconf $autoconf_version): configure ac_config.h.in"
michael@1 34 autoconf
michael@1 35 autoheader 2>&1 | grep -v "is unchanged"
michael@1 36 rm -rf autom4te.cache >/dev/null 2>&1
michael@1 37 ;;
michael@1 38 libtool )
michael@1 39 libtoolize_version=`devtool_require libtoolize --version 4 "$1" "$2"`
michael@1 40 echo "generating (GNU Libtool $libtoolize_version): ltmain.sh, libtool.m4, config.guess, config.sub"
michael@1 41 libtoolize --force --copy >/dev/null 2>&1
michael@1 42 cp `libtoolize --force --copy --dry-run | grep "add the contents of" |\
michael@1 43 sed -e 's;^[^\`]*\`;;' -e "s;'.*;;"` libtool.m4
michael@1 44 ;;
michael@1 45 shtool )
michael@1 46 shtoolize_version=`devtool_require shtoolize -v 3 "$1" "$2"`
michael@1 47 echo "generating (GNU Shtool $shtoolize_version): shtool"
michael@1 48 shift
michael@1 49 shift
michael@1 50 shtoolize -q "$@"
michael@1 51 ;;
michael@1 52 esac
michael@1 53 }
michael@1 54
michael@1 55 devtool_autoclean () {
michael@1 56 tool=$1
michael@1 57 shift
michael@1 58 case $tool in
michael@1 59 autoconf )
michael@1 60 echo "removing: configure ac_config.h.in"
michael@1 61 rm -f configure ac_config.h.in
michael@1 62 ;;
michael@1 63 libtool )
michael@1 64 echo "removing: ltmain.sh libtool.m4 config.guess config.sub"
michael@1 65 rm -f ltmain.sh libtool.m4 config.guess config.sub
michael@1 66 ;;
michael@1 67 shtool )
michael@1 68 echo "removing: shtool"
michael@1 69 rm -f shtool
michael@1 70 ;;
michael@1 71 esac
michael@1 72 }

mercurial