Update for OS X support (by Ville Voipio)

git-svn-id: https://urjtag.svn.sourceforge.net/svnroot/urjtag/trunk@1205 b68d4a1b-bc3d-0410-92ed-d4ac073336b7
master
Kolja Waschk 17 years ago
parent 733722108d
commit ff3536198c

@ -1,3 +1,8 @@
2005-05-06 Kolja Waschk <kawk>
* acinclude.m4, src/cmd/cmd.c, src/jtag.c:
Update for [ 1940323 ] OS X support for UrJTAG (by Ville Voipio)
2008-05-05 Mike Frysinger <vapier@gentoo.org>
* src/svf/svf.c: Fix __MINGW32__ typo.

@ -45,7 +45,8 @@ dnl
dnl
dnl @version 1.1
dnl @author Ville Laurikari <vl@iki.fi>
dnl
dnl @author Ville Voipio <vv@iki.fi>; check for readline completion (not available in, e.g. Leopard)
AC_DEFUN([VL_LIB_READLINE], [
AC_CACHE_CHECK([for a readline compatible library],
vl_cv_lib_readline, [
@ -78,16 +79,23 @@ AC_DEFUN([VL_LIB_READLINE], [
[Define if you have a readline compatible library])
AC_CHECK_HEADERS(readline.h readline/readline.h)
AC_CACHE_CHECK([whether readline supports history],
vl_cv_lib_readline_history, [
vl_cv_lib_readline_history="no"
AC_TRY_LINK_FUNC(add_history, vl_cv_lib_readline_history="yes")
])
vl_cv_lib_readline_history,
[vl_cv_lib_readline_history="no"
AC_TRY_LINK_FUNC(add_history, vl_cv_lib_readline_history="yes")])
if test "$vl_cv_lib_readline_history" = "yes"; then
AC_DEFINE(HAVE_READLINE_HISTORY, 1,
[Define if your readline library has \`add_history'])
AC_DEFINE(HAVE_READLINE_HISTORY, 1, [Define if your readline library has \`add_history'])
AC_CHECK_HEADERS(history.h readline/history.h)
fi
AC_CACHE_CHECK([whether readline supports completion],
vl_cv_lib_readline_completion,
[vl_cv_lib_readline_completion="no"
AC_TRY_LINK_FUNC(rl_completion_matches, vl_cv_lib_readline_completion="yes")])
if test "$vl_cv_lib_readline_completion" = "yes"; then
AC_DEFINE(HAVE_READLINE_COMPLETION, 1, [Define if your readline library has \`rl_completion_matches'])
fi
fi
])dnl
# ACI_PROG_SED

@ -141,6 +141,7 @@ cmd_find_next( const char *text, int state )
return NULL;
}
#ifdef HAVE_READLINE_COMPLETION
char **
cmd_completion( const char *text, int start, int end )
{
@ -152,6 +153,7 @@ cmd_completion( const char *text, int start, int end )
return ret;
}
#endif
#endif
int
cmd_test_cable( chain_t *chain )

@ -463,7 +463,9 @@ main( int argc, char *const argv[] )
go = norc ? 1 : jtag_parse_rc( chain );
#ifdef HAVE_LIBREADLINE
#ifdef HAVE_READLINE_COMPLETION
rl_attempted_completion_function = cmd_completion;
#endif
#endif
if (go) {

Loading…
Cancel
Save