improve configure script to remember the previous value of each dependency in build_t...
authorKevin P. Fleming <kpfleming@digium.com>
Tue, 4 Nov 2008 15:07:54 +0000 (15:07 +0000)
committerKevin P. Fleming <kpfleming@digium.com>
Tue, 4 Nov 2008 15:07:54 +0000 (15:07 +0000)
along the way, change tags used in configure script, menuselect-deps and code for various dependencies to be consistently named

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@154151 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 files changed:
apps/app_osplookup.c
apps/app_voicemail.c
build_tools/menuselect-deps.in
cdr/cdr_adaptive_odbc.c
cdr/cdr_odbc.c
channels/chan_alsa.c
channels/chan_oss.c
channels/chan_usbradio.c
channels/chan_vpb.cc
configure
configure.ac
funcs/func_odbc.c
makeopts.in
res/res_config_odbc.c
res/res_crypto.c
res/res_odbc.c

index 03f3dbc..3c2b2ea 100644 (file)
@@ -30,7 +30,7 @@
 
 /*** MODULEINFO
        <depend>osptk</depend>
-       <depend>ssl</depend>
+       <depend>openssl</depend>
  ***/
 
 #include "asterisk.h"
index d01ce3d..3338de8 100644 (file)
@@ -47,7 +47,7 @@ c-client (http://www.washington.edu/imap/
 /*** MAKEOPTS
 <category name="MENUSELECT_OPTS_app_voicemail" displayname="Voicemail Build Options" positive_output="yes" remove_on_change="apps/app_voicemail.o apps/app_directory.o">
        <member name="ODBC_STORAGE" displayname="Storage of Voicemail using ODBC">
-               <depend>unixodbc_or_iodbc</depend>
+               <depend>odbc</depend>
                <depend>ltdl</depend>
                <use>unixodbc</use>
                <use>iodbc</use>
@@ -57,7 +57,7 @@ c-client (http://www.washington.edu/imap/
        <member name="IMAP_STORAGE" displayname="Storage of Voicemail using IMAP4">
                <depend>imap_tk</depend>
                <conflict>ODBC_STORAGE</conflict>
-               <use>ssl</use>
+               <use>openssl</use>
                <defaultenabled>no</defaultenabled>
        </member>
 </category>
index 1e1319a..e976079 100644 (file)
@@ -1,4 +1,4 @@
-ASOUND=@PBX_ALSA@
+ALSA=@PBX_ALSA@
 CRYPTO=@PBX_CRYPTO@
 CURL=@PBX_CURL@
 DAHDI=@PBX_DAHDI@
@@ -24,11 +24,11 @@ MISDN=@PBX_MISDN@
 NBS=@PBX_NBS@
 NETSNMP=@PBX_NETSNMP@
 NEWT=@PBX_NEWT@
-UNIXODBC_OR_IODBC=@PBX_ODBC@
+ODBC=@PBX_ODBC@
 OGG=@PBX_OGG@
 OPENH323=@PBX_OPENH323@
 OSPTK=@PBX_OSPTK@
-OSSAUDIO=@PBX_OSS@
+OSS=@PBX_OSS@
 PGSQL=@PBX_PGSQL@
 POPT=@PBX_POPT@
 PORTAUDIO=@PBX_PORTAUDIO@
@@ -43,12 +43,12 @@ SPEEX_PREPROCESS=@PBX_SPEEX_PREPROCESS@
 SQLITE3=@PBX_SQLITE3@
 SQLITE=@PBX_SQLITE@
 SS7=@PBX_SS7@
-SSL=@PBX_OPENSSL@
+OPENSSL=@PBX_OPENSSL@
 SUPPSERV=@PBX_SUPPSERV@
 TONEZONE=@PBX_TONEZONE@
 UNIXODBC=@PBX_UNIXODBC@
 USB=@PBX_USB@
 VORBIS=@PBX_VORBIS@
-VPBAPI=@PBX_VPB@
-WINARCH=@WINARCH@
+VPB=@PBX_VPB@
+WINARCH=@PBX_WINARCH@
 ZLIB=@PBX_ZLIB@
index edc01e7..b254ad6 100644 (file)
@@ -25,7 +25,7 @@
  */
 
 /*** MODULEINFO
-       <depend>unixodbc_or_iodbc</depend>
+       <depend>odbc</depend>
        <use>unixodbc</use>
        <use>iodbc</use>
  ***/
index df93290..d4db02b 100644 (file)
@@ -29,7 +29,7 @@
  */
 
 /*** MODULEINFO
-       <depend>unixodbc_or_iodbc</depend>
+       <depend>odbc</depend>
        <depend>ltdl</depend>
        <use>unixodbc</use>
        <use>iodbc</use>
index 66fecd5..30c728a 100644 (file)
@@ -28,7 +28,7 @@
  */
 
 /*** MODULEINFO
-       <depend>asound</depend>
+       <depend>alsa</depend>
  ***/
 
 #include "asterisk.h"
index 186e3a2..72ab78c 100644 (file)
@@ -34,7 +34,7 @@
  */
 
 /*** MODULEINFO
-       <depend>ossaudio</depend>
+       <depend>oss</depend>
  ***/
 
 #include "asterisk.h"
index a5daebe..bc1dbb3 100644 (file)
@@ -34,7 +34,7 @@
  */
 
 /*** MODULEINFO
-       <depend>ossaudio</depend>
+       <depend>oss</depend>
        <depend>usb</depend>
        <defaultenabled>no</defaultenabled>
  ***/
index e643628..b8ca240 100644 (file)
@@ -30,7 +30,7 @@
  */
 
 /*** MODULEINFO
-       <depend>vpbapi</depend>
+       <depend>vpb</depend>
  ***/
 
 #include <vpbapi.h>
index 3e1b904..6a501cb 100755 (executable)
--- a/configure
+++ b/configure
@@ -683,7 +683,7 @@ HOST_CPU
 HOST_VENDOR
 HOST_OS
 OSARCH
-WINARCH
+PBX_WINARCH
 UNAME
 PBX_OSREV
 CXX
@@ -4116,7 +4116,7 @@ HOST_OS=${host_os}
 
 
 
-WINARCH=0
+PBX_WINARCH=0
 
 case "${host_os}" in
      freebsd*)
