From 8f576022071a01861c7390a2143c4f62ff82197b Mon Sep 17 00:00:00 2001 From: David Polverari Date: Thu, 14 Sep 2023 02:18:25 +0000 Subject: [PATCH] autogen.sh: add check for pkg-config being present Since a ./configure switch was added to enable bash-completion installation support, pkg-config is now required during the build. This adds a check in autogen.sh to ensure pkg-config is installed. Closes: #19 --- autogen.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/autogen.sh b/autogen.sh index d45ba58..8a34d2c 100755 --- a/autogen.sh +++ b/autogen.sh @@ -2,6 +2,7 @@ # autogen.sh with clean option # Copyright 2016 Joao Eriberto Mota Filho +# Copyright 2023 David da Silva Polverari # # This file is under BSD-3-Clause license. # @@ -47,6 +48,13 @@ then exit 0 fi +env pkg-config --version > /dev/null 2>&1 +if [ $? -ne 0 ] +then + echo "pkg-config is missing. Please install it and run $0 again." + exit 1 +fi + # Do autoreconf autoreconf -i \ && { echo " "; \