Makefile.in |   12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

New commits:
commit 98fb8f9a1b6c8d5550c07bb5f718031be4f5731e
Author:     Jan Holesovsky <[email protected]>
AuthorDate: Mon Oct 21 09:21:19 2024 +0200
Commit:     Tomaž Vajngerl <[email protected]>
CommitDate: Tue Dec 2 08:45:14 2025 +0100

    Check that the build starts with the right make version
    
    Can be a problem on macOS - where the 'make' is version is too old for
    gbuild.
    
    Change-Id: I1039072a2c36b9f960467176118bce457732f0b7
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194560
    Reviewed-by: Tomaž Vajngerl <[email protected]>
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Reviewed-by: Michael Stahl <[email protected]>

diff --git a/Makefile.in b/Makefile.in
index 74044594d157..f23e1f0aa5c7 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -9,7 +9,7 @@
 
 gb_Top_MODULE_CHECK_TARGETS := slowcheck unitcheck subsequentcheck perfcheck 
uicheck screenshot
 
-.PHONY : check-if-root bootstrap gbuild build build-non-l10n-only 
build-l10n-only check clean clean-build clean-host test-install distclean 
distro-pack-install docs download etags fetch get-submodules id install 
install-gdb-printers install-strip tags debugrun help showmodules translations 
packageinfo coverage internal.clean $(gb_Top_MODULE_CHECK_TARGETS)
+.PHONY : check-if-root check-makefile-version bootstrap gbuild build 
build-non-l10n-only build-l10n-only check clean clean-build clean-host 
test-install distclean distro-pack-install docs download etags fetch 
get-submodules id install install-gdb-printers install-strip tags debugrun help 
showmodules translations packageinfo coverage internal.clean 
$(gb_Top_MODULE_CHECK_TARGETS)
 
 MAKECMDGOALS?=build
 build_goal:=$(if $(filter build uicheck,$(MAKECMDGOALS)),build)\
@@ -78,6 +78,14 @@ check-if-root:
                fi \
        fi
 
+check-makefile-version:
+       @if awk 'BEGIN {exit ($(MAKE_VERSION) >= 4.0) ;}' ; then \
+               echo; \
+               echo "Running with make $(MAKE_VERSION) is likely to cause 
problems, try with $$GNUMAKE instead."; \
+               echo; \
+               exit 1; \
+       fi
+
 gb_Side ?= host
 
 include $(BUILDDIR)/config_$(gb_Side).mk
@@ -289,7 +297,7 @@ endif
 #
 # Bootstrap
 #
-bootstrap: check-if-root compilerplugins
+bootstrap: check-if-root check-makefile-version compilerplugins
 
 #
 # Build

Reply via email to