Kaydet (Commit) 910a452f authored tarafından Bjoern Michaelsen's avatar Bjoern Michaelsen

move build dev-install cross-build-toolset to gbuild

üst 8a310e35
......@@ -8,13 +8,6 @@ else
CROSS_TOOLSET_RULE:=
endif
ifeq ($(filter all check unitcheck,$(MAKECMDGOALS)),)
gb_MAKETARGET=build
else
# fail early
gb_MAKETARGET=all
endif
.PHONY : build dev-install all cross-build-toolset install distro-pack-install clean clean-host clean-build distclean findunusedcode bootstrap
define forward_to_gbuild
......@@ -24,63 +17,11 @@ define forward_to_gbuild
$(patsubst allcheck,check,$(1))
endef
define forward_to_buildpl
. ./Env.Host.sh && cd $(1) && gb_MAKETARGET=$(gb_MAKETARGET) build.pl -P@BUILD_NCPUS@ -- -P@BUILD_MAX_JOBS@
endef
ifeq (@CROSS_COMPILING@,YES)
define all_install
To install, issue: @GNUMAKE@ install
Developers might prefer this way: @GNUMAKE@ dev-install -o build
To run smoketest, issue: @GNUMAKE@ check
endef
else
allinstall=For crosscompiles, please consult README.cross how to install it.
endif
UNAMESYSTEM=$(shell uname -s)
ifeq ($(UNAMESYSTEM),Linux)
devinstall_run=make debugrun
else
ifeq ($(UNAMESYSTEM),Linux)
devinstall_run=open @abs_builddir@/install/LibreOffice.app
else
define devinstall_run
cd @abs_builddir@/install/program
. ./ooenv
./soffice.bin
endef
endif
endif
all: build unitcheck
$(info)
$(info LibreOffice build succesfully finished.)
$(info)
$(info $(all_install))
$(info)
build: Makefile bootstrap src.downloaded $(CROSS_TOOLSET_RULE)
@$(call forward_to_buildpl,instsetoo_native)
smoketest: Makefile bootstrap src.downloaded $(CROSS_TOOLSET_RULE)
@$(call forward_to_buildpl,smoketestoo_native) && \
rm -f "@abs_builddir@"/install && \
ln -s "$$SOLARVER/$$INPATH"/installation/opt/ "@abs_builddir@"/install
dev-install: smoketest
$(info)
$(info Developer installation finished, you can now execute:)
$(info)
$(info $(devinstall_run))
check : allcheck
@true
cross-build-toolset:
$(call forward_to_buildpl,cross_toolset)
install: build
@. ./Env.Host.sh && \
echo "Installing in @INSTALLDIR@..." && \
......@@ -150,6 +91,15 @@ tags:
docs:
@$(call forward_to_gbuild,$@)
build: Makefile bootstrap src.downloaded $(CROSS_TOOLSET_RULE)
@$(call forward_to_gbuild,$@)
dev-install: Makefile bootstrap src.downloaded $(CROSS_TOOLSET_RULE)
$(call forward_to_gbuild,$@)
cross-build-toolset:
$(call forward_to_gbuild,$@)
findunusedcode:
# experimental callcatcher target
# http://www.skynet.ie/~caolan/Packages/callcatcher.html
......
......@@ -79,16 +79,46 @@ $(call gb_Module_get_target,%) :
mkdir -p $(dir $@) && \
touch $@)
.PHONY : build all clean unitcheck subsequentcheck
.PHONY : build all clean unitcheck subsequentcheck dev-install
.DEFAULT_GOAL := all
ifeq ($(strip $(gb_PARTIALBUILD)),)
check : subsequentcheck
define gb_Module_BUILDHINT
LibreOffice build succesfully finished.
To install, issue: $(MAKE) install
Developers might prefer this way: $(MAKE) dev-install -o build
To run smoketest, issue: $(MAKE) check
For crosscompiles, please consult README.cross how to install it.
endef
define gb_Module_DEVINSTALLHINT
Developer installation finished, you can now execute:
make debugrun # on Linux
dopen $(SRCDIR)/install/LibreOffice.app # on OSX
endef
else
gb_Module_BUILDHINT=
gb_Module_DEVINSTALLHINT=
endif
all : build unitcheck
$(info $(gb_Module_BUILDHINT))
build :
$(call gb_Output_announce,top level modules: $(foreach module,$(filter-out deliverlog,$^),$(notdir $(module))),$(true),ALL,6)
$(call gb_Output_announce,loaded modules: $(sort $(gb_Module_ALLMODULES)),$(true),ALL,6)
$(call gb_Output_announce_title,build done.)
$(call gb_Output_announce_bell)
$(info $(gb_Module_BUILDHINT))
unitcheck :
$(call gb_Output_announce,loaded modules: $(sort $(gb_Module_ALLMODULES)),$(true),CHK,6)
......@@ -115,12 +145,10 @@ check : unitcheck
debugrun : build
$(call gb_Module_DEBUGRUNCOMMAND)
ifeq ($(strip $(gb_PARTIALBUILD)),)
check : subsequentcheck
endif
dev-install :
@rm -f $(SRCDIR)/install && \
ln -s $(OUTDIR)/installation/opt/ $(SRCDIR)/install
$(info $(gb_Module_DEVINSTALLHINT))
define gb_Module_Module
gb_Module_ALLMODULES += $(1)
......
# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
#
# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License or as specified alternatively below. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# Major Contributor(s):
# [ Copyright (C) 2011 Bjoern Michaelsen <bjoern.michaelsen@canonical.com> (initial developer) ]
#
# All Rights Reserved.
#
# For minor contributions see the git repository.
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
# instead of those above.
ifeq ($(strip $(gb_PARTIALBUILD)),)
gb_Module_add_target=
gb_Module_add_check_target=
gb_Module_add_subsequentcheck_target=
gb_FULLDEPS=
endif # gb_PARTIALBUILD
# vim:set shiftwidth=4 softtabstop=4 noexpandtab:
......@@ -49,7 +49,7 @@ fetch: $(SRCDIR)/src.downloaded
$(WORKDIR)/bootstrap:
@cd $(SRCDIR) && ./bootstrap
@touch $@
@mkdir -p $(dir $@) && touch $@
bootstrap: $(WORKDIR)/bootstrap
......
# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
#
# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License or as specified alternatively below. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# Major Contributor(s):
# [ Copyright (C) 2011 Bjoern Michaelsen <bjoern.michaelsen@canonical.com> (initial developer) ]
#
# All Rights Reserved.
#
# For minor contributions see the git repository.
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
# instead of those above.
ifeq ($(strip $(gb_PARTIALBUILD)),)
ifeq ($(filter-out build,$(MAKECMDSEQUENCE)),)
gb_MAKETARGET=build
else
gb_MAKETARGET=all
endif
define gb_BuildplTarget_command
cd $(SRCDIR)/$(1) && unset MAKEFLAGS && $(SOLARENV)/bin/build.pl --all gb_MAKETARGET=$(gb_MAKETARGET)
endef
.PHONY: smoketestoo_native instsetoo_native cross-build-toolset dev-install all build
smoketestoo_native:
$(call gb_BuildplTarget_command,$@)
instsetoo_native:
$(call gb_BuildplTarget_command,$@)
cross-build-toolset:
$(call gb_BuildplTarget_command,$@)
dev-install: smoketestoo_native
all: instsetoo_native
build: instsetoo_native
endif # gb_PARTIALBUILD
# vim:set shiftwidth=4 softtabstop=4 noexpandtab:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment