[sane-devel] How to use DBG(level, fmt, ...) to output debug information?
m. allan noah
kitno455 at gmail.com
Wed Jun 11 10:37:09 UTC 2008
the DBG macro only prints if the proper environment var is set:
SANE_DEBUG_BACKENDNAME scanimage -L
but change 'BACKENDNAME' to an all-capital version of your backend name.
On 6/10/08, eagleskycloud <eagleskycloud at gmail.com> wrote:
> I look up the <sane/sanei_debug.h>, and I also refer to the backends
> wrote by others, but I still confused how to use DBG(level, fmt, ...) to
> output specific information. e.g. I define below macro follow the
> #include <sane/sanei_debug.h>
> #define BACKEND_NAME MY_BACKEND
> #define FUNCTION_DETAIL 1
> #define FUNCTION_TRACE 2
> I call DBG_INIT() in sane_init (). In some functions I use DBG(1, "%d",
> param) and DBG(2, "%d", msg) to output debug information. But the backend
> doesn't output any information that I wanted while I debug it . Does anyone
> tell me what should I do to output these debug information?
> Thank you.
> sane-devel mailing list:
> sane-devel at lists.alioth.debian.org
> Unsubscribe: Send mail with subject "unsubscribe your_password"
> to sane-devel-request at lists.alioth.debian.org
"The truth is an offense, but not a sin"
More information about the sane-devel