Fixing build against uclibc

Some minor changes made to be compatible with >=uClibc-0.9.30.2