From 0311239d7b41f9b66498f0dc50a35b5d4bf65360 Mon Sep 17 00:00:00 2001 From: Andre Heinecke Date: Sun, 14 Jul 2024 06:01:04 +0200 Subject: [PATCH] speedo: Add VERBOSE variable * build-aux/speedo.mk (VERBOSE): New variable. -- While the configuration output stays silent by default having the option to show it can be useful in case of errors. --- build-aux/speedo.mk | 33 ++++++++++++++++++++++++--------- 1 file changed, 24 insertions(+), 9 deletions(-) diff --git a/build-aux/speedo.mk b/build-aux/speedo.mk index f3abc16c1..683bab955 100644 --- a/build-aux/speedo.mk +++ b/build-aux/speedo.mk @@ -199,6 +199,9 @@ WIXPREFIX=$(shell readlink -f ~/w32root/wixtools) # If patchelf(1) is not available disable the command. PATCHELF := $(shell patchelf --version 2>/dev/null >/dev/null || echo "echo please run: ")patchelf +# Set this to 1 to get verbose output +VERBOSE=0 + # Read signing information from ~/.gnupg-autogen.rc define READ_AUTOGEN_template $(1) = $$(shell grep '^[[:blank:]]*$(1)[[:blank:]]*=' $$$$HOME/.gnupg-autogen.rc|cut -d= -f2|xargs) @@ -681,13 +684,24 @@ speedo_w64_build_list = $(speedo_w64_spkgs) # assignments), we check that the targetos has been given ifneq ($(TARGETOS),) +# Check for VERBOSE variable to conditionally set the silent option +ifeq ($(VERBOSE),1) + slient_flag = + autogen_sh_silent_flag = +else + slient_flag = --silent + autogen_sh_silent_flag = AUTOGEN_SH_SILENT=1 +endif + # Determine build and host system -build := $(shell $(topsrc)/autogen.sh --silent --print-build) +build := $(shell $(topsrc)/autogen.sh $(silent_flag) --print-build) ifeq ($(TARGETOS),w32) speedo_autogen_buildopt := --build-$(W32VERSION) speedo_autogen_buildopt6 := --build-w64 - host := $(shell $(topsrc)/autogen.sh --silent --print-host --build-$(W32VERSION)) - host6:= $(shell $(topsrc)/autogen.sh --silent --print-host --build-w64) + host := $(shell $(topsrc)/autogen.sh $(silent_flag) --print-host \ + --build-$(W32VERSION)) + host6:= $(shell $(topsrc)/autogen.sh $(silent_flag) --print-host \ + --build-w64) speedo_host_build_option := --host=$(host) --build=$(build) speedo_host_build_option6 := --host=$(host6) --build=$(build) speedo_w32_cflags := -mms-bitfields @@ -910,13 +924,14 @@ else ifneq ($(findstring $(1),$(speedo_gnupg_style)),) mkdir "$$$${pkgbdir}"; \ cd "$$$${pkgbdir}"; \ if [ -n "$(speedo_autogen_buildopt)" ]; then \ - eval AUTOGEN_SH_SILENT=1 $(W32VERSION)root="$(idir)" \ + eval $(autogen_sh_silent_flag) \ + $(W32VERSION)root="$(idir)" \ "$$$${pkgsdir}/autogen.sh" \ $(speedo_autogen_buildopt) \ $$$${pkgcfg} $$$${pkgextracflags}; \ else \ eval "$$$${pkgsdir}/configure" \ - --silent \ + $(silent_flag) \ --enable-maintainer-mode \ --prefix="$(idir)" \ $$$${pkgcfg} $$$${pkgextracflags}; \ @@ -926,7 +941,7 @@ else mkdir "$$$${pkgbdir}"; \ cd "$$$${pkgbdir}"; \ eval "$$$${pkgsdir}/configure" \ - --silent $(speedo_host_build_option) \ + $(silent_flag) $(speedo_host_build_option) \ --prefix="$(idir)" \ $$$${pkgcfg} $$$${pkgextracflags}; \ ) @@ -945,13 +960,13 @@ else ifneq ($(findstring $(1),$(speedo_gnupg_style)),) mkdir "$$$${pkgbdir}"; \ cd "$$$${pkgbdir}"; \ if [ -n "$(speedo_autogen_buildopt)" ]; then \ - eval AUTOGEN_SH_SILENT=1 w64root="$(idir6)" \ + eval $(autogen_sh_silent_flag) w64root="$(idir6)" \ "$$$${pkgsdir}/autogen.sh" \ $(speedo_autogen_buildopt6) \ $$$${pkgcfg} $$$${pkgextracflags}; \ else \ eval "$$$${pkgsdir}/configure" \ - --silent \ + $(silent_flag) \ --enable-maintainer-mode \ --prefix="$(idir6)" \ $$$${pkgcfg} $$$${pkgextracflags}; \ @@ -961,7 +976,7 @@ else mkdir "$$$${pkgbdir}"; \ cd "$$$${pkgbdir}"; \ eval "$$$${pkgsdir}/configure" \ - --silent $(speedo_host_build_option6) \ + $(silent_flag) $(speedo_host_build_option6) \ --prefix="$(idir6)" \ $$$${pkgcfg} $$$${pkgextracflags}; \ )