[asterisk-commits] kpfleming: branch group/new_loader_completion r40660 - in /team/group/new_loa...

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Sun Aug 20 10:55:03 MST 2006


Author: kpfleming
Date: Sun Aug 20 12:55:03 2006
New Revision: 40660

URL: http://svn.digium.com/view/asterisk?rev=40660&view=rev
Log:
more simplification and improvements to cross-compile support

Modified:
    team/group/new_loader_completion/Makefile
    team/group/new_loader_completion/channels/Makefile
    team/group/new_loader_completion/configure
    team/group/new_loader_completion/configure.ac
    team/group/new_loader_completion/include/asterisk/autoconfig.h.in
    team/group/new_loader_completion/main/Makefile
    team/group/new_loader_completion/makeopts.in

Modified: team/group/new_loader_completion/Makefile
URL: http://svn.digium.com/view/asterisk/team/group/new_loader_completion/Makefile?rev=40660&r1=40659&r2=40660&view=diff
==============================================================================
--- team/group/new_loader_completion/Makefile (original)
+++ team/group/new_loader_completion/Makefile Sun Aug 20 12:55:03 2006
@@ -29,22 +29,6 @@
 
 # Create OPTIONS variable
 OPTIONS=
-
-# If cross compiling, define these to suit
-#CROSS_COMPILE=/opt/montavista/pro/devkit/arm/xscale_be/bin/xscale_be-
-#CROSS_COMPILE_BIN=/opt/montavista/pro/devkit/arm/xscale_be/bin/
-#CROSS_COMPILE_TARGET=/opt/montavista/pro/devkit/arm/xscale_be/target
-#CROSS_ARCH=Linux
-#CROSS_PROC=arm
-#SUB_PROC=xscale # or maverick
-
-ifeq ($(CROSS_COMPILE),)
-  OSARCH:=$(shell uname -s)
-  PROC?:=$(shell uname -m)
-else
-  OSARCH=$(CROSS_ARCH)
-  PROC=$(CROSS_PROC)
-endif
 
 ASTTOPDIR:=$(shell pwd)
 
@@ -120,7 +104,7 @@
 MOD_SUBDIR_CFLAGS=-I../include -I../main
 OTHER_SUBDIR_CFLAGS=-I../include
 
-ifeq ($(OSARCH),Linux)
+ifeq ($(OSARCH),linux-gnu)
   ifeq ($(PROC),x86_64)
     # You must have GCC 3.4 to use k8, otherwise use athlon
     PROC=k8
@@ -167,7 +151,7 @@
 endif
 
 ifeq ($(findstring BSD,$(OSARCH)),BSD)
-  ASTCFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include -L$(CROSS_COMPILE_TARGET)/usr/local/lib
+  ASTCFLAGS+=-I/usr/local/include -L/usr/local/lib
 endif
 
 ifneq ($(PROC),ultrasparc)
@@ -179,13 +163,13 @@
 endif
 
 ifeq ($(OSARCH),FreeBSD)
-  BSDVERSION=$(shell make -V OSVERSION -f $(CROSS_COMPILE_TARGET)/usr/share/mk/bsd.port.subdir.mk)
+  BSDVERSION=$(shell make -V OSVERSION -f /usr/share/mk/bsd.port.subdir.mk)
   ASTCFLAGS+=$(shell if test $(BSDVERSION) -lt 500016 ; then echo "-D_THREAD_SAFE"; fi)
   AST_LIBS+=$(shell if test  $(BSDVERSION) -lt 502102 ; then echo "-lc_r"; else echo "-pthread"; fi)
 endif
 
 ifeq ($(OSARCH),NetBSD)
-  ASTCFLAGS+=-pthread -I$(CROSS_COMPILE_TARGET)/usr/pkg/include
+  ASTCFLAGS+=-pthread -I/usr/pkg/include
 endif
 
 ifeq ($(OSARCH),OpenBSD)
@@ -193,7 +177,7 @@
 endif
 
 ifeq ($(OSARCH),SunOS)
-  ASTCFLAGS+=-Wcast-align -DSOLARIS -Iinclude/solaris-compat -I$(CROSS_COMPILE_TARGET)/opt/ssl/include -I$(CROSS_COMPILE_TARGET)/usr/local/ssl/include
+  ASTCFLAGS+=-Wcast-align -DSOLARIS -Iinclude/solaris-compat -I/opt/ssl/include -I/usr/local/ssl/include
 endif
 
 ASTERISKVERSION:=$(shell build_tools/make_version .)
