Add AVV description file
authorMyhailo Danylenko <isbear@ukrpost.net>
Tue, 03 May 2011 16:27:19 +0300
changeset 115 47bed161e3b0
parent 114 81ec4182c92d
child 116 6c533e9b5f88
Add AVV description file
.gitignore
CMakeLists.txt
config.h.in
lua.avv.in
lua.c
--- a/.gitignore	Tue May 03 16:26:22 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,25 +0,0 @@
-# ignore generated by libtool files (no more necessary)
-*.a
-*.o
-*.lo
-*.la
-*.so
-*.lai
-*.so.*
-# ignore backup files
-*~
-# ignore docs: they are not important and apiref is generated on the fly
-*.html
-# ignore generated makefile
-Makefile
-# ignore cmake files
-*.cmake
-CMake*
-CPack*
-# ignore generated header
-config.h
-# ignore resulting bundles
-*.deb
-*.tar.bz2
-# ignore build dir
-build
--- a/CMakeLists.txt	Tue May 03 16:26:22 2011 +0300
+++ b/CMakeLists.txt	Tue May 03 16:27:19 2011 +0300
@@ -89,14 +89,15 @@
 set(CPACK_SOURCE_IGNORE_FILES "/\\\\..*;\\\\.swp;~$;/build/;\\\\.tar\\\\.;\\\\.deb;\\\\.so")
 include(CPack)
 
+configure_file(lua.avv.in lua.avv)
+
 ## Set up installer
 install(TARGETS lua DESTINATION lib/mcabber)
 if(PERL_FOUND)
 	install(FILES ${lua_BINARY_DIR}/lua.html DESTINATION share/doc/${CPACK_PACKAGE_NAME})
 endif()
 install(DIRECTORY examples DESTINATION share/doc/${CPACK_PACKAGE_NAME} PATTERN "*~" EXCLUDE)
-install(FILES README DESTINATION share/doc/${CPACK_PACKAGE_NAME})
-install(FILES TODO DESTINATION share/doc/${CPACK_PACKAGE_NAME})
-install(FILES COPYING DESTINATION share/doc/${CPACK_PACKAGE_NAME})
+install(FILES README TODO COPYING DESTINATION share/doc/${CPACK_PACKAGE_NAME})
+install(FILES ${PROJECT_BINARY_DIR}/lua.avv DESTINATION share/mcabber/avv/modules RENAME lua)
 
 ## The End ## vim: se ts=4: ##
--- a/config.h.in	Tue May 03 16:26:22 2011 +0300
+++ b/config.h.in	Tue May 03 16:27:19 2011 +0300
@@ -21,10 +21,6 @@
 
 #include <mcabber/config.h>
 
-#if MCABBER_BRANCH_EXPERIMENTAL && MCABBER_API_VERSION >= 27
-#  define HAVE_CMD_ID
-#endif
-
 // define this to enable debugging output
 #cmakedefine DEBUG
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/lua.avv.in	Tue May 03 16:27:19 2011 +0300
@@ -0,0 +1,12 @@
+
+Name:        ${PROJECT_NAME}
+Method:      glib
+Version:     ${PROJECT_VERSION}
+Description: ${CPACK_PACKAGE_DESCRIPTION_SUMMARY}
+Requires:    modules:2 + logprint:3 + screen:4 + hbuf:1 + commands:3 + xmpp:4 +
+             xmpp_helper:2 + roster:3 + utils:2 + hooks:4 + settings:1 + compl:3 +
+	     events:1 + main:1
+Provides:    lua:1
+Init:        mlua_init
+Uninit:      mlua_uninit
+
--- a/lua.c	Tue May 03 16:26:22 2011 +0300
+++ b/lua.c	Tue May 03 16:27:19 2011 +0300
@@ -39,15 +39,15 @@
 #include <mcabber/compl.h>       // compl_new_category, compl_add_category_word, compl_del_category_word
 #include <mcabber/events.h>      // evs_*
 #include <mcabber/modules.h>     // module_info_t
-#include <mcabber/api.h>         // mcabber_branch, mcabber_api_version
+#include <mcabber/api.h>         // mcabber_branch, mcabber_api_version, MCABBER_API_HAVE_CMD_ID
 #include <mcabber/main.h>        // mcabber_version
 
 #include "config.h"
 #include "util.h"
 
 // module description
-static void mlua_init   (void);
-static void mlua_uninit (void);
+void mlua_init   (void);
+void mlua_uninit (void);
 
 #ifdef LLM_LOG_HANDLER
 #define DESCRIPTION ( \
@@ -1740,7 +1740,7 @@
 	}
 }
 
-static void mlua_init (void)
+void mlua_init (void)
 {
 	luaL_openlibs (lua);
 
@@ -1846,7 +1846,7 @@
 	compl_del_category (id);
 }
 
-static void mlua_uninit (void)
+void mlua_uninit (void)
 {
 	if (lua) {
 		hk_arg_t args[] = {