diff options
author | Bastien Nocera <hadess@hadess.net> | 2006-10-20 13:48:21 +0000 |
---|---|---|
committer | Bastien Nocera <hadess@src.gnome.org> | 2006-10-20 13:48:21 +0000 |
commit | c9abb85cb52a29838bceaf147cc8a7e43bf06eff (patch) | |
tree | 0ed01378cff45d67b0bec36e6d94ceae3fd58baa | |
parent | 1f7d1be8d6f32cac072878d44a0ea652bcc034e2 (diff) | |
download | shared-mime-info-c9abb85cb52a29838bceaf147cc8a7e43bf06eff.tar.gz |
exit from the check_m4macros function as soon as we have detected some
2006-10-20 Bastien Nocera <hadess@hadess.net>
* macros2/gnome-autogen.sh: exit from the check_m4macros function as
soon as we have detected some undefined macros, rather than leaving
the developer wondering what the problem is
svn path=/trunk/; revision=3877
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | macros2/gnome-autogen.sh | 21 |
2 files changed, 22 insertions, 5 deletions
@@ -1,3 +1,9 @@ +2006-10-20 Bastien Nocera <hadess@hadess.net> + + * macros2/gnome-autogen.sh: exit from the check_m4macros function as + soon as we have detected some undefined macros, rather than leaving + the developer wondering what the problem is + 2006-05-10 Kjartan Maraas <kmaraas@gnome.org> * gnome-common.spec.in: Fix a typo. diff --git a/macros2/gnome-autogen.sh b/macros2/gnome-autogen.sh index b9b7eeaf..6a69fc5b 100644 --- a/macros2/gnome-autogen.sh +++ b/macros2/gnome-autogen.sh @@ -141,6 +141,17 @@ add_to_cm_macrodirs() { } # Usage: +# print_m4macros_error +# Prints an error message saying that autoconf macros were misused +print_m4macros_error() { + printerr "***Error***: some autoconf macros required to build $PKG_NAME" + printerr " were not found in your aclocal path, or some forbidden" + printerr " macros were found. Perhaps you need to adjust your" + printerr " ACLOCAL_FLAGS?" + printerr +} + +# Usage: # check_m4macros # Checks that all the requested macro files are in the aclocal macro path # Uses REQUIRED_M4MACROS and ACLOCAL variables. @@ -202,6 +213,10 @@ check_m4macros() { fi done fi + if [ "$cm_status" != 0 ]; then + print_m4macros_error + return $cm_status + fi if [ -n "$FORBIDDEN_M4MACROS" ]; then printbold "Checking for forbidden M4 macros..." # check that each macro file is in one of the macro dirs @@ -220,11 +235,7 @@ check_m4macros() { done fi if [ "$cm_status" != 0 ]; then - printerr "***Error***: some autoconf macros required to build $PKG_NAME" - printerr " were not found in your aclocal path, or some forbidden" - printerr " macros were found. Perhaps you need to adjust your" - printerr " ACLOCAL_FLAGS?" - printerr + print_m4macros_error fi return $cm_status } |