tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit 33999afe4b35916d9e072dcb1808598b8f354826
parent bbd43b356ba4ea2126839bc601aee54c3b41fb64
Author: serge-sans-paille <sguelton@mozilla.com>
Date:   Tue,  4 Nov 2025 07:48:36 +0000

Bug 1995595 - Move make version check to moz.configure r=glandium

This could be dependent of the backend, but it's not going to happen any
soon :-)

Differential Revision: https://phabricator.services.mozilla.com/D269430

Diffstat:
MMakefile.in | 8--------
Mjs/src/Makefile.in | 8--------
Mmoz.configure | 20+++++++++++++++++++-
3 files changed, 19 insertions(+), 17 deletions(-)

diff --git a/Makefile.in b/Makefile.in @@ -3,14 +3,6 @@ # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/. -ifeq (,$(MAKE_VERSION)) -$(error GNU Make is required) -endif -make_min_ver := 3.81 -ifneq ($(make_min_ver),$(firstword $(sort $(make_min_ver) $(MAKE_VERSION)))) -$(error GNU Make $(make_min_ver) or higher is required) -endif - export TOPLEVEL_BUILD := 1 default:: diff --git a/js/src/Makefile.in b/js/src/Makefile.in @@ -4,14 +4,6 @@ # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/. -ifeq (,$(MAKE_VERSION)) -$(error GNU Make is required) -endif -make_min_ver := 3.81 -ifneq ($(make_min_ver),$(firstword $(sort $(make_min_ver) $(MAKE_VERSION)))) -$(error GNU Make $(make_min_ver) or higher is required) -endif - DASH_R = -r # Define keyword generator before rules.mk, see bug 323979 comment 50 diff --git a/moz.configure b/moz.configure @@ -634,7 +634,25 @@ def possible_makes(make, host): return candidates -check_prog("GMAKE", possible_makes, bootstrap="mozmake") +gmake = check_prog("GMAKE", possible_makes, bootstrap="mozmake") + + +@depends(gmake) +@checking("for gmake version") +def gmake_version(prog): + out = check_cmd_output(prog, "--version") + version_line = out.splitlines()[0] + if not version_line.startswith("GNU Make"): + die("GNU make is required") + return Version(version_line[8:].strip()) + + +@depends(gmake_version) +def check_gmake_version(version): + make_min_ver = Version("3.81") + if version < make_min_ver: + die(f"GNU Make {make_min_ver} or higher is required") + # watchman detection # ==============================================================