libxdg-basedir 1.0.0 compatibility

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Nikos Ntarmos 2009-04-18 18:50:55 +02:00 committed by Julien Danjou
parent 4a34693bfb
commit 715f95555a
4 changed files with 10 additions and 10 deletions

View file

@ -357,10 +357,10 @@ main(int argc, char **argv)
setlocale(LC_CTYPE, "");
/* Get XDG basedir data */
xdg = xdgAllocHandle();
xdgInitHandle(&xdg);
/* init lua */
luaA_init(xdg);
luaA_init(&xdg);
/* check args */
while((opt = getopt_long(argc, argv, "vhkc:",
@ -374,7 +374,7 @@ main(int argc, char **argv)
exit_help(EXIT_SUCCESS);
break;
case 'k':
if(!luaA_parserc(xdg, confpath, false))
if(!luaA_parserc(&xdg, confpath, false))
{
fprintf(stderr, "✘ Configuration file syntax error.\n");
return EXIT_FAILURE;
@ -505,9 +505,9 @@ main(int argc, char **argv)
spawn_init();
/* Parse and run configuration file */
luaA_parserc(xdg, confpath, true);
luaA_parserc(&xdg, confpath, true);
xdgFreeHandle(xdg);
xdgWipeHandle(&xdg);
/* scan existing windows */
scan();

View file

@ -148,7 +148,7 @@ pkg_check_modules(AWESOME_REQUIRED REQUIRED
libstartup-notification-1.0>=0.10
xproto>=7.0.11
imlib2
libxdg-basedir)
libxdg-basedir>=1.0.0)
if(NOT AWESOME_REQUIRED_FOUND OR NOT AWESOME_COMMON_REQUIRED_FOUND)
message(FATAL_ERROR)

4
luaa.c
View file

@ -640,7 +640,7 @@ luaA_awesome_newindex(lua_State *L)
* \param xdg An xdg handle to use to get XDG basedir.
*/
void
luaA_init(xdgHandle xdg)
luaA_init(xdgHandle* xdg)
{
lua_State *L;
static const struct luaL_reg awesome_lib[] =
@ -780,7 +780,7 @@ luaA_loadrc(const char *confpath, bool run)
* \param run Run the configuration file.
*/
bool
luaA_parserc(xdgHandle xdg, const char *confpatharg, bool run)
luaA_parserc(xdgHandle* xdg, const char *confpatharg, bool run)
{
char *confpath = NULL;
bool ret = false;

4
luaa.h
View file

@ -328,8 +328,8 @@ luaA_pushpadding(lua_State *L, padding_t *padding)
return 1;
}
void luaA_init(xdgHandle);
bool luaA_parserc(xdgHandle, const char *, bool);
void luaA_init(xdgHandle *);
bool luaA_parserc(xdgHandle *, const char *, bool);
void luaA_on_timer(EV_P_ ev_timer *, int);
int luaA_pushxcolor(lua_State *, const xcolor_t *);
int luaA_pushcolor(lua_State *, const color_t *);