[zaptel-commits] tzafrir: branch 1.4 r3198 - in /branches/1.4: ./ build_tools/ firmware/
SVN commits to the Zaptel project
zaptel-commits at lists.digium.com
Sun Oct 28 13:26:04 CDT 2007
Author: tzafrir
Date: Sun Oct 28 13:26:04 2007
New Revision: 3198
URL: http://svn.digium.com/view/zaptel?view=rev&rev=3198
Log:
Firmware object file building does not depend anymore on another object
to be linked into the same module.
That dependency existed solely for checking target binary properties in
make_firmware_object . Those properties are now checked in autoconf.
Added:
branches/1.4/build_tools/make_firmware_object.in
- copied, changed from r3189, branches/1.4/build_tools/make_firmware_object
Removed:
branches/1.4/build_tools/make_firmware_object
Modified:
branches/1.4/configure
branches/1.4/configure.ac
branches/1.4/firmware/Makefile
Copied: branches/1.4/build_tools/make_firmware_object.in (from r3189, branches/1.4/build_tools/make_firmware_object)
URL: http://svn.digium.com/view/zaptel/branches/1.4/build_tools/make_firmware_object.in?view=diff&rev=3198&p1=branches/1.4/build_tools/make_firmware_object&r1=3189&p2=branches/1.4/build_tools/make_firmware_object.in&r2=3198
==============================================================================
--- branches/1.4/build_tools/make_firmware_object (original)
+++ branches/1.4/build_tools/make_firmware_object.in Sun Oct 28 13:26:04 2007
@@ -4,9 +4,8 @@
# arguments:
# 1 - firmware file
# 2 - output file
-# 3 - template output file (used to learn desired format)
-bfdname=`LANG=C objdump -f ${3} | grep -e "${3}:" | sed "s/.*file format \(.*\)/\1/"`
-bfdarch=`LANG=C objdump -f ${3} | grep -e "architecture:" | sed "s/.*ture: \(.*\),.*/\1/"`
+bfdname=@BDFNAME@
+bfdarch=@BDFARCH@
objcopy -I binary ${1} -B ${bfdarch} -O ${bfdname} ${2} --rename-section .data=.rodata,alloc,load,data,contents,readonly
Modified: branches/1.4/configure
URL: http://svn.digium.com/view/zaptel/branches/1.4/configure?view=diff&rev=3198&r1=3197&r2=3198
==============================================================================
--- branches/1.4/configure (original)
+++ branches/1.4/configure Sun Oct 28 13:26:04 2007
@@ -1,5 +1,5 @@
#! /bin/sh
-# From configure.ac Revision: 2999 .
+# From configure.ac Revision: 3195 .
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.61.
#
@@ -667,6 +667,8 @@
INSTALL_DATA
LN_S
GNU_MAKE
+BDFNAME
+BDFARCH
HOSTCC
GREP
LN
@@ -3034,6 +3036,48 @@
+test_obj=conftest.o
+
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+
+ BDFNAME=`LANG=C objdump -f $test_obj | grep -e "$test_obj:" | sed "s/.*file format \(.*\)/\1/"`
+ BDFARCH=`LANG=C objdump -f $test_obj | grep -e "architecture:" | sed "s/.*ture: \(.*\),.*/\1/"`
+
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
# Set the default value of HOSTCC from CC if --host was not provided:
HOSTCC=${HOSTCC:=${CC}}
@@ -3256,7 +3300,6 @@
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
@@ -5395,7 +5438,7 @@
-ac_config_files="$ac_config_files build_tools/menuselect-deps makeopts"
+ac_config_files="$ac_config_files build_tools/menuselect-deps makeopts build_tools/make_firmware_object"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
@@ -5967,6 +6010,7 @@
case $ac_config_target in
"build_tools/menuselect-deps") CONFIG_FILES="$CONFIG_FILES build_tools/menuselect-deps" ;;
"makeopts") CONFIG_FILES="$CONFIG_FILES makeopts" ;;
+ "build_tools/make_firmware_object") CONFIG_FILES="$CONFIG_FILES build_tools/make_firmware_object" ;;
*) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
@@ -6077,6 +6121,8 @@
INSTALL_DATA!$INSTALL_DATA$ac_delim
LN_S!$LN_S$ac_delim
GNU_MAKE!$GNU_MAKE$ac_delim
+BDFNAME!$BDFNAME$ac_delim
+BDFARCH!$BDFARCH$ac_delim
HOSTCC!$HOSTCC$ac_delim
GREP!$GREP$ac_delim
LN!$LN$ac_delim
@@ -6103,7 +6149,7 @@
LTLIBOBJS!$LTLIBOBJS$ac_delim
_ACEOF
- if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 74; then
+ if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 76; then
break
elif $ac_last_try; then
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
@@ -6435,6 +6481,7 @@
$ac_cs_success || { (exit 1); exit 1; }
fi
+chmod a+x build_tools/make_firmware_object
{ echo "$as_me:$LINENO: *** Zaptel build successfully configured ***" >&5
echo "$as_me: *** Zaptel build successfully configured ***" >&6;}
Modified: branches/1.4/configure.ac
URL: http://svn.digium.com/view/zaptel/branches/1.4/configure.ac?view=diff&rev=3198&r1=3197&r2=3198
==============================================================================
--- branches/1.4/configure.ac (original)
+++ branches/1.4/configure.ac Sun Oct 28 13:26:04 2007
@@ -35,6 +35,14 @@
AC_PROG_INSTALL
AC_PROG_LN_S
AST_CHECK_GNU_MAKE
+
+test_obj=conftest.o
+AC_COMPILE_IFELSE(AC_LANG_SOURCE(),[
+ BDFNAME=`LANG=C objdump -f $test_obj | grep -e "$test_obj:" | sed "s/.*file format \(.*\)/\1/"`
+ BDFARCH=`LANG=C objdump -f $test_obj | grep -e "architecture:" | sed "s/.*ture: \(.*\),.*/\1/"`
+],[])
+AC_SUBST(BDFNAME)
+AC_SUBST(BDFARCH)
# Set the default value of HOSTCC from CC if --host was not provided:
HOSTCC=${HOSTCC:=${CC}}
@@ -116,8 +124,9 @@
AC_SUBST(PPPD_VERSION)
-AC_CONFIG_FILES([build_tools/menuselect-deps makeopts])
+AC_CONFIG_FILES([build_tools/menuselect-deps makeopts build_tools/make_firmware_object])
AC_OUTPUT
+chmod a+x build_tools/make_firmware_object
AC_MSG_NOTICE(*** Zaptel build successfully configured ***)
Modified: branches/1.4/firmware/Makefile
URL: http://svn.digium.com/view/zaptel/branches/1.4/firmware/Makefile?view=diff&rev=3198&r1=3197&r2=3198
==============================================================================
--- branches/1.4/firmware/Makefile (original)
+++ branches/1.4/firmware/Makefile Sun Oct 28 13:26:04 2007
@@ -181,21 +181,21 @@
fi
# Build object file of an oct6114 064 firmware image for linking
-zaptel-fw-oct6114-064.o: zaptel-fw-oct6114-064-$(OCT6114_064_VERSION).tar.gz ../wct4xxp/base.o zaptel-fw-oct6114-064.bin
+zaptel-fw-oct6114-064.o: zaptel-fw-oct6114-064-$(OCT6114_064_VERSION).tar.gz zaptel-fw-oct6114-064.bin
@echo Making firmware object file for zaptel-fw-oct6114-064.bin
- ../build_tools/make_firmware_object zaptel-fw-oct6114-064.bin $@ ../wct4xxp/base.o
+ ../build_tools/make_firmware_object zaptel-fw-oct6114-064.bin $@
# Build object file of an oct6114 128 firmware image for linking
-zaptel-fw-oct6114-128.o: zaptel-fw-oct6114-128-$(OCT6114_128_VERSION).tar.gz ../wct4xxp/base.o zaptel-fw-oct6114-128.bin
+zaptel-fw-oct6114-128.o: zaptel-fw-oct6114-128-$(OCT6114_128_VERSION).tar.gz zaptel-fw-oct6114-128.bin
@echo Making firmware object file for zaptel-fw-oct6114-128.bin
- ../build_tools/make_firmware_object zaptel-fw-oct6114-128.bin $@ ../wct4xxp/base.o
+ ../build_tools/make_firmware_object zaptel-fw-oct6114-128.bin $@
# Build object file of a TC400M firmware image for linking
-zaptel-fw-tc400m.o: zaptel-fw-tc400m-$(TC400M_VERSION).tar.gz ../wctc4xxp/base.o zaptel-fw-tc400m.bin
+zaptel-fw-tc400m.o: zaptel-fw-tc400m-$(TC400M_VERSION).tar.gz zaptel-fw-tc400m.bin
@echo Making firmware object file for zaptel-fw-tc400m.bin
- ../build_tools/make_firmware_object zaptel-fw-tc400m.bin $@ ../wctc4xxp/base.o
+ ../build_tools/make_firmware_object zaptel-fw-tc400m.bin $@
# Build object file of a VPMADT032 firmware image for linking
-zaptel-fw-vpmadt032.o: zaptel-fw-vpmadt032-$(VPMADT032_VERSION).tar.gz ../wctdm24xxp/base.o zaptel-fw-vpmadt032.bin
+zaptel-fw-vpmadt032.o: zaptel-fw-vpmadt032-$(VPMADT032_VERSION).tar.gz zaptel-fw-vpmadt032.bin
@echo Making firmware object file for zaptel-fw-vpmadt032.bin
- ../build_tools/make_firmware_object zaptel-fw-vpmadt032.bin $@ ../wctdm24xxp/base.o
+ ../build_tools/make_firmware_object zaptel-fw-vpmadt032.bin $@
More information about the zaptel-commits
mailing list