OSDN Git Service

Work with automake-1.10.
authorJim Meyering <jim@meyering.net>
Mon, 12 Feb 2007 22:30:46 +0000 (23:30 +0100)
committerOtavio Salvador <otavio@ossystems.com.br>
Tue, 13 Feb 2007 11:20:51 +0000 (09:20 -0200)
I've just tried building parted from scratch (running ./autogen.sh
after git-clone) and hit a couple of snags:

Without aclocal's -I m4, ./autogen.sh produced this:

  configure.ac:192: warning: macro `AM_GNU_GETTEXT_VERSION' not found in library
  configure.ac:193: warning: macro `AM_GNU_GETTEXT' not found in library
  configure.ac:192: error: possibly undefined macro: AM_GNU_GETTEXT_VERSION
        If this token and others are legitimate, please use m4_pattern_allow.
        See the Autoconf documentation.

With automake-1.10, I got this:

    parted/Makefile.am:5: compiling `command.c' with per-target flags requires `AM_PROG_CC_C_O' in `configure.ac'

Here's a patch that fixes those and also removes some trailing blanks.

autogen.sh
configure.ac

index 41df3a9..3ba386f 100755 (executable)
@@ -1,7 +1,7 @@
 #!/bin/sh
 
 git log --pretty=medium | fold -s > ChangeLog
-aclocal
+aclocal -I m4
 autoconf -f
 autoheader
 autopoint -f
index 7d6914f..d47d5fa 100644 (file)
@@ -1,5 +1,5 @@
 dnl GNU Parted - a library and front end for manipulation hard disk partitions
-dnl Copyright (C) 1998, 1999, 2000, 2001, 2002, 2005
+dnl Copyright (C) 1998, 1999, 2000, 2001, 2002, 2005, 2007
 dnl                     Free Software Foundation, Inc.
 dnl
 dnl This file may be modified and/or distributed without restriction.
@@ -40,7 +40,7 @@ PACKAGE=parted
 VERSION=$PED_VERSION
 
 AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
+
 AM_CONFIG_HEADER(config.h)
 
 AC_CANONICAL_HOST
@@ -165,6 +165,7 @@ dnl Check for programs.
 AC_ISC_POSIX
 AC_PROG_CC
 AC_PROG_GCC_TRADITIONAL
+AM_PROG_CC_C_O
 
 dnl This test must come as early as possible after the compiler configuration
 dnl tests, because the choice of the file model can (in principle) affect
@@ -364,7 +365,7 @@ if test "$OS" = beos; then
        dnl Include the socket library, as it is a depedency of libuuid
        dnl and so also of us (due to socket() call in libuuid)
        OS_LIBS="$OS_LIBS -lsocket"
-fi     
+fi
 
 AC_SUBST(OS_LIBS)
 
@@ -387,7 +388,7 @@ If you can't find one try:
        exit
 )
 
-AC_CHECK_HEADERS(getopt.h) 
+AC_CHECK_HEADERS(getopt.h)
 
 dnl required for libparted/llseek.c  (TODO: make linux-x86 only)
 if test "$OS" = linux; then