--- ./e2fsck/e2fsck.c.orig 2011-08-03 20:54:59.531147443 +0200 +++ ./e2fsck/e2fsck.c 2011-08-03 21:02:09.511147380 +0200 @@ -15,6 +15,26 @@ #include "problem.h" /* + * fix posix_memalign in uclibc + */ +#if __UCLIBC_SUBLEVEL__ <= 28 && __UCLIBC_MINOR__ == 9 && __UCLIBC_MAJOR__ == 0 +int posix_memalign(void **memptr, size_t alignment, size_t size) +{ + /* Make sure alignment is correct. */ + if (alignment % sizeof(void *) != 0) + /* Skip these checks because the memalign() func does them for us + || !powerof2(alignment / sizeof(void *)) != 0 + || alignment == 0 + */ + return EINVAL; + + *memptr = memalign(alignment, size); + + return (*memptr != NULL ? 0 : ENOMEM); +} +#endif + +/* * This function allocates an e2fsck context */ errcode_t e2fsck_allocate_context(e2fsck_t *ret)