build-sys: uClibc does not have rpmatch()

Add simple replacement with hardcoded y/n responses to allow
compilation on systems without rpmatch().

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola
2012-04-17 21:41:26 +02:00
parent bb4ae3d933
commit 34344de979
3 changed files with 11 additions and 0 deletions

9
include/rpmatch.h Normal file
View File

@ -0,0 +1,9 @@
#ifndef PROCPS_NG_RPMATCH_H
#define PROCPS_NG_RPMATCH_H
#ifndef HAVE_RPMATCH
#define rpmatch(r) \
(*r == 'y' || *r == 'Y' ? 1 : *r == 'n' || *r == 'N' ? 0 : -1)
#endif
#endif /* PROCPS_NG_RPMATCH_H */