check_hpjd is a nice and easy tool to monitor HP printers. I’m finding that it is giving me a little more information than I want. I’d like to be able to limit it to telling me when the toner is out or maybe if there is a paper jam. Things like paper out can be handled by the end user. Is there a way to limit the alerts? Or is the source available to customize it?
I found the source, but I can’t seem to compile the individual plugin after changing it (or even if I don’t change it). Is there a document that shows how to recompile it?
I run:
gcc check_hpjd.c -o check_hpjd
I get this as output:
In file included from check_hpjd.c:36:
common.h:34:20: error: config.h: No such file or directory
common.h:110:21: error: dirname.h: No such file or directory
common.h:195:21: error: gettext.h: No such file or directory
In file included from check_hpjd.c:37:
popen.h:8: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âpopen_timeout_alarm_handlerâ
In file included from check_hpjd.c:38:
utils.h:17:24: error: utils_base.h: No such file or directory
In file included from check_hpjd.c:38:
utils.h:41: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âtimeout_alarm_handlerâ
utils.h:64: error: redefinition of âstruct timevalâ
utils.h:71: warning: âstruct timezoneâ declared inside parameter list
utils.h:71: warning: its scope is only this definition or declaration, which is probably not what you want
In file included from check_hpjd.c:39:
netutils.h:91: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âsocket_timeout_alarm_handlerâ
check_hpjd.c: In function âmainâ:
check_hpjd.c:95: error: âLC_ALLâ undeclared (first use in this function)
check_hpjd.c:95: error: (Each undeclared identifier is reported only once
check_hpjd.c:95: error: for each function it appears in.)
check_hpjd.c:103: warning: incompatible implicit declaration of built-in function âgettextâ
check_hpjd.c:122: error: âPATH_TO_SNMPGETâ undeclared (first use in this function)
check_hpjd.c:143: warning: incompatible implicit declaration of built-in function âstrlenâ
check_hpjd.c:148: warning: assignment makes pointer from integer without a cast
check_hpjd.c:149: warning: assignment makes pointer from integer without a cast
check_hpjd.c:154: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:194: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:197: warning: incompatible implicit declaration of built-in function âstrncatâ
check_hpjd.c:212: warning: incompatible implicit declaration of built-in function âstrlenâ
check_hpjd.c:239: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:243: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:248: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:253: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:257: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:261: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:265: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:269: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:273: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:277: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:281: warning: incompatible implicit declaration of built-in function âstrcpyâ
check_hpjd.c:293: warning: incompatible implicit declaration of built-in function âstrstrâ
check_hpjd.c: In function âprocess_argumentsâ:
check_hpjd.c:338: warning: incompatible implicit declaration of built-in function âgettextâ
check_hpjd.c:345: error: âNP_VERSIONâ undeclared (first use in this function)
check_hpjd.c:361: warning: incompatible implicit declaration of built-in function âgettextâ
check_hpjd.c:369: warning: incompatible implicit declaration of built-in function âstrdupâ
check_hpjd.c: In function âprint_helpâ:
check_hpjd.c:386: error: âNP_VERSIONâ undeclared (first use in this function)
check_hpjd.c:391: warning: incompatible implicit declaration of built-in function âgettextâ
check_hpjd.c: In function âprint_usageâ:
check_hpjd.c:414: warning: incompatible implicit declaration of built-in function âgettextâ