@@ -233,12 +217,12 @@
 # These are used for all but Darwin
   SOLINK=-shared -Xlinker -x
   ifeq ($(findstring BSD,$(OSARCH)),BSD)
-    LDFLAGS+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
+    LDFLAGS+=-L/usr/local/lib
   endif
 endif
 
 ifeq ($(OSARCH),SunOS)
-  SOLINK=-shared -fpic -L$(CROSS_COMPILE_TARGET)/usr/local/ssl/lib
+  SOLINK=-shared -fpic -L/usr/local/ssl/lib
 endif
 
 # This is used when generating the doxygen documentation
@@ -578,7 +562,7 @@
 	echo "PROJECT_NUMBER=$(ASTERISKVERSION)") | doxygen - 
 
 config:
-	@if [ "${OSARCH}" = "Linux" ]; then \
+	@if [ "${OSARCH}" = "linux-gnu" ]; then \
 		if [ -f /etc/redhat-release -o -f /etc/fedora-release ]; then \
 			$(INSTALL) -m 755 contrib/init.d/rc.redhat.asterisk /etc/rc.d/init.d/asterisk; \
 			/sbin/chkconfig --add asterisk; \
@@ -668,7 +652,7 @@
 	@CFLAGS="-include $(ASTTOPDIR)/include/asterisk/autoconfig.h -I$(ASTTOPDIR)/include" PARENTSRC="$(ASTTOPDIR)" $(MAKE) -C menuselect CC="$(HOST_CC)" menuselect
 
 mxml/libmxml.a:
