[flac-dev] [PATCH 5/5] configure: modernize autoconf usage
Max Horn
max at quendi.de
Wed Dec 12 12:33:55 PST 2012
In particular:
- quote several macro arguments properly
- switch to the extended version of AC_INIT
- replace AM_CONFIG_HEADER by AC_CONFIG_HEADERS
- remove obsolete extra AC_CHECK_SIZEOF param
- upgrade minimal automake version from 1.7 to 1.11
(which is when dist-xz was introduced)
Signed-off-by: Max Horn <max at quendi.de>
---
configure.ac | 13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/configure.ac b/configure.ac
index 022cba8..5cbcbc7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -19,10 +19,11 @@
# instead of FLAC__ since autoconf triggers off 'AC_' in strings
AC_PREREQ(2.60)
-AC_INIT([flac], [1.2.1])
+AC_INIT([flac], [1.2.1], [flac-dev at xiph.org], [flac], [http://flac.sourceforge.net/])
+AC_CONFIG_HEADERS([config.h])
AC_CONFIG_SRCDIR([src/flac/main.c])
AC_CONFIG_MACRO_DIR([m4])
-AM_INIT_AUTOMAKE([foreign 1.7 -Wall tar-pax no-dist-gzip dist-xz subdir-objects])
+AM_INIT_AUTOMAKE([foreign 1.11 -Wall tar-pax no-dist-gzip dist-xz subdir-objects])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
user_cflags=$CFLAGS
@@ -39,18 +40,16 @@ AC_PROG_MAKE_SET
AC_SYS_LARGEFILE
AC_FUNC_FSEEKO
-AC_CHECK_SIZEOF(void*,0)
+AC_CHECK_SIZEOF([void*])
AC_SEARCH_LIBS([lround],[m], [AC_DEFINE(HAVE_LROUND,1,lround support)])
-#@@@ new name is AC_CONFIG_HEADERS
-AM_CONFIG_HEADER(config.h)
-AC_LANG_PUSH(C++)
+AC_LANG_PUSH([C++])
# c++ flavor first
AC_C_VARARRAYS
if test $ac_cv_c_vararrays = yes; then
AC_DEFINE([HAVE_CXX_VARARRAYS], 1, [Define to 1 if C++ supports variable-length arrays.])
fi
-AC_LANG_POP(C++)
+AC_LANG_POP([C++])
# c flavor
AC_HEADER_STDC
--
1.8.0.1.525.gaaf5ad5
More information about the flac-dev
mailing list