Mercurial > pidgin
comparison autogen.sh @ 22753:3b14215d2ca4
merge of 'a2c4bf662d1fdab8c870c1ebbca30968af4bb80a'
and 'caaa65e1c157e6cb43219237f88a4ad298f3bbf5'
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Mon, 28 Apr 2008 06:27:11 +0000 |
parents | 7291da73b054 |
children | 78ee2ec009e8 |
comparison
equal
deleted
inserted
replaced
22752:a184ac4eace6 | 22753:3b14215d2ca4 |
---|---|
47 # This will work for any influential environment variable to configure. | 47 # This will work for any influential environment variable to configure. |
48 ############################################################################### | 48 ############################################################################### |
49 PACKAGE="Pidgin" | 49 PACKAGE="Pidgin" |
50 ARGS_FILE="autogen.args" | 50 ARGS_FILE="autogen.args" |
51 | 51 |
52 libtoolize="libtoolize" | |
53 case $(uname -s) in | |
54 Darwin*) | |
55 libtoolize="glibtoolize" | |
56 ;; | |
57 *) | |
58 esac | |
59 | |
52 ############################################################################### | 60 ############################################################################### |
53 # Some helper functions | 61 # Some helper functions |
54 ############################################################################### | 62 ############################################################################### |
55 check () { | 63 check () { |
56 CMD=$1 | 64 CMD=$1 |
57 | 65 |
58 echo -n "checking for ${CMD}... " | 66 printf "%s" "checking for ${CMD}... " |
59 BIN=`which ${CMD} 2> /dev/null` | 67 BIN=`which ${CMD} 2> /dev/null` |
60 | 68 |
61 if [ x"${BIN}" = x"" ] ; then | 69 if [ x"${BIN}" = x"" ] ; then |
62 echo "not found." | 70 echo "not found." |
63 echo "${CMD} is required to build ${PACKAGE}!" | 71 echo "${CMD} is required to build ${PACKAGE}!" |
69 | 77 |
70 run_or_die () { # beotch | 78 run_or_die () { # beotch |
71 CMD=$1 | 79 CMD=$1 |
72 shift | 80 shift |
73 | 81 |
74 echo -n "running ${CMD} ${@}... " | 82 printf "%s" "running ${CMD} ${@}... " |
75 OUTPUT=`${CMD} ${@} 2>&1` | 83 OUTPUT=`${CMD} ${@} 2>&1` |
76 if [ $? != 0 ] ; then | 84 if [ $? != 0 ] ; then |
77 echo "failed." | 85 echo "failed." |
78 echo ${OUTPUT} | 86 echo ${OUTPUT} |
79 exit 1 | 87 exit 1 |
97 fi | 105 fi |
98 | 106 |
99 ############################################################################### | 107 ############################################################################### |
100 # Look for our args file | 108 # Look for our args file |
101 ############################################################################### | 109 ############################################################################### |
102 echo -n "checking for ${ARGS_FILE}: " | 110 printf "%s" "checking for ${ARGS_FILE}: " |
103 if [ -f ${ARGS_FILE} ] ; then | 111 if [ -f ${ARGS_FILE} ] ; then |
104 echo "found." | 112 echo "found." |
105 echo -n "sourcing ${ARGS_FILE}: " | 113 printf "%s" "sourcing ${ARGS_FILE}: " |
106 . autogen.args | 114 . ${ARGS_FILE} |
107 echo "done." | 115 echo "done." |
108 else | 116 else |
109 echo "not found." | 117 echo "not found." |
110 fi | 118 fi |
111 | 119 |
112 ############################################################################### | 120 ############################################################################### |
113 # Check for our required helpers | 121 # Check for our required helpers |
114 ############################################################################### | 122 ############################################################################### |
115 check "libtoolize"; LIBTOOLIZE=${BIN}; | 123 check "$libtoolize"; LIBTOOLIZE=${BIN}; |
116 check "glib-gettextize"; GLIB_GETTEXTIZE=${BIN}; | 124 check "glib-gettextize"; GLIB_GETTEXTIZE=${BIN}; |
117 check "intltoolize"; INTLTOOLIZE=${BIN}; | 125 check "intltoolize"; INTLTOOLIZE=${BIN}; |
118 check "aclocal"; ACLOCAL=${BIN}; | 126 check "aclocal"; ACLOCAL=${BIN}; |
119 check "autoheader"; AUTOHEADER=${BIN}; | 127 check "autoheader"; AUTOHEADER=${BIN}; |
120 check "automake"; AUTOMAKE=${BIN}; | 128 check "automake"; AUTOMAKE=${BIN}; |