fix Makefile.in

- unify ~all gbuild targets to one gbuild call
- kill CHECK_PARALLELISM as we dont respect it consistently anyway
- ${MODULE}.subsequentcheck needs no specialcasing now anymore too
- should fix e.g. "make unitcheck slowcheck subsequentcheck" calls

Change-Id: I4238d7de599cb9fbaf09f60539d6655b85b87c29
Reviewed-on: https://gerrit.libreoffice.org/6722
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
This commit is contained in:
Bjoern Michaelsen 2013-11-19 14:25:45 +01:00 committed by Björn Michaelsen
parent cc27264466
commit 4eebd65858
3 changed files with 8 additions and 33 deletions

View file

@ -7,7 +7,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/. # file, You can obtain one at http://mozilla.org/MPL/2.0/.
# #
.PHONY : all bootstrap build build-non-l10n-only build-l10n-only check clean clean-build clean-host test-install distclean distro-pack-install docs download fetch findunusedcode get-submodules id install install-strip subsequentcheck tags .PHONY : all bootstrap gbuild build build-non-l10n-only build-l10n-only check clean clean-build clean-host test-install distclean distro-pack-install docs download fetch findunusedcode get-submodules id install install-strip subsequentcheck tags debugrun help slowcheck translations unitcheck
ifeq ($(MAKECMDGOALS),) ifeq ($(MAKECMDGOALS),)
MAKECMDGOALS:=all MAKECMDGOALS:=all
@ -79,12 +79,9 @@ define gbuild_module_rules
$(1): bootstrap fetch $(1): bootstrap fetch
cd $(SRCDIR)/$(2) && $(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) cd $(SRCDIR)/$(2) && $(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS)
$(1).build $(1).check $(1).clean $(1).showdeliverables: $(1).build $(1).check $(1).clean $(1).showdeliverables $(1).subsequentcheck:
cd $(SRCDIR)/$(2) && $(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) $$(patsubst $(1).%,%,$$@) cd $(SRCDIR)/$(2) && $(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) $$(patsubst $(1).%,%,$$@)
$(1).subsequentcheck:
cd $(SRCDIR)/$(2) && $(GNUMAKE) -j $(CHECK_PARALLELISM) $(GMAKE_OPTIONS) subsequentcheck
$(1).all: bootstrap fetch $(1).all: bootstrap fetch
$(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild $(WORKDIR)/Module/$(1) $(if $(CROSS_COMPILING),,$(WORKDIR)/Module/check/$(1) $(WORKDIR)/Module/slowcheck/$(1)) $(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild $(WORKDIR)/Module/$(1) $(if $(CROSS_COMPILING),,$(WORKDIR)/Module/check/$(1) $(WORKDIR)/Module/slowcheck/$(1))
@ -231,23 +228,22 @@ bootstrap: compilerplugins
# #
# Build # Build
# #
# Note: if invoked as "make check" this will also run subsequentcheck! # Note: this will pipe through all gbuild targets to ... gbuild
# with some translations like "build"->"all" for historic reasons
# #
build: bootstrap fetch $(if $(CROSS_COMPILING),cross-toolset) build: bootstrap fetch $(if $(CROSS_COMPILING),cross-toolset)
ifneq ($(filter-out WNT MACOSX IOS ANDROID,$(OS)),) ifneq ($(filter-out WNT MACOSX IOS ANDROID,$(OS)),)
mkdir -p $(INSTDIR) && install-gdb-printers -a $(INSTDIR) -c mkdir -p $(INSTDIR) && install-gdb-printers -a $(INSTDIR) -c
endif endif
$(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild \ $(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild \
all $(if $(filter check,$(MAKECMDGOALS)),subsequentcheck) $(if $(filter build,$(MAKECMDGOALS)),all) \
$(if $(filter build-nocheck,$(MAKECMDGOALS)),build) \
$(filter all build-l10n-only build-non-l10n-only debugrun help slowcheck translations unitcheck subsequentcheck,$(MAKECMDGOALS))
ifeq ($(OS),IOS) ifeq ($(OS),IOS)
$(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) ios $(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) ios
endif endif
build-nocheck: bootstrap fetch $(if $(CROSS_COMPILING),cross-toolset) build-nocheck check debugrun help slowcheck translations unitcheck subsequentcheck : build
$(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild build
build-l10n-only build-non-l10n-only: bootstrap fetch $(if $(CROSS_COMPILING),cross-toolset)
$(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild $@
cross-toolset: bootstrap fetch cross-toolset: bootstrap fetch
$(GNUMAKE) gb_Side=build -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild build-tools $(GNUMAKE) gb_Side=build -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild build-tools
@ -384,8 +380,6 @@ findunusedcode:
findunusedheaders: findunusedheaders:
$(SRCDIR)/bin/find-unusedheaders.pl $(SRCDIR)/bin/find-unusedheaders.pl
# the actual running of subsequentcheck is now done in "build" target => faster
check: build
dump-deps: dump-deps:
@$(SRCDIR)/bin/module-deps.pl $(GNUMAKE) $(SRCDIR)/Makefile.gbuild @$(SRCDIR)/bin/module-deps.pl $(GNUMAKE) $(SRCDIR)/Makefile.gbuild
@ -393,13 +387,6 @@ dump-deps:
dump-deps-png: dump-deps-png:
@$(SRCDIR)/bin/module-deps.pl $(GNUMAKE) $(SRCDIR)/Makefile.gbuild | dot -Tpng -o lo.png @$(SRCDIR)/bin/module-deps.pl $(GNUMAKE) $(SRCDIR)/Makefile.gbuild | dot -Tpng -o lo.png
subsequentcheck :| $(if $(filter-out subsequentcheck,$(MAKECMDGOALS)),build)
$(GNUMAKE) -j $(CHECK_PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild $@
.PHONY : debugrun help slowcheck translations unitcheck
debugrun help slowcheck translations unitcheck :
$(GNUMAKE) -j $(PARALLELISM) $(GMAKE_OPTIONS) -f $(SRCDIR)/Makefile.gbuild $@
define GbuildToIdeIntegration define GbuildToIdeIntegration
$(1)-ide-integration: $(1)-ide-integration:
cd $(SRCDIR) && (make cmd -npf Makefile.gbuild all || true) | $(SRCDIR)/bin/gbuild-to-ide --ide $(1) cd $(SRCDIR) && (make cmd -npf Makefile.gbuild all || true) | $(SRCDIR)/bin/gbuild-to-ide --ide $(1)

View file

@ -50,7 +50,6 @@ export CC=@CC@
export CDR_CFLAGS=$(gb_SPACE)@CDR_CFLAGS@ export CDR_CFLAGS=$(gb_SPACE)@CDR_CFLAGS@
export CDR_LIBS=$(gb_SPACE)@CDR_LIBS@ export CDR_LIBS=$(gb_SPACE)@CDR_LIBS@
@x_CFLAGS@ export CFLAGS=@CFLAGS@ @x_CFLAGS@ export CFLAGS=@CFLAGS@
export CHECK_PARALLELISM?=@CHECK_PARALLELISM@
export CLANGBUILD=@CLANGBUILD@ export CLANGBUILD=@CLANGBUILD@
export CLANGDIR=@CLANGDIR@ export CLANGDIR=@CLANGDIR@
export CLUCENE_CFLAGS=$(gb_SPACE)@CLUCENE_CFLAGS@ export CLUCENE_CFLAGS=$(gb_SPACE)@CLUCENE_CFLAGS@

View file

@ -12446,17 +12446,6 @@ fi
AC_MSG_RESULT([$PARALLELISM]) AC_MSG_RESULT([$PARALLELISM])
AC_SUBST(PARALLELISM) AC_SUBST(PARALLELISM)
# ===================================================================
# Number of parallel jobs to be executed during subsequenttest
# ===================================================================
AC_MSG_CHECKING([for maximum no. of jobs during subsequenttest])
CHECK_PARALLELISM=$PARALLELISM
if test "$with_check_jobs" != ""; then
CHECK_PARALLELISM="$with_check_jobs"
fi
AC_MSG_RESULT([$CHECK_PARALLELISM])
AC_SUBST(CHECK_PARALLELISM)
# #
# Set up ILIB for MSVC build # Set up ILIB for MSVC build
# #