From 33cc4739da693d87f9c1ad9686539791f36c4eae Mon Sep 17 00:00:00 2001 From: Milan Broz Date: Sun, 6 Sep 2020 10:41:49 +0200 Subject: [PATCH] Print warning if msgfmt utility from gettext is missing. User have to install gettext package or manually disable translation using --disable-nls. Also remove links to GNU packages ftp, all of these should by provided by native distro packaging systems. Fixes: #591. --- autogen.sh | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/autogen.sh b/autogen.sh index c6719f62..ffe5a9e6 100755 --- a/autogen.sh +++ b/autogen.sh @@ -9,16 +9,23 @@ DIE=0 (autopoint --version) < /dev/null > /dev/null 2>&1 || { echo echo "**Error**: You must have autopoint installed." - echo "Download the appropriate package for your distribution," - echo "or see http://www.gnu.org/software/gettext" + echo "Download the appropriate package for your distribution." DIE=1 } + +(msgfmt --version) < /dev/null > /dev/null 2>&1 || { + echo + echo "**Warning**: You should have gettext installed." + echo "Download the appropriate package for your distribution." + echo "To disable translation, you can also use --disable-nls" + echo "configure option." +} + (autoconf --version) < /dev/null > /dev/null 2>&1 || { echo - echo "**Error**: You must have autoconf installed to." - echo "Download the appropriate package for your distribution," - echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/" + echo "**Error**: You must have autoconf installed." + echo "Download the appropriate package for your distribution." DIE=1 } @@ -26,8 +33,7 @@ DIE=0 (libtool --version) < /dev/null > /dev/null 2>&1 || { echo echo "**Error**: You must have libtool installed." - echo "Get ftp://ftp.gnu.org/pub/gnu/" - echo "(or a newer version if it is available)" + echo "Download the appropriate package for your distribution." DIE=1 } } @@ -35,8 +41,7 @@ DIE=0 (automake --version) < /dev/null > /dev/null 2>&1 || { echo echo "**Error**: You must have automake installed." - echo "Get ftp://ftp.gnu.org/pub/gnu/" - echo "(or a newer version if it is available)" + echo "Download the appropriate package for your distribution." DIE=1 NO_AUTOMAKE=yes } @@ -47,8 +52,6 @@ test -n "$NO_AUTOMAKE" || (aclocal --version) < /dev/null > /dev/null 2>&1 || { echo echo "**Error**: Missing aclocal. The version of automake" echo "installed doesn't appear recent enough." - echo "Get ftp://ftp.gnu.org/pub/gnu/" - echo "(or a newer version if it is available)" DIE=1 }