Free some resources
Hack for windows + libtool warnings