forked from osmocom/wireshark
From Tony Trinh:
Update Lua from 5.1 to 5.2 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7400 svn path=/trunk/; revision=43482
This commit is contained in:
parent
8eeebf73e0
commit
e6e6d6217b
|
@ -365,7 +365,7 @@ if(HAVE_LIBPYTHON)
|
|||
endif()
|
||||
if(HAVE_LIBLUA)
|
||||
set(HAVE_LUA_H 1)
|
||||
set(HAVE_LUA_5_1 1)
|
||||
set(HAVE_LUA 1)
|
||||
endif()
|
||||
if(HAVE_LIBKERBEROS)
|
||||
set(HAVE_KERBEROS 1)
|
||||
|
|
|
@ -409,7 +409,7 @@ config.h : config.h.win32 config.nmake
|
|||
-e "s/@HAVE_LIBGNUTLS@/$(GNUTLS_CONFIG)/" \
|
||||
-e "s/@HAVE_LIBGCRYPT@/$(LIBGCRYPT_CONFIG)/" \
|
||||
-e "s/@HAVE_LUA@/$(LUA_CONFIG)/" \
|
||||
-e "s/@HAVE_LUA_5_1@/$(LUA_VERSION)/" \
|
||||
-e "s/@HAVE_LUA@/$(LUA_VERSION)/" \
|
||||
-e "s/@HAVE_PYTHON@/$(PYTHON_CONFIG)/" \
|
||||
-e "s/@HAVE_AIRPCAP@/$(AIRPCAP_CONFIG)/" \
|
||||
-e "s/@HAVE_AIRPDCAP@/$(AIRPDCAP_CONFIG)/" \
|
||||
|
|
|
@ -938,7 +938,7 @@ AC_DEFUN([AC_WIRESHARK_LIBLUA_CHECK],[
|
|||
LUA_LIBS="-llua -lm"
|
||||
LUA_INCLUDES=""
|
||||
fi
|
||||
AC_DEFINE(HAVE_LUA_5_1, 1, [Define to use Lua ${lua_ver}])
|
||||
AC_DEFINE(HAVE_LUA, 1, [Define to use Lua ${lua_ver}])
|
||||
want_lua=yes
|
||||
|
||||
],[
|
||||
|
@ -954,7 +954,7 @@ AC_DEFUN([AC_WIRESHARK_LIBLUA_CHECK],[
|
|||
# Lua found
|
||||
#
|
||||
LUA_LIBS=" -llua${lua_ver} -lm"
|
||||
AC_DEFINE(HAVE_LUA_5_1, 1, [Define to use Lua ${lua_ver}])
|
||||
AC_DEFINE(HAVE_LUA, 1, [Define to use Lua ${lua_ver}])
|
||||
want_lua=yes
|
||||
],[
|
||||
#
|
||||
|
|
|
@ -136,7 +136,7 @@
|
|||
#cmakedefine HAVE_LUALIB_H 1
|
||||
|
||||
/* Define to use Lua 5.1 */
|
||||
#cmakedefine HAVE_LUA_5_1 1
|
||||
#cmakedefine HAVE_LUA 1
|
||||
|
||||
/* Define to 1 if you have the <lua.h> header file. */
|
||||
#cmakedefine HAVE_LUA_H 1
|
||||
|
|
|
@ -203,7 +203,7 @@
|
|||
|
||||
/* Define to use Lua */
|
||||
@HAVE_LUA@
|
||||
@HAVE_LUA_5_1@
|
||||
@HAVE_LUA@
|
||||
|
||||
/* Define to use Python */
|
||||
@HAVE_PYTHON@
|
||||
|
|
|
@ -1274,7 +1274,7 @@ LUA_CFLAGS=/I$(LUA_DIR)\include
|
|||
LUA_LIBS=$(LUA_DIR)\lua5.1.lib
|
||||
# Nmake uses carets to escape special characters
|
||||
LUA_CONFIG=^#define HAVE_LUA 1
|
||||
LUA_VERSION=^#define HAVE_LUA_5_1 1
|
||||
LUA_VERSION=^#define HAVE_LUA 1
|
||||
!else
|
||||
LUA_CFLAGS=
|
||||
LUA_LIBS=
|
||||
|
|
|
@ -54,7 +54,7 @@
|
|||
#include "emem.h"
|
||||
#include "expert.h"
|
||||
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
#include <lua.h>
|
||||
#include <wslua/wslua.h>
|
||||
#endif
|
||||
|
@ -117,7 +117,7 @@ epan_init(void (*register_all_protocols_func)(register_cb cb, gpointer client_da
|
|||
final_registration_all_protocols();
|
||||
host_name_lookup_init();
|
||||
expert_init();
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
wslua_init(cb, client_data);
|
||||
#endif
|
||||
#ifdef HAVE_GEOIP
|
||||
|
@ -295,12 +295,12 @@ epan_get_compiled_version_info(GString *str)
|
|||
|
||||
/* LUA */
|
||||
g_string_append(str, ", ");
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
g_string_append(str, "with ");
|
||||
g_string_append(str, LUA_VERSION);
|
||||
#else
|
||||
g_string_append(str, "without Lua");
|
||||
#endif /* HAVE_LUA_5_1 */
|
||||
#endif /* HAVE_LUA */
|
||||
|
||||
g_string_append(str, ", ");
|
||||
#ifdef HAVE_PYTHON
|
||||
|
|
|
@ -771,7 +771,7 @@ get_wspython_dir(void)
|
|||
}
|
||||
|
||||
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA_5_1)
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA)
|
||||
/*
|
||||
* Find the directory where the plugins are stored.
|
||||
*
|
||||
|
@ -850,7 +850,7 @@ init_plugin_dir(void)
|
|||
}
|
||||
#endif
|
||||
}
|
||||
#endif /* HAVE_PLUGINS || HAVE_LUA_5_1 */
|
||||
#endif /* HAVE_PLUGINS || HAVE_LUA */
|
||||
|
||||
/*
|
||||
* Get the directory in which the plugins are stored.
|
||||
|
@ -858,7 +858,7 @@ init_plugin_dir(void)
|
|||
const char *
|
||||
get_plugin_dir(void)
|
||||
{
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA_5_1)
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA)
|
||||
if (!plugin_dir) init_plugin_dir();
|
||||
return plugin_dir;
|
||||
#else
|
||||
|
|
|
@ -519,7 +519,7 @@ plugins_dump_all(void)
|
|||
plugin *pt_plug;
|
||||
const char *sep;
|
||||
#endif
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
wslua_plugin *lua_plug;
|
||||
#endif
|
||||
|
||||
|
@ -552,7 +552,7 @@ plugins_dump_all(void)
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
for (lua_plug = wslua_plugin_list; lua_plug != NULL; lua_plug = lua_plug->next)
|
||||
{
|
||||
printf("%s\t%s\tlua script\t%s\n", lua_plug->name, lua_plug->version, lua_plug->filename);
|
||||
|
|
|
@ -297,7 +297,7 @@ C shift##C(lua_State* L,int i) { \
|
|||
} \
|
||||
typedef int dummy##C
|
||||
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
|
||||
#if LUA_VERSION_NUM >= 502
|
||||
#define WSLUA_REGISTER_CLASS(C) { \
|
||||
|
|
|
@ -247,7 +247,7 @@ splash_update(register_action_e action, const char *message, gpointer client_dat
|
|||
dissectors, listeners,
|
||||
registering plugins, handingoff plugins,
|
||||
preferences and configuration */
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
ul_count++; /* additional one for lua plugins */
|
||||
#endif
|
||||
#ifdef HAVE_PYTHON
|
||||
|
@ -438,7 +438,7 @@ about_folders_page_new(void)
|
|||
about_folders_row(table, "Program", constpath,
|
||||
"program files");
|
||||
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA_5_1)
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA)
|
||||
/* pers plugins */
|
||||
path = get_plugins_pers_dir();
|
||||
about_folders_row(table, "Personal Plugins", path,
|
||||
|
@ -509,7 +509,7 @@ about_wireshark_cb( GtkWidget *w _U_, gpointer data _U_ )
|
|||
GtkWidget *main_box, *main_nb, *bbox, *ok_btn;
|
||||
GtkWidget *page_lb, *about_page, *folders_page;
|
||||
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA_5_1)
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA)
|
||||
GtkWidget *plugins_page;
|
||||
#endif
|
||||
|
||||
|
@ -553,7 +553,7 @@ about_wireshark_cb( GtkWidget *w _U_, gpointer data _U_ )
|
|||
page_lb = gtk_label_new("Folders");
|
||||
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), folders_page, page_lb);
|
||||
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA_5_1)
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA)
|
||||
plugins_page = about_plugins_page_new();
|
||||
page_lb = gtk_label_new("Plugins");
|
||||
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), plugins_page, page_lb);
|
||||
|
|
|
@ -3708,7 +3708,7 @@ make_menu_xml(const char *path) {
|
|||
* Creates an action group for the menu items in xpath, and returns it. The caller should
|
||||
* use g_object_unref() on the returned pointer if transferring scope.
|
||||
*/
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
/* NOTE currently only used from Lua, remove this ifdef when used
|
||||
outside of #ifdef LUA */
|
||||
static GtkActionGroup*
|
||||
|
@ -3797,7 +3797,7 @@ make_menu_actions(const char *path, const menu_item_t *menu_item_data) {
|
|||
static void
|
||||
merge_lua_menu_items(GList *merge_lua_menu_items_list _U_)
|
||||
{
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
guint merge_id;
|
||||
GtkActionGroup *action_group;
|
||||
menu_item_t *menu_item_data;
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
#include "ui/gtk/plugins_dlg.h"
|
||||
|
||||
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA_5_1)
|
||||
#if defined(HAVE_PLUGINS) || defined(HAVE_LUA)
|
||||
|
||||
/*
|
||||
* Fill the list widget with a list of the plugin modules.
|
||||
|
@ -48,7 +48,7 @@ plugins_scan(GtkWidget *list)
|
|||
plugin *pt_plug;
|
||||
const char *sep;
|
||||
#endif
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
wslua_plugin *lua_plug;
|
||||
#endif
|
||||
GString *type;
|
||||
|
@ -86,7 +86,7 @@ plugins_scan(GtkWidget *list)
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_LUA_5_1
|
||||
#ifdef HAVE_LUA
|
||||
for (lua_plug = wslua_plugin_list; lua_plug != NULL; lua_plug = lua_plug->next)
|
||||
{
|
||||
type = g_string_new("");
|
||||
|
@ -119,4 +119,4 @@ about_plugins_page_new(void)
|
|||
return scrolledwindow;
|
||||
}
|
||||
|
||||
#endif /* HAVE_PLUGINS || HAVE_LUA_5_1 */
|
||||
#endif /* HAVE_PLUGINS || HAVE_LUA */
|
||||
|
|
Loading…
Reference in New Issue