-	@cd mxml && unset CFLAGS AST_LIBS && test -f config.h || CC="$(HOST_CC)" RANLIB="ranlib" ./configure
+	@cd mxml && unset CFLAGS AST_LIBS && test -f config.h || ./configure --build=$(BUILD_PLATFORM) --host=$(BUILD_PLATFORM)
 	$(MAKE) -C mxml libmxml.a
 
 menuselect-tree: $(foreach dir,$(MOD_SUBDIRS),$(wildcard $(dir)/*.c) $(wildcard $(dir)/*.cc)) build_tools/cflags.xml sounds/sounds.xml build_tools/embed_modules.xml

Modified: team/group/new_loader_completion/channels/Makefile
URL: http://svn.digium.com/view/asterisk/team/group/new_loader_completion/channels/Makefile?rev=40660&r1=40659&r2=40660&view=diff
==============================================================================
--- team/group/new_loader_completion/channels/Makefile (original)
+++ team/group/new_loader_completion/channels/Makefile Sun Aug 20 12:55:03 2006
@@ -22,7 +22,7 @@
   H323LIB=-lh323_OpenBSD_x86_r
 endif
 
-ifeq ($(OSARCH),Linux)
+ifeq ($(OSARCH),linux-gnu)
   PTLIB=-lpt_linux_x86_r
   H323LIB=-lh323_linux_x86_r
   CHANH323LIB=-ldl
@@ -85,7 +85,7 @@
 
 chan_alsa.o: busy.h ringtone.h
 
-ifeq ($(OSARCH),Linux)
+ifeq ($(OSARCH),linux-gnu)
 chan_h323.so: chan_h323.o h323_module_interface.so h323/libchanh323.a h323/Makefile.ast
 	$(CC) $(SOLINK) $(H323LDFLAGS) -o $@ $^ h323/libchanh323.a $(H323LDLIBS) -lstdc++
 else

Modified: team/group/new_loader_completion/configure
URL: http://svn.digium.com/view/asterisk/team/group/new_loader_completion/configure?rev=40660&r1=40659&r2=40660&view=diff
==============================================================================
--- team/group/new_loader_completion/configure (original)
+++ team/group/new_loader_completion/configure Sun Aug 20 12:55:03 2006
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.ac Revision: 40558 .
+# From configure.ac Revision: 40597 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.60.
 #
@@ -647,21 +647,21 @@
 host_cpu
 host_vendor
 host_os
-PBX_PLATFORM
-PBX_CPU
-PBX_VENDOR
-PBX_OS
+BUILD_PLATFORM
+BUILD_CPU
+BUILD_VENDOR
+BUILD_OS
+HOST_PLATFORM
+HOST_CPU
+HOST_VENDOR
+HOST_OS
 UNAME
 PBX_OSREV
-OSISWIN32
-PBX_OSTYPE
 CC
 CXX
+LD
 RANLIB
 AR
-NM
-WINDRES
-DLLWRAP
 CFLAGS
 LDFLAGS
 CPPFLAGS
@@ -2003,8 +2003,8 @@
 
 
 
-case "${host}" in
-     *freebsd*)
+case "${host_os}" in
+     freebsd)
      ac_default_prefix=/usr/local
      ;;
      *)
@@ -2022,33 +2022,21 @@
      localstatedir=/var
 fi
 
-### ** Platform.
-
-cat >>confdefs.h <<_ACEOF
-#define PBX_PLATFORM "${host}"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PBX_CPU "${host_cpu}"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PBX_VENDOR "${host_vendor}"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PBX_OS "${host_os}"
-_ACEOF
-
-
-# export some useful defines
-PBX_PLATFORM=${host}
-PBX_CPU=${host_cpu}
-PBX_VENDOR=${host_vendor}
-PBX_OS=${host_os}
+BUILD_PLATFORM=${build}
+BUILD_CPU=${build_cpu}
+BUILD_VENDOR=${build_vendor}
+BUILD_OS=${build_os}
+
+
+
+
+
+
+HOST_PLATFORM=${host}
+HOST_CPU=${host_cpu}
+HOST_VENDOR=${host_vendor}
+HOST_OS=${host_os}
+
 
 
 
@@ -2162,86 +2150,6 @@
 fi
 
 
-# guest OS type
-case "${host}" in
-  cygwin*|mingw*|windows*|winnt)
-
-cat >>confdefs.h <<\_ACEOF
-#define Win32 1
-_ACEOF
-
-    PBX_OSTYPE="CYGWIN"
-# this is ugly - KPF
-  OSISWIN32=1
-
-    ;;
-  *linux*)
-
-cat >>confdefs.h <<\_ACEOF
-#define Linux 1
-_ACEOF
-
-    PBX_OSTYPE="Linux"
-    ;;
-  *netbsd*)
-
-cat >>confdefs.h <<\_ACEOF
-#define NetBSD 1
-_ACEOF
-
-    PBX_OSTYPE="NetBSD"
-    ;;
-  *freebsd*)
-
-cat >>confdefs.h <<\_ACEOF
-#define FreeBSD 1
-_ACEOF
-
-    PBX_OSTYPE="FreeBSD"
-    # XXX temporary hack to let FreeBSD use the default paths
-    # for local stuff. We need a better solution.
-    if test x"${CPPFLAGS}" = x; then
-        CPPFLAGS="-I/usr/local/include"
-    fi
-    if test x"${LDFLAGS}" = x; then
-        LDFLAGS="-L/usr/local/lib"
-    fi
-    ;;
-  *openbsd*)
-
-cat >>confdefs.h <<\_ACEOF
-#define OpenBSD 1
-_ACEOF
-
-    PBX_OSTYPE="OpenBSD"
-    ;;
-  *sun*)
-
-cat >>confdefs.h <<\_ACEOF
-#define SunOS 1
-_ACEOF
-
-    PBX_OSTYPE="SunOS"
-    ;;
-  *darwin*)
-
-cat >>confdefs.h <<\_ACEOF
-#define Darwin 1
-_ACEOF
-
-    PBX_OSTYPE="Darwin"
-    ;;
-  *)
-
-cat >>confdefs.h <<\_ACEOF
-#define Unix 1
-_ACEOF
-
-    PBX_OSTYPE="Unix"
-   ;;
-esac
-
-
 # This needs to be before any macros that use the C compiler
 
 cat >>confdefs.h <<\_ACEOF
@@ -2257,7 +2165,7 @@
 
 
 # cross-compile checks
-if test x"${build}" != x"${host}";
+if test "${cross_compiling}" = "yes";
 then
    if test -n "$ac_tool_prefix"; then
   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
@@ -2452,6 +2360,102 @@
 fi
 
    if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
+set dummy ${ac_tool_prefix}ld; 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_LD+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$LD"; then
+  ac_cv_prog_LD="$LD" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_LD="${ac_tool_prefix}ld"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
+
+fi
+fi
+LD=$ac_cv_prog_LD
+if test -n "$LD"; then
+  { echo "$as_me:$LINENO: result: $LD" >&5
+echo "${ECHO_T}$LD" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+
+fi
+if test -z "$ac_cv_prog_LD"; then
+  ac_ct_LD=$LD
+  # Extract the first word of "ld", so it can be a program name with args.
+set dummy ld; 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_ac_ct_LD+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$ac_ct_LD"; then
+  ac_cv_prog_ac_ct_LD="$ac_ct_LD" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_LD="ld"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_LD=$ac_cv_prog_ac_ct_LD
+if test -n "$ac_ct_LD"; then
+  { echo "$as_me:$LINENO: result: $ac_ct_LD" >&5
+echo "${ECHO_T}$ac_ct_LD" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+  if test "x$ac_ct_LD" = x; then
+    LD=":"
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf at gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf at gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+    LD=$ac_ct_LD
+  fi
+else
+  LD="$ac_cv_prog_LD"
+fi
+
+   if test -n "$ac_tool_prefix"; then
   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
 { echo "$as_me:$LINENO: checking for $ac_word" >&5
@@ -2643,299 +2647,6 @@
   AR="$ac_cv_prog_AR"
 fi
 
-
-   if test x"${PBX_OSTYPE}" = xWin32;
-   then
-      if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nm; 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_NM+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$NM"; then
-  ac_cv_prog_NM="$NM" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_NM="${ac_tool_prefix}nm"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-NM=$ac_cv_prog_NM
-if test -n "$NM"; then
-  { echo "$as_me:$LINENO: result: $NM" >&5
-echo "${ECHO_T}$NM" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NM"; then
-  ac_ct_NM=$NM
-  # Extract the first word of "nm", so it can be a program name with args.
-set dummy nm; 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_ac_ct_NM+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_NM"; then
-  ac_cv_prog_ac_ct_NM="$ac_ct_NM" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_NM="nm"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NM=$ac_cv_prog_ac_ct_NM
-if test -n "$ac_ct_NM"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_NM" >&5
-echo "${ECHO_T}$ac_ct_NM" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-  if test "x$ac_ct_NM" = x; then
-    NM=":"
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    NM=$ac_ct_NM
-  fi
-else
-  NM="$ac_cv_prog_NM"
-fi
-
-      if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
-set dummy ${ac_tool_prefix}windres; 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_WINDRES+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$WINDRES"; then
-  ac_cv_prog_WINDRES="$WINDRES" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDRES=$ac_cv_prog_WINDRES
-if test -n "$WINDRES"; then
-  { echo "$as_me:$LINENO: result: $WINDRES" >&5
-echo "${ECHO_T}$WINDRES" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_WINDRES"; then
-  ac_ct_WINDRES=$WINDRES
-  # Extract the first word of "windres", so it can be a program name with args.
-set dummy windres; 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_ac_ct_WINDRES+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_WINDRES"; then
-  ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_WINDRES="windres"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
-if test -n "$ac_ct_WINDRES"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
-echo "${ECHO_T}$ac_ct_WINDRES" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-  if test "x$ac_ct_WINDRES" = x; then
-    WINDRES=":"
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    WINDRES=$ac_ct_WINDRES
-  fi
-else
-  WINDRES="$ac_cv_prog_WINDRES"
-fi
-
-      if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dllwrap; 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_DLLWRAP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$DLLWRAP"; then
-  ac_cv_prog_DLLWRAP="$DLLWRAP" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLWRAP=$ac_cv_prog_DLLWRAP
-if test -n "$DLLWRAP"; then
-  { echo "$as_me:$LINENO: result: $DLLWRAP" >&5
-echo "${ECHO_T}$DLLWRAP" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_DLLWRAP"; then
-  ac_ct_DLLWRAP=$DLLWRAP
-  # Extract the first word of "dllwrap", so it can be a program name with args.
-set dummy dllwrap; 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_ac_ct_DLLWRAP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_DLLWRAP"; then
-  ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # 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_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
-if test -n "$ac_ct_DLLWRAP"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
-echo "${ECHO_T}$ac_ct_DLLWRAP" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-  if test "x$ac_ct_DLLWRAP" = x; then
-    DLLWRAP=":"
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    DLLWRAP=$ac_ct_DLLWRAP
-  fi
-else
-  DLLWRAP="$ac_cv_prog_DLLWRAP"
-fi
-
-   fi
-   crossCompile="Yes"
 fi
 
 # Checks for programs.
@@ -27586,7 +27297,7 @@
 fi
 
 
-if test "${PBX_OSTYPE}" != "Linux" ; then
+if test "${host_os}" != "linux-gnu" ; then
   tonezone_extra="-lm"
 fi
 
@@ -29658,7 +29369,7 @@
 
 if test ! x"${CURL}" = xNo; then
 # check for version
-   if test $PBX_OSTYPE = "SunOS"; then
+   if test "${host_os}" = "SunOS"; then
       if [ 0x`curl-config --vernum` -ge 0x70907 ]; then
          CURLLIB=$(${CURL} --libs)
          PBX_CURL=1
@@ -30334,21 +30045,21 @@
 host_cpu!$host_cpu$ac_delim
 host_vendor!$host_vendor$ac_delim
 host_os!$host_os$ac_delim
-PBX_PLATFORM!$PBX_PLATFORM$ac_delim
-PBX_CPU!$PBX_CPU$ac_delim
-PBX_VENDOR!$PBX_VENDOR$ac_delim
-PBX_OS!$PBX_OS$ac_delim
+BUILD_PLATFORM!$BUILD_PLATFORM$ac_delim
+BUILD_CPU!$BUILD_CPU$ac_delim
+BUILD_VENDOR!$BUILD_VENDOR$ac_delim
+BUILD_OS!$BUILD_OS$ac_delim
+HOST_PLATFORM!$HOST_PLATFORM$ac_delim
+HOST_CPU!$HOST_CPU$ac_delim
+HOST_VENDOR!$HOST_VENDOR$ac_delim
+HOST_OS!$HOST_OS$ac_delim
 UNAME!$UNAME$ac_delim
 PBX_OSREV!$PBX_OSREV$ac_delim
-OSISWIN32!$OSISWIN32$ac_delim
-PBX_OSTYPE!$PBX_OSTYPE$ac_delim
 CC!$CC$ac_delim
 CXX!$CXX$ac_delim
+LD!$LD$ac_delim
 RANLIB!$RANLIB$ac_delim
 AR!$AR$ac_delim
-NM!$NM$ac_delim
-WINDRES!$WINDRES$ac_delim
-DLLWRAP!$DLLWRAP$ac_delim
 CFLAGS!$CFLAGS$ac_delim
 LDFLAGS!$LDFLAGS$ac_delim
 CPPFLAGS!$CPPFLAGS$ac_delim
@@ -31041,17 +30752,13 @@
 
 { echo "$as_me:$LINENO: Package configured for: " >&5
 echo "$as_me: Package configured for: " >&6;}
-{ echo "$as_me:$LINENO: OS type  : $PBX_OSTYPE" >&5
-echo "$as_me: OS type  : $PBX_OSTYPE" >&6;}
+{ echo "$as_me:$LINENO: OS type  : $host_os" >&5
+echo "$as_me: OS type  : $host_os" >&6;}
 { echo "$as_me:$LINENO: Host CPU : $host_cpu" >&5
 echo "$as_me: Host CPU : $host_cpu" >&6;}
-if test "x${crossCompile}" = xYes; then
-   { echo "$as_me:$LINENO: " >&5
-echo "$as_me: " >&6;}
+if test "${cross_compiling}" = "yes"; then
    { echo "$as_me:$LINENO: Cross Compilation = YES" >&5
 echo "$as_me: Cross Compilation = YES" >&6;}
-   { echo "$as_me:$LINENO: Target            = ${host}" >&5
-echo "$as_me: Target            = ${host}" >&6;}
 fi
 
 if test ${GNU_MAKE_VERSION_MAJOR} -lt 3 || test ${GNU_MAKE_VERSION_MINOR} -lt 81 ; then

Modified: team/group/new_loader_completion/configure.ac
URL: http://svn.digium.com/view/asterisk/team/group/new_loader_completion/configure.ac?rev=40660&r1=40659&r2=40660&view=diff
==============================================================================
--- team/group/new_loader_completion/configure.ac (original)
+++ team/group/new_loader_completion/configure.ac Sun Aug 20 12:55:03 2006
@@ -21,8 +21,8 @@
 AC_COPYRIGHT("Asterisk")
 AC_REVISION($Revision$)
 
-case "${host}" in
-     *freebsd*)
+case "${host_os}" in
+     freebsd)
      ac_default_prefix=/usr/local
      ;;
      *)
@@ -40,25 +40,25 @@
      localstatedir=/var
 fi
 
-### ** Platform.
-AC_DEFINE_UNQUOTED(PBX_PLATFORM, "${host}",
-[Define this to be the canonical name (cpu-vendor-os) of your system.])
-AC_DEFINE_UNQUOTED(PBX_CPU, "${host_cpu}",
-[Define this to be the name of the CPU of your system.])
-AC_DEFINE_UNQUOTED(PBX_VENDOR, "${host_vendor}",
-[Define this to be the name of the vendor of your system.])
-AC_DEFINE_UNQUOTED(PBX_OS, "${host_os}",
-[Define this to be the name of the OS of your system.])
-
-# export some useful defines
-PBX_PLATFORM=${host}
-PBX_CPU=${host_cpu}
-PBX_VENDOR=${host_vendor}
-PBX_OS=${host_os}
-AC_SUBST(PBX_PLATFORM)
-AC_SUBST(PBX_CPU)
-AC_SUBST(PBX_VENDOR)
-AC_SUBST(PBX_OS)
+BUILD_PLATFORM=${build}
+BUILD_CPU=${build_cpu}
+BUILD_VENDOR=${build_vendor}
+BUILD_OS=${build_os}
+
+AC_SUBST(BUILD_PLATFORM)
+AC_SUBST(BUILD_CPU)
+AC_SUBST(BUILD_VENDOR)
+AC_SUBST(BUILD_OS)
+
+HOST_PLATFORM=${host}
+HOST_CPU=${host_cpu}
+HOST_VENDOR=${host_vendor}
+HOST_OS=${host_os}
+
+AC_SUBST(HOST_PLATFORM)
+AC_SUBST(HOST_CPU)
+AC_SUBST(HOST_VENDOR)
+AC_SUBST(HOST_OS)
 
 #  check for uname
 AC_PATH_TOOL([UNAME], [uname], No)
@@ -67,62 +67,6 @@
 fi
 AC_SUBST(PBX_OSREV)
 
-# guest OS type
-case "${host}" in
-  cygwin*|mingw*|windows*|winnt)
-    AC_DEFINE(Win32, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="CYGWIN"
-# this is ugly - KPF
-  OSISWIN32=1
-  AC_SUBST(OSISWIN32)
-    ;;
-  *linux*)
-    AC_DEFINE(Linux, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="Linux"
-    ;;
-  *netbsd*)
-    AC_DEFINE(NetBSD, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="NetBSD"
-    ;;
-  *freebsd*)
-    AC_DEFINE(FreeBSD, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="FreeBSD"
-    # XXX temporary hack to let FreeBSD use the default paths
-    # for local stuff. We need a better solution.
-    if test x"${CPPFLAGS}" = x; then
-        CPPFLAGS="-I/usr/local/include"
-    fi
-    if test x"${LDFLAGS}" = x; then
-        LDFLAGS="-L/usr/local/lib"
-    fi
-    ;;
-  *openbsd*)
-    AC_DEFINE(OpenBSD, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="OpenBSD"
-    ;;
-  *sun*)
-    AC_DEFINE(SunOS, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="SunOS"
-    ;;
-  *darwin*)
-    AC_DEFINE(Darwin, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="Darwin"
-    ;;
-  *)
-    AC_DEFINE(Unix, 1,
-              [Define according to your operating system type.])
-    PBX_OSTYPE="Unix"
-   ;;
-esac
-AC_SUBST(PBX_OSTYPE)
-
 # This needs to be before any macros that use the C compiler
 AC_GNU_SOURCE
 
@@ -144,20 +88,13 @@
 )
 
 # cross-compile checks
-if test x"${build}" != x"${host}"; 
+if test "${cross_compiling}" = "yes"; 
 then
    AC_CHECK_TOOL(CC, gcc, :)
    AC_CHECK_TOOL(CXX, g++, :)
+   AC_CHECK_TOOL(LD, ld, :)
    AC_CHECK_TOOL(RANLIB, ranlib, :)
    AC_CHECK_TOOL(AR, ar, :)
-
-   if test x"${PBX_OSTYPE}" = xWin32;
-   then
-      AC_CHECK_TOOL(NM, nm, :)
-      AC_CHECK_TOOL(WINDRES, windres, :)
-      AC_CHECK_TOOL(DLLWRAP, dllwrap, :)
-   fi
-   crossCompile="Yes"
 fi
 
 # Checks for programs.
@@ -832,7 +769,7 @@
 
 AST_EXT_LIB_CHECK([TINFO], [tinfo], [tgetent], [])
 
-if test "${PBX_OSTYPE}" != "Linux" ; then
+if test "${host_os}" != "linux-gnu" ; then
   tonezone_extra="-lm"
 fi
 
@@ -969,7 +906,7 @@
 AC_PATH_TOOL([CURL], [curl-config], No)
 if test ! x"${CURL}" = xNo; then
 # check for version
-   if test $PBX_OSTYPE = "SunOS"; then
+   if test "${host_os}" = "SunOS"; then
       if [[ 0x`curl-config --vernum` -ge 0x70907 ]]; then
          CURLLIB=$(${CURL} --libs)
          PBX_CURL=1
@@ -1016,12 +953,10 @@
 fi
 
 AC_MSG_NOTICE(Package configured for: )
-AC_MSG_NOTICE( OS type  : $PBX_OSTYPE)
+AC_MSG_NOTICE( OS type  : $host_os)
 AC_MSG_NOTICE( Host CPU : $host_cpu)
-if test "x${crossCompile}" = xYes; then
-   AC_MSG_NOTICE()
+if test "${cross_compiling}" = "yes"; then
    AC_MSG_NOTICE( Cross Compilation = YES)
-   AC_MSG_NOTICE( Target            = ${host})
 fi
 
 if test ${GNU_MAKE_VERSION_MAJOR} -lt 3 || test ${GNU_MAKE_VERSION_MINOR} -lt 81 ; then

Modified: team/group/new_loader_completion/include/asterisk/autoconfig.h.in
URL: http://svn.digium.com/view/asterisk/team/group/new_loader_completion/include/asterisk/autoconfig.h.in?rev=40660&r1=40659&r2=40660&view=diff
==============================================================================
--- team/group/new_loader_completion/include/asterisk/autoconfig.h.in (original)
+++ team/group/new_loader_completion/include/asterisk/autoconfig.h.in Sun Aug 20 12:55:03 2006
@@ -23,12 +23,6 @@
 /* Define to 1 if using `alloca.c'. */
 #undef C_ALLOCA
 
-/* Define according to your operating system type. */
-#undef Darwin
-
-/* Define according to your operating system type. */
-#undef FreeBSD
-
 /* Define to 1 if you have the `alarm' function. */
 #undef HAVE_ALARM
 
@@ -479,15 +473,6 @@
    slash. */
 #undef LSTAT_FOLLOWS_SLASHED_SYMLINK
 
-/* Define according to your operating system type. */
-#undef Linux
-
-/* Define according to your operating system type. */
-#undef NetBSD
-
-/* Define according to your operating system type. */
-#undef OpenBSD
-
 /* Define to the address where bug reports for this package should be sent. */
 #undef PACKAGE_BUGREPORT
 
@@ -502,18 +487,6 @@
 
 /* Define to the version of this package. */
 #undef PACKAGE_VERSION
-
-/* Define this to be the name of the CPU of your system. */
-#undef PBX_CPU
-
-/* Define this to be the name of the OS of your system. */
-#undef PBX_OS
-
-/* Define this to be the canonical name (cpu-vendor-os) of your system. */
-#undef PBX_PLATFORM
-
-/* Define this to be the name of the vendor of your system. */
-#undef PBX_VENDOR
 
 /* Define to 1 if the C compiler supports function prototypes. */
 #undef PROTOTYPES
@@ -549,20 +522,11 @@
 /* Define to 1 if you have the ANSI C header files. */
 #undef STDC_HEADERS
 
-/* Define according to your operating system type. */
-#undef SunOS
-
 /* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
 #undef TIME_WITH_SYS_TIME
 
 /* Define to 1 if your <sys/time.h> declares `struct tm'. */
 #undef TM_IN_SYS_TIME
-
-/* Define according to your operating system type. */
-#undef Unix
-
-/* Define according to your operating system type. */
-#undef Win32
 
 /* Number of bits in a file offset, on hosts where this is settable. */
 #undef _FILE_OFFSET_BITS

Modified: team/group/new_loader_completion/main/Makefile
URL: http://svn.digium.com/view/asterisk/team/group/new_loader_completion/main/Makefile?rev=40660&r1=40659&r2=40660&view=diff
==============================================================================
--- team/group/new_loader_completion/main/Makefile (original)
+++ team/group/new_loader_completion/main/Makefile Sun Aug 20 12:55:03 2006
@@ -43,15 +43,15 @@
 # by a module.
 OBJS+=say.o
 
-ifeq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/sys/poll.h),)
+ifeq ($(wildcard /usr/include/sys/poll.h),)
   OBJS+=poll.o
 endif
 
