summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorntfreak <ntfreak@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2008-07-12 16:25:17 +0000
committerntfreak <ntfreak@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2008-07-12 16:25:17 +0000
commit2e832a399a10fc00253b342f8cde9c5b1062fa63 (patch)
treeb679dc6381c72dc78e9c483c3399ae270c6dfa77 /configure.in
parentcebfbfa661b4e53cabf23bbb32c227e0b1962c77 (diff)
downloadopenocd+libswd-2e832a399a10fc00253b342f8cde9c5b1062fa63.tar.gz
openocd+libswd-2e832a399a10fc00253b342f8cde9c5b1062fa63.tar.bz2
openocd+libswd-2e832a399a10fc00253b342f8cde9c5b1062fa63.tar.xz
openocd+libswd-2e832a399a10fc00253b342f8cde9c5b1062fa63.zip
- remove requirement for file2c.tcl
git-svn-id: svn://svn.berlios.de/openocd/trunk@800 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in15
1 files changed, 11 insertions, 4 deletions
diff --git a/configure.in b/configure.in
index cce438fe..bc47064f 100644
--- a/configure.in
+++ b/configure.in
@@ -290,13 +290,20 @@ AM_CONDITIONAL(BITQ, test $build_bitq = yes)
AC_LANG_C
AC_PROG_CC
AC_PROG_RANLIB
-AC_PATH_PROG(TCLSH, tclsh)
-# quit if we have no tclsh
-if test "x${TCLSH}" = "x"; then
- AC_MSG_ERROR([no working tclsh found])
+AC_CHECK_PROG(OBJDUMP, objdump, objdump)
+AC_CHECK_PROG(OBJCOPY, objcopy, objcopy)
+
+if test x${OBJDUMP} != x -a x${OBJCOPY} != x ; then
+ AC_MSG_CHECKING(objcopy command line)
+ AC_TRY_COMPILE(,,[OBJCOPY_format=`${OBJDUMP} -f conftest.$ac_objext | sed -e '/file format/!d' -e 's/.*format \(.*\)/\1/'`
+ OBJCOPY_arch=`${OBJDUMP} -f conftest.$ac_objext | sed -e '/architecture/!d' -e 's/.*architecture: \(.*\),.*/\1/'`])
+ AC_MSG_RESULT(-I binary -O ${OBJCOPY_format} -B ${OBJCOPY_arch})
fi
+AC_SUBST(OBJCOPY_FORMAT, ${OBJCOPY_format})
+AC_SUBST(OBJCOPY_ARCH, ${OBJCOPY_arch})
+
AC_SUBST(WITH_FTD2XX, $with_ftd2xx)
AC_OUTPUT(Makefile src/Makefile src/helper/Makefile src/jtag/Makefile src/xsvf/Makefile src/target/Makefile src/server/Makefile src/flash/Makefile src/pld/Makefile doc/Makefile)