Fixed build scripts to build successfully with automake >= 1.12

Removed -Wall option from AM_INIT_AUTOMAKE due to following reasons:

 * -Wall enable some warning (-Wportability, -Wextra-portability) with automake >= 1.12,
   and build failed...
   Automake 1.12 break some compatibility to fix long-awaited bug.
   Any explicit enabling or disabling of a warning category
   always take precedence over the set of warning categories(ex. -Wall)
   implied by the strictness mode(ex. foreign).

   Please read the release note of automake 1.12 for more information:
   http://lists.gnu.org/archive/html/automake/2012-04/msg00060.html