Merge branch 'python-bindings' of github.com:datamachine/tg into python-bindings

Conflicts:
	Makefile.in
	config.h.in
	configure
	main.c
This commit is contained in:
Vincent Castellano 2015-05-15 09:24:25 -07:00
commit 2e62498539
4 changed files with 21 additions and 2 deletions

4
configure vendored
View File

@ -1338,7 +1338,6 @@ Optional Features:
--enable-libconfig/--disable-libconfig --enable-libconfig/--disable-libconfig
--enable-extf/--disable-extf --enable-extf/--disable-extf
--enable-liblua/--disable-liblua --enable-liblua/--disable-liblua
<<<<<<< HEAD
--enable-json/--disable-json --enable-json/--disable-json
--enable-valgrind/--disable-valgrind --enable-valgrind/--disable-valgrind
--enable-python/--disable-python --enable-python/--disable-python
@ -6380,6 +6379,7 @@ $as_echo "#define USE_PYTHON 1" >>confdefs.h
fi fi
<<<<<<< HEAD
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libjansson" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libjansson" >&5
$as_echo_n "checking for libjansson... " >&6; } $as_echo_n "checking for libjansson... " >&6; }
@ -6501,6 +6501,8 @@ $as_echo "#define USE_JSON 1" >>confdefs.h
fi fi
=======
>>>>>>> 1b3cdff3fde9a12d9251fa388fc86a94a905db2a
#check for custom prog name #check for custom prog name
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking progname" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking progname" >&5

View File

@ -94,6 +94,19 @@ AC_ARG_ENABLE(liblua,[--enable-liblua/--disable-liblua],
AC_MSG_ERROR([No lua found. Try --disable-liblua]) AC_MSG_ERROR([No lua found. Try --disable-liblua])
]) ])
]) ])
AC_ARG_ENABLE(python,[--enable-python/--disable-python],
[
AX_PYTHON()
dnl python checks (you can change the required python version bellow)
AM_PATH_PYTHON(2.7.0)
PY_PREFIX=`$PYTHON -c 'import sys ; print sys.prefix'`
AC_SUBST([PYTHON_LIBS])
AC_SUBST([PYTHON_CFLAGS])
EXTRA_LIBS="${EXTRA_LIBS} -l${PYTHON_LIB}"
CPPFLAGS="${CPPFLAGS} -I${PYTHON_INCLUDE_DIR}"
AC_DEFINE(USE_PYTHON,1,[use python])
])
AC_MSG_CHECKING([for libjansson]) AC_MSG_CHECKING([for libjansson])
AC_ARG_ENABLE(json,[--enable-json/--disable-json], AC_ARG_ENABLE(json,[--enable-json/--disable-json],

4
main.c
View File

@ -496,6 +496,9 @@ void usage (void) {
#ifdef USE_PYTHON #ifdef USE_PYTHON
printf (" -Z python script file\n"); printf (" -Z python script file\n");
#endif #endif
#ifdef USE_PYTHON
printf (" -Z python script file\n");
#endif
printf (" -W send dialog_list query and wait for answer before reading input\n"); printf (" -W send dialog_list query and wait for answer before reading input\n");
printf (" -C disable color output\n"); printf (" -C disable color output\n");
printf (" -R disable readline\n"); printf (" -R disable readline\n");
@ -674,6 +677,7 @@ void args_parse (int argc, char **argv) {
"Z:" "Z:"
#endif #endif
, long_options, NULL , long_options, NULL
)) != -1) { )) != -1) {
switch (opt) { switch (opt) {
case 1000: case 1000:

2
tgl

@ -1 +1 @@
Subproject commit b3dcce35110f5c995366318c2886065287815d09 Subproject commit 76824c29a6dcb424e1109e691d31280a9cbaa954