diff options
-rw-r--r-- | Makefile | 1 | ||||
-rwxr-xr-x | build_tools/make_buildopts_h | 12 | ||||
-rwxr-xr-x | build_tools/make_version | 4 | ||||
-rwxr-xr-x | configure | 71 | ||||
-rw-r--r-- | configure.ac | 6 | ||||
-rw-r--r-- | makeopts.in | 1 |
6 files changed, 69 insertions, 26 deletions
@@ -92,6 +92,7 @@ export DOWNLOAD export AWK export GREP export ID +export MD5 # even though we could use '-include makeopts' here, use a wildcard # lookup anyway, so that make won't try to build makeopts if it doesn't diff --git a/build_tools/make_buildopts_h b/build_tools/make_buildopts_h index 8409f805f..5159688af 100755 --- a/build_tools/make_buildopts_h +++ b/build_tools/make_buildopts_h @@ -27,17 +27,7 @@ then TMP="${TMP} AST_DEVMODE" fi -case ${OSARCH} in # actually we should check build_os -*BSD|mingw|darwin*) - BUILDSUM=`echo ${TMP} | md5 | cut -c1-32` - ;; -SunOS) - BUILDSUM=`echo ${TMP} | digest -a md5 | cut -c1-32` - ;; -*) - BUILDSUM=`echo ${TMP} | md5sum | cut -c1-32` - ;; -esac +BUILDSUM=`echo ${TMP} | ${MD5} | cut -c1-32` echo "#define AST_BUILDOPT_SUM \"${BUILDSUM}\"" diff --git a/build_tools/make_version b/build_tools/make_version index b7fdf8297..cf8201f8b 100755 --- a/build_tools/make_version +++ b/build_tools/make_version @@ -30,7 +30,7 @@ elif [ -d .svn ]; then fi if [ ${BRANCH} != 0 ] ; then - if [ -z ${RESULT} ] ; then + if [ -z "${RESULT}" ] ; then RESULT="${PART}" else RESULT="${RESULT}-${PART}" @@ -39,7 +39,7 @@ elif [ -d .svn ]; then fi if [ ${TEAM} != 0 ] ; then - if [ -z ${RESULT} ] ; then + if [ -z "${RESULT}" ] ; then RESULT="${PART}" else RESULT="${RESULT}-${PART}" @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.ac Revision: 151244 . +# From configure.ac Revision: 153745 . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61 for asterisk 1.6. # @@ -715,6 +715,7 @@ KPATHSEA FETCH DOWNLOAD SOXMIX +MD5 acx_pthread_config PTHREAD_CC PTHREAD_LIBS @@ -7429,6 +7430,53 @@ _ACEOF fi +for ac_prog in md5 md5sum gmd5sum digest +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } +if test "${ac_cv_prog_MD5+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$MD5"; then + ac_cv_prog_MD5="$MD5" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_MD5="$ac_prog" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + +fi +fi +MD5=$ac_cv_prog_MD5 +if test -n "$MD5"; then + { echo "$as_me:$LINENO: result: $MD5" >&5 +echo "${ECHO_T}$MD5" >&6; } +else + { echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6; } +fi + + + test -n "$MD5" && break +done + + +if test "${MD5}" = "digest" ; then + MD5="${MD5} -a md5" +fi + @@ -12835,13 +12883,11 @@ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include <sys/types.h> /* for off_t */ - #include <stdio.h> +#include <stdio.h> int main () { -int (*fp) (FILE *, off_t, int) = fseeko; - return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); +return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0); ; return 0; } @@ -12881,13 +12927,11 @@ cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #define _LARGEFILE_SOURCE 1 -#include <sys/types.h> /* for off_t */ - #include <stdio.h> +#include <stdio.h> int main () { -int (*fp) (FILE *, off_t, int) = fseeko; - return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); +return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0); ; return 0; } @@ -49961,7 +50005,7 @@ KPATHSEA!$KPATHSEA$ac_delim FETCH!$FETCH$ac_delim DOWNLOAD!$DOWNLOAD$ac_delim SOXMIX!$SOXMIX$ac_delim -acx_pthread_config!$acx_pthread_config$ac_delim +MD5!$MD5$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then @@ -50003,6 +50047,7 @@ _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF +acx_pthread_config!$acx_pthread_config$ac_delim PTHREAD_CC!$PTHREAD_CC$ac_delim PTHREAD_LIBS!$PTHREAD_LIBS$ac_delim PTHREAD_CFLAGS!$PTHREAD_CFLAGS$ac_delim @@ -50099,7 +50144,6 @@ NCURSES_LIB!$NCURSES_LIB$ac_delim NCURSES_INCLUDE!$NCURSES_INCLUDE$ac_delim NCURSES_DIR!$NCURSES_DIR$ac_delim PBX_NCURSES!$PBX_NCURSES$ac_delim -NETSNMP_LIB!$NETSNMP_LIB$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then @@ -50141,6 +50185,7 @@ _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF +NETSNMP_LIB!$NETSNMP_LIB$ac_delim NETSNMP_INCLUDE!$NETSNMP_INCLUDE$ac_delim NETSNMP_DIR!$NETSNMP_DIR$ac_delim PBX_NETSNMP!$PBX_NETSNMP$ac_delim @@ -50237,7 +50282,6 @@ OPENSSL_INCLUDE!$OPENSSL_INCLUDE$ac_delim OPENSSL_DIR!$OPENSSL_DIR$ac_delim PBX_OPENSSL!$PBX_OPENSSL$ac_delim FREETDS_LIB!$FREETDS_LIB$ac_delim -FREETDS_INCLUDE!$FREETDS_INCLUDE$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then @@ -50279,6 +50323,7 @@ _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF +FREETDS_INCLUDE!$FREETDS_INCLUDE$ac_delim FREETDS_DIR!$FREETDS_DIR$ac_delim PBX_FREETDS!$PBX_FREETDS$ac_delim TERMCAP_LIB!$TERMCAP_LIB$ac_delim @@ -50352,7 +50397,7 @@ CURL_CONFIG!$CURL_CONFIG$ac_delim LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 71; then + if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 72; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 diff --git a/configure.ac b/configure.ac index 9d6b4416e..b882d9440 100644 --- a/configure.ac +++ b/configure.ac @@ -177,6 +177,12 @@ if test "${SOXMIX}" != ":" ; then AC_DEFINE([HAVE_SOXMIX], 1, [Define to 1 if your system has soxmix application.]) fi +AC_CHECK_PROGS([MD5], [md5 md5sum gmd5sum digest]) + +if test "${MD5}" = "digest" ; then + MD5="${MD5} -a md5" +fi + ACX_PTHREAD AC_LANG(C) diff --git a/makeopts.in b/makeopts.in index b3e5c4946..7606f9410 100644 --- a/makeopts.in +++ b/makeopts.in @@ -24,6 +24,7 @@ FETCH=@FETCH@ DOWNLOAD=@DOWNLOAD@ RUBBER=@RUBBER@ KPATHSEA=@KPATHSEA@ +MD5=@MD5@ BUILD_PLATFORM=@BUILD_PLATFORM@ BUILD_CPU=@BUILD_CPU@ |