dnl Copyright (C) 2012 The Meme Factory, Inc. http://www.meme.com/ dnl Copyright (C) 2004, 2008, Karl O. Pinc dnl dnl This file is part of Gombe-MI. dnl dnl Gombe-MI is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by dnl the Free Software Foundation; either version 3 of the License, or dnl (at your option) any later version. dnl dnl This program is distributed in the hope that it will be useful, dnl but WITHOUT ANY WARRANTY; without even the implied warranty of dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the dnl GNU General Public License for more details. dnl dnl You should have received a copy of the GNU General Public License dnl along with Gombe-MI. If not, see . dnl dnl M4 macros for making functions to support Gombe-MI on the server side. dnl Karl O. Pinc dnl dnl dnl m4 includes include(`copyright.m4') include(`globalmacros.m4') dnl dnl Don't ouput while defining functions. divert(-1) dnl Grant privliges to a function. dnl dnl This also prints the name of the function. As every function has dnl priviliges granted on it we get to monitor progress this way. dnl dnl Syntax: grant_func_priv(function_declaration) changequote([,]) define([grant_func_priv],[ GRANT EXECUTE ON FUNCTION $1 TO GROUP gombemi_editors; SELECT '$1' AS done_with; ]) changequote(`,') dnl Grant everybody privliges to a function. dnl dnl This also prints the name of the function. As every function has dnl priviliges granted on it we get to monitor progress this way. dnl dnl Syntax: grant_everybody_func_priv(function_declaration) changequote([,]) define([grant_everybody_func_priv],[ GRANT EXECUTE ON FUNCTION $1 TO GROUP gombemi_editors; GRANT EXECUTE ON FUNCTION $1 TO GROUP gombemi_readers; SELECT '$1' AS done_with; ]) changequote(`,') dnl Turn output back on. divert`'dnl