From a92205679aed1880bf958244811474210a8c2d9b Mon Sep 17 00:00:00 2001 From: Martin Peach Date: Wed, 28 Sep 2011 16:15:06 +0000 Subject: Applied Hans' patch to limit startup boilerplate visibility to log level >=3, if logpost() is available. svn path=/trunk/externals/loaders/pdlua/; revision=15376 --- src/pdlua.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/src/pdlua.c b/src/pdlua.c index b80215c..519cd7f 100644 --- a/src/pdlua.c +++ b/src/pdlua.c @@ -1356,10 +1356,23 @@ EXTERN void pdlua_setup(void) t_pdlua_readerdata reader; int fd; int result; + char* pdluaver = "pdlua 0.6 (GPL) 2011 Martin Peach, based on"; + char* luaver = "lua 0.6~svn (GPL) 2008 Claude Heiland-Allen "; + char compiled[MAXPDSTRING]; - post("pdlua 0.6 (GPL) 2011 Martin Peach, based on"); - post("lua 0.6~svn (GPL) 2008 Claude Heiland-Allen "); - post("pdlua: compiled for pd-%d.%d on %s %s", PD_MAJOR_VERSION, PD_MINOR_VERSION, __DATE__, __TIME__); + snprintf(compiled, MAXPDSTRING, "pdlua: compiled for pd-%d.%d on %s %s", + PD_MAJOR_VERSION, PD_MINOR_VERSION, __DATE__, __TIME__); + + +#if PD_MAJOR_VERSION==0 && PD_MINOR_VERSION<43 + post(pdluaver); + post(luaver); + post(compiled); +#else + logpost(NULL, 3, pdluaver); + logpost(NULL, 3, luaver); + logpost(NULL, 3, compiled); +#endif pdlua_proxyinlet_setup(); #ifdef PDLUA_DEBUG post("pdlua pdlua_proxyinlet_setup done"); -- cgit v1.2.1