-ifeq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/dlfcn.h),)
+ifeq ($(wildcard /usr/include/dlfcn.h),)
   OBJS+=dlfcn.o
 endif
 
-ifeq ($(OSARCH),Linux)
+ifeq ($(OSARCH),linux-gnu)
   ifneq ($(findstring LOADABLE_MODULES,$(MENUSELECT_CFLAGS)),)
   AST_LIBS+=-ldl
   endif
@@ -72,7 +72,7 @@
 # These are used for all but Darwin
   ASTLINK=-Wl,-E 
   ifeq ($(findstring BSD,$(OSARCH)),BSD)
-    LDFLAGS+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
+    LDFLAGS+=-L/usr/local/lib
   endif
 endif
 
@@ -81,7 +81,7 @@
 endif
 
 ifeq ($(OSARCH),NetBSD)
-  AST_LIBS+=-lpthread -lcrypto -lm -L$(CROSS_COMPILE_TARGET)/usr/pkg/lib $(EDITLINE_LIB)
+  AST_LIBS+=-lpthread -lcrypto -lm -L/usr/pkg/lib $(EDITLINE_LIB)
 endif
 
 ifeq ($(OSARCH),OpenBSD)
@@ -89,13 +89,13 @@
 endif
 
 ifeq ($(OSARCH),SunOS)
