From 5adc8bdbb1471821f912becbba86e4631a4a001a Mon Sep 17 00:00:00 2001 From: "Leandro A. F. Pereira" Date: Wed, 3 Jan 2007 01:19:25 +0000 Subject: Cleanups. Implement DEBUG() macro. --- hardinfo2/configure | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'hardinfo2/configure') diff --git a/hardinfo2/configure b/hardinfo2/configure index 05e92c0e..068d99cc 100755 --- a/hardinfo2/configure +++ b/hardinfo2/configure @@ -162,7 +162,14 @@ echo "#define HOSTNAME \"`hostname`\"" >> config.h echo "#define PREFIX \"/usr/share/hardinfo/\"" >> config.h echo "#define LIBPREFIX \"/usr/lib/hardinfo/\"" >> config.h -echo "#define DEBUG 1" >> config.h + +if [ "$RELEASE" == "1" ]; then + echo "#define DEBUG(...)" >> config.h +else + echo '#define DEBUG(msg,...) g_print("*** %s:%d (%s) *** " msg "\n", \' >> config.h + echo ' __FILE__, __LINE__, __FUNCTION__, ##__VA_ARGS__)' >> config.h +fi + echo "#define ENABLE_BINRELOC 1" >> config.h echo "#define RELEASE $RELEASE" >> config.h -- cgit v1.2.3