From: jsancho Date: Wed, 23 Sep 2009 20:53:43 +0000 (+0000) Subject: (no commit message) X-Git-Url: https://git.jsancho.org/?a=commitdiff_plain;h=199f4ec61993ba0a47b8dfa700cee2aa83b650a7;p=gacela.git --- diff --git a/gacela_SDL.lisp b/gacela_SDL.lisp index fe74349..1a2a02c 100644 --- a/gacela_SDL.lisp +++ b/gacela_SDL.lisp @@ -23,8 +23,14 @@ (clines "#include ") (clines "#include ") -(defmacro defcconst (type name) - `(let ((header (concatenate 'string "(defcfun \" +(defmacro mapcconst (type name) + `(let ((header (concatenate 'string ,type " gacela_" ,name " (void)")) + (body (concatenate 'string "return " ,name ";")) + (cfun (concatenate 'string "gacela_" ,name))) + (defcfun header 0 body) + (defentry + +(defentry SDL_GetTicks () (int "gacela_SDL_GetTicks")) ;;; SDL constants as functions (defcfun "int gacela_SDL_INIT_TIMER (void)" 0 "return SDL_INIT_TIMER;")