-  AST_LIBS+=-lpthread -ldl -lnsl -lsocket -lresolv -L$(CROSS_COMPILE_TARGET)/opt/ssl/lib -L$(CROSS_COMPILE_TARGET)/usr/local/ssl/lib
+  AST_LIBS+=-lpthread -ldl -lnsl -lsocket -lresolv -L/opt/ssl/lib -L/usr/local/ssl/lib
   OBJS+=strcompat.o
   ASTLINK=
 endif
 
 editline/libedit.a:
-	cd editline && unset CFLAGS AST_LIBS && test -f config.h || CFLAGS="$(OPTIMIZE)" ./configure
+	cd editline && unset CFLAGS AST_LIBS && test -f config.h || CFLAGS="$(OPTIMIZE)" ./configure --build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)
 	$(MAKE) -C editline libedit.a
 
 db1-ast/libdb1.a:

Modified: team/group/new_loader_completion/makeopts.in
URL: http://svn.digium.com/view/asterisk/team/group/new_loader_completion/makeopts.in?rev=40660&r1=40659&r2=40660&view=diff
==============================================================================
--- team/group/new_loader_completion/makeopts.in (original)
+++ team/group/new_loader_completion/makeopts.in Sun Aug 20 12:55:03 2006
@@ -18,10 +18,18 @@
 QTMOC=@QTMOC@
 DOT=@DOT@
 
-CROSS_ARCH=@PBX_OSTYPE@
-CROSS_PROC=@PBX_CPU@
-PROC=@PBX_CPU@
-OSARCH=@PBX_OSTYPE@
+BUILD_PLATFORM=@BUILD_PLATFORM@
+BUILD_CPU=@BUILD_CPU@
+BUILD_VENDOR=@BUILD_VENDOR@
+BUILD_OS=@BUILD_OS@
+
+HOST_PLATFORM=@HOST_PLATFORM@
+HOST_CPU=@HOST_CPU@
+HOST_VENDOR=@HOST_VENDOR@
+HOST_OS=@HOST_OS@
+
+PROC=@HOST_CPU@
+OSARCH=@HOST_OS@
 OSREV=@PBX_OSREV@
 
 prefix = @prefix@



More information about the asterisk-commits mailing list