libcgroup cross-compile error: undefined reference to rpl_realloc

libcgroup is an abstraction of a linux cgroups. Even though standard cross-compile operations are fairly enough:

./configure --host=arm-linux-gnueabihf

During compilation, this error happens:

make[3]: Entering directory `/home/arcelik/1511/tools/libcgroup-0.41/src/daemon'
CC cgrulesengd.o
CCLD cgrulesengd
cgrulesengd.o: In function `cgre_store_unchanged_process':
/home/arcelik/1511/tools/libcgroup-0.41/src/daemon/cgrulesengd.c:310: undefined reference to `rpl_realloc'
cgrulesengd.o: In function `cgre_store_parent_info':
/home/arcelik/1511/tools/libcgroup-0.41/src/daemon/cgrulesengd.c:223: undefined reference to `rpl_realloc'
../../src/.libs/ undefined reference to `rpl_malloc'
collect2: error: ld returned 1 exit status

undefined reference to rpl_malloc and rpl_realloc error can be fixed by explicitly telling the configure script that malloc and realloc functions are exist. So that, above linking error should not happen.

However, target platform has to be a glibc system to avoid from runtime error in the future.

ac_cv_func_malloc_0_nonnull=yes ac_cv_func_realloc_0_nonnull=yes ./configure --host=arm-linux-gnueabihf

Note: an extension of a linaro toolchain 2014.09 is used while cross-compiling.