@@ -4133,11 +4133,11 @@ case "${host_os}" in
      ;;
      mingw32)
      OSARCH=mingw32
-     WINARCH=1
+     PBX_WINARCH=1
      ;;
      cygwin)
      OSARCH=cygwin
-     WINARCH=1
+     PBX_WINARCH=1
      ;;
      *)
      OSARCH=${host_os}
@@ -50960,6 +50960,16 @@ echo "$as_me: *** including --without-${a}." >&6;}
 echo "${ECHO_T}ok" >&6; }
 
 
+if test -f build_tools/menuselect-deps; then
+    # extract old values of all PBX_ variables from menuselect-deps
+    # and preserve them so that menuselect can determine whether
+    # any previously-met dependencies are no longer met and warn
+    # the user appropriately
+    while IFS="=:" read var val old_val; do
+        eval "PBX_${var}=\${PBX_${var}}:${val}"
+    done < build_tools/menuselect-deps
+fi
+
 cat >confcache <<\_ACEOF
 # This file is a shell script that caches the results of configure
 # tests run on this system so they can be shared between configure
@@ -51642,7 +51652,7 @@ HOST_CPU!$HOST_CPU$ac_delim
 HOST_VENDOR!$HOST_VENDOR$ac_delim
 HOST_OS!$HOST_OS$ac_delim
 OSARCH!$OSARCH$ac_delim
-WINARCH!$WINARCH$ac_delim
+PBX_WINARCH!$PBX_WINARCH$ac_delim
 UNAME!$UNAME$ac_delim
 PBX_OSREV!$PBX_OSREV$ac_delim
 CXX!$CXX$ac_delim
index 43940aa..b3672b6 100644 (file)
@@ -82,7 +82,7 @@ AC_SUBST(HOST_CPU)
 AC_SUBST(HOST_VENDOR)
 AC_SUBST(HOST_OS)
 
-WINARCH=0
+PBX_WINARCH=0
 
 case "${host_os}" in
      freebsd*)
@@ -99,11 +99,11 @@ case "${host_os}" in
      ;;
      mingw32)
      OSARCH=mingw32
-     WINARCH=1
+     PBX_WINARCH=1
      ;;
      cygwin)
      OSARCH=cygwin
-     WINARCH=1
+     PBX_WINARCH=1
      ;;
      *)
      OSARCH=${host_os}
@@ -111,7 +111,7 @@ case "${host_os}" in
 esac
 
 AC_SUBST(OSARCH)
-AC_SUBST(WINARCH)
+AC_SUBST(PBX_WINARCH)
 
 #  check for uname
 AC_PATH_TOOL([UNAME], [uname], No)
@@ -1649,6 +1649,16 @@ fi
 AC_CONFIG_FILES([build_tools/menuselect-deps makeopts channels/h323/Makefile])
 AST_CHECK_MANDATORY
 
