From a97685e7029afebf3781d694509dc9530bb7c6af Mon Sep 17 00:00:00 2001 From: Ben Noordhuis Date: Mon, 5 Aug 2013 23:27:28 +0200 Subject: [PATCH] build: add automake serial-tests version check The serial-tests directive was added in automake v0.11. Add an ad-hoc version check to find out if it's safe to enable. Fixes the autotools build with older versions of automake. --- configure.ac | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 72fa57a1..f50e6353 100644 --- a/configure.ac +++ b/configure.ac @@ -14,7 +14,11 @@ AC_PREREQ(2.57) AC_INIT([libuv], [0.11.5], [https://github.com/joyent/libuv/issues]) -AM_INIT_AUTOMAKE([foreign serial-tests subdir-objects -Wall -Werror]) +# Use AM_SILENT_RULES as an ad-hoc version check to find out if it's safe +# to use the serial-tests directive. Both were added in automake v0.11. +AM_INIT_AUTOMAKE(m4_ifdef([AM_SILENT_RULES], + [-Wall -Werror foreign subdir-objects serial-tests], + [-Wall -Werror foreign subdir-objects])) AC_CONFIG_MACRO_DIR([m4]) AC_CANONICAL_HOST AC_ENABLE_SHARED