Missing prototype and includes.

* `transaction_remove()` wasn't declared in header;
* `<ctype.h>` needed for functions `isspace()`, `isprint()` etc.
Typo in comment.
Fixed bad/missing return codes in `lwm2m_set_bootstrap_server()` and `lwm2m_handle_packet()`.
Removed unused variables, fixed some signedness issues.
Added CMake build artifacts to `.gitignore`.