+if test -f build_tools/menuselect-deps; then
+    # extract old values of all PBX_ variables from menuselect-deps
+    # and preserve them so that menuselect can determine whether
+    # any previously-met dependencies are no longer met and warn
+    # the user appropriately
+    while IFS="=:" read var val old_val; do
+        eval "PBX_${var}=\${PBX_${var}}:${val}"
+    done < build_tools/menuselect-deps
+fi
+
 AC_OUTPUT
 
 if test "x${silent}" != "xyes" ; then
index 41f5d7b..23cc4f8 100644 (file)
@@ -27,7 +27,7 @@
  */
 
 /*** MODULEINFO
-       <depend>unixodbc_or_iodbc</depend>
+       <depend>odbc</depend>
        <depend>ltdl</depend>
        <depend>res_odbc</depend>
        <use>unixodbc</use>
index eeccc1f..3856d89 100644 (file)
@@ -68,8 +68,8 @@ AST_DECLARATION_AFTER_STATEMENT=@AST_DECLARATION_AFTER_STATEMENT@
 AST_NO_STRICT_OVERFLOW=@AST_NO_STRICT_OVERFLOW@
 AST_SHADOW_WARNINGS=@AST_SHADOW_WARNINGS@
 
-ASOUND_INCLUDE=@ALSA_INCLUDE@
-ASOUND_LIB=@ALSA_LIB@
+ALSA_INCLUDE=@ALSA_INCLUDE@
+ALSA_LIB=@ALSA_LIB@
 
 CURL_INCLUDE=@CURL_INCLUDE@
 CURL_LIB=@CURL_LIB@
@@ -140,8 +140,8 @@ OSPTK_LIB=@OSPTK_LIB@
 
 # ossaudio can optionally use ffmpeg, x11, sdl and sdl_image.
 # Because sdl_image in turn depends on sdl, we don't duplicate the include
-OSSAUDIO_INCLUDE=@OSS_INCLUDE@ @FFMPEG_INCLUDE@ @SDL_INCLUDE@ @X11_INCLUDE@
-OSSAUDIO_LIB=@OSS_LIB@ @FFMPEG_LIB@ @SDL_LIB@ @SDL_IMAGE_LIB@ @X11_LIB@
+OSS_INCLUDE=@OSS_INCLUDE@ @FFMPEG_INCLUDE@ @SDL_INCLUDE@ @X11_INCLUDE@
+OSS_LIB=@OSS_LIB@ @FFMPEG_LIB@ @SDL_LIB@ @SDL_IMAGE_LIB@ @X11_LIB@
 
 PGSQL_INCLUDE=@PGSQL_INCLUDE@
 PGSQL_LIB=@PGSQL_LIB@
@@ -197,8 +197,8 @@ SQLITE_LIB=@SQLITE_LIB@
 SQLITE3_INCLUDE=@SQLITE3_INCLUDE@
 SQLITE3_LIB=@SQLITE3_LIB@
 
-SSL_INCLUDE=@OPENSSL_INCLUDE@
-SSL_LIB=@OPENSSL_LIB@
+OPENSSL_INCLUDE=@OPENSSL_INCLUDE@
+OPENSSL_LIB=@OPENSSL_LIB@
 
 CRYPTO_INCLUDE=@CRYPTO_INCLUDE@
 CRYPTO_LIB=@CRYPTO_LIB@
@@ -215,8 +215,8 @@ UNIXODBC_LIB=@UNIXODBC_LIB@
 VORBIS_INCLUDE=@VORBIS_INCLUDE@
 VORBIS_LIB=@VORBIS_LIB@
 
-VPBAPI_INCLUDE=@VPB_INCLUDE@
-VPBAPI_LIB=@VPB_LIB@
+VPB_INCLUDE=@VPB_INCLUDE@
+VPB_LIB=@VPB_LIB@
 
 DAHDI_INCLUDE=@DAHDI_INCLUDE@
 
index ea83652..a815a9d 100644 (file)
@@ -29,7 +29,7 @@
  */
 
 /*** MODULEINFO
-       <depend>unixodbc_or_iodbc</depend>
+       <depend>odbc</depend>
        <depend>ltdl</depend>
        <depend>res_odbc</depend>
        <use>unixodbc</use>
index e55abe8..5d2d286 100644 (file)
@@ -27,7 +27,7 @@
  */
 
 /*** MODULEINFO
-       <depend>ssl</depend>
+       <depend>openssl</depend>
  ***/
 
 #include "asterisk.h"
index a16f79a..67089a9 100644 (file)
@@ -30,7 +30,7 @@
  */
 
 /*** MODULEINFO
-       <depend>unixodbc_or_iodbc</depend>
+       <depend>odbc</depend>
        <depend>ltdl</depend>
        <use>unixodbc</use>
        <use>iodbc</use>