Makes autogen.sh workable under Mac and Linux

Autogen depends on libtoolize that is known by glibtoolize on MacOS.
This patch just check if libtoolize is workable if not, try glibtoolize.