--- a/CMakeLists.txt Thu Dec 10 00:38:00 2009 +0200
+++ b/CMakeLists.txt Fri Jan 15 11:03:59 2010 +0200
@@ -22,7 +22,7 @@
option(DEBUG "Enable debugging output" ON)
option(LLM_CONNECTION_ENABLE "Enable exposing of mcabber loudmouth connection to lua" ON)
option(LLM_LOG_HANDLER "Enable registration of log messages handler for lua-loudmouth library's messages" ON)
-set(MCABBER_INCLUDE_DIR "${lua_SOURCE_DIR}/include" CACHE FILEPATH "Path to mcabber headers")
+set(MCABBER_INCLUDE_DIR "/usr/include" CACHE FILEPATH "Path to mcabber headers")
set(ML_SOURCE_PRIORITY G_PRIORITY_HIGH_IDLE CACHE STRING "Glib event source priority for timeout and bgread")
set(ML_BGREAD_BUFFER 4096 CACHE STRING "Background pipe reading buffer size")
@@ -71,9 +71,9 @@
## Set up compiler
configure_file(config.h.in config.h ESCAPE_QUOTES)
-include_directories(SYSTEM ${LUA_INCLUDE_DIR} ${GLIB_INCLUDE_DIRS} ${GMODULE_INCLUDE_DIRS} ${LM_INCLUDE_DIRS})
+include_directories(SYSTEM ${LUA_INCLUDE_DIR} ${GLIB_INCLUDE_DIRS} ${GMODULE_INCLUDE_DIRS} ${LM_INCLUDE_DIRS} ${MCABBER_INCLUDE_DIR})
target_link_libraries(lua ${LUA_LIBRARIES} ${GLIB_LIBRARIES} ${GMODULE_LIBRARIES})
-include_directories(${lua_SOURCE_DIR} ${lua_BINARY_DIR} ${MCABBER_INCLUDE_DIR})
+include_directories(${lua_SOURCE_DIR} ${lua_BINARY_DIR})
## Extra targets
if(PERL_FOUND)
--- a/README Thu Dec 10 00:38:00 2009 +0200
+++ b/README Fri Jan 15 11:03:59 2010 +0200
@@ -5,10 +5,10 @@
scripts working with this module.
To install it, you will need:
-- lua library and headers
+- lua 5.1 library and headers
- glib (with gmodule) library and headers
- loudmouth headers
-- mcabber-lm sources (for headers)
+- mcabber headers
- cmake
- perl (optional)
@@ -22,7 +22,7 @@
Debian users can instead of make install do
$ fakeroot make package
-# dpkg -i mcabber-lua-*.deb
+# dpkg -i mcabber-lua*.deb
This code underlies terms of GNU GPL v2 or later.
--- a/main.c Thu Dec 10 00:38:00 2009 +0200
+++ b/main.c Fri Jan 15 11:03:59 2010 +0200
@@ -25,21 +25,21 @@
#include <stdlib.h> // getenv
#include <string.h> // strcmp
+#include <mcabber/logprint.h> // scr_LogPrint
+#include <mcabber/screen.h> // scr_Beep, scr_WriteIncomingMessage
+#include <mcabber/hbuf.h> // HBB_PREFIX_INFO
+#include <mcabber/commands.h> // process_command, cmd_add, cmd_del
+#include <mcabber/xmpp.h> // xmpp_getstatus, xmpp_getstatusmsg, lconnection
+#include <mcabber/xmpp_helper.h> // xmpp_add_feature, xmpp_del_feature
+#include <mcabber/roster.h> // imstatus2char, foreach_buddy, buddy_*, current_buddy, BUDDATA, ROSTER_TYPE_*
+#include <mcabber/utils.h> // from_utf8, jidtodisp
+#include <mcabber/hooks.h> // hk_add_handler, hk_del_handler
+#include <mcabber/settings.h> // settings_set, settings_del, settings_get
+#include <mcabber/compl.h> // compl_new_category, compl_add_category_word, compl_del_category_word
+#include <mcabber/events.h> // evs_*
+
#include "config.h"
#include "util.h"
-#include "logprint.h" // scr_LogPrint
-#include "screen.h" // scr_Beep, scr_WriteIncomingMessage
-#include "hbuf.h" // HBB_PREFIX_INFO
-#include "commands.h" // process_command, cmd_add, cmd_del
-#include "xmpp.h" // xmpp_getstatus, xmpp_getstatusmsg, lconnection
-#include "xmpp_helper.h" // xmpp_add_feature, xmpp_del_feature
-#include "roster.h" // imstatus2char, foreach_buddy, buddy_*, current_buddy, BUDDATA, ROSTER_TYPE_*
-#include "utils.h" // from_utf8, jidtodisp
-#include "hooks.h" // hk_add_handler, hk_del_handler
-#include "settings.h" // settings_set, settings_del, settings_get
-#include "compl.h" // compl_new_category, compl_add_category_word, compl_del_category_word
-#include "events.h" // evs_*
-
// global lua state object, necessary for uninitialization function
static lua_State *lua = NULL;