diff options
author | Michael Stahl <mst@openoffice.org> | 2011-04-18 15:59:15 +0000 |
---|---|---|
committer | Bjoern Michaelsen <bjoern.michaelsen@canonical.com> | 2011-06-17 18:18:51 +0200 |
commit | 9360e44ce3c3db981fca2c52bf68ddd6940c12eb (patch) | |
tree | cd325464cdaf7cd60982b65217f43c2c6d90d553 | |
parent | 00610e27d156a8c56d33debbaba4ac55b7ec9e87 (diff) |
gnumake4: #i117687#: source the right *Env.Set.sh in bootstrap: [hg:ffdb9023a592]
add source_soenv.sh: detects the platform and sources the right *Env.Set.sh.
bootstrap and the root GNUmakefile call source_soenv.sh.
-rw-r--r-- | GNUmakefile | 12 | ||||
-rw-r--r-- | bootstrap.1 | 8 |
2 files changed, 18 insertions, 2 deletions
diff --git a/GNUmakefile b/GNUmakefile index 018b21e3f1ac..9c2d78df9ac5 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -25,13 +25,21 @@ # #************************************************************************* +# if no environment is set, try to find one, source it and re-exec ifeq ($(strip $(SOLARENV)),) -$(error No environment set!) -endif + +all: + if test -f ./source_soenv.sh; then . ./source_soenv.sh; fi && \ + if test -z "$${SOLARENV}"; then echo "No environment set!"; exit 1; fi && \ + $(MAKE) + +else # SOLARENV GBUILDDIR := $(SOLARENV)/gbuild include $(GBUILDDIR)/gbuild.mk $(foreach repo,$(gb_REPOS),$(eval $(call gb_Module_make_global_targets,$(wildcard $(repo)/Module_*.mk)))) +endif # SOLARENV + # vim: set noet sw=4 ts=4: diff --git a/bootstrap.1 b/bootstrap.1 index 24edc7581e97..2a475bf1ef52 100644 --- a/bootstrap.1 +++ b/bootstrap.1 @@ -1,4 +1,12 @@ +if test -z "${SOLARENV}"; then + if test -f ./source_soenv.sh; then . ./source_soenv.sh; fi +fi +if test -z "${SOLARENV}"; then + echo "bootstrap: No environment set!" + exit 1 +fi + # remove aliases set by *Env.Set.sh unalias mkout unalias deliver |