Adding autotools support
Adding test skeleton
Fixing some minor compilation errors