diff options
author | Jan Holesovsky <kendy@suse.cz> | 2011-12-05 00:57:12 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2011-12-05 01:46:51 +0100 |
commit | f259162cf511528c210eb71f51e63b5ff6838ff5 (patch) | |
tree | c5af3e4aa402e158f62016391acdc0f337f2f0fa /solenv | |
parent | 9d5d04776f0a163796a41446852ec59ba76c9c1a (diff) |
The evil in BuildDirs.mk has to be undone by another evil.
Diffstat (limited to 'solenv')
-rwxr-xr-x | solenv/bin/build.pl | 12 | ||||
-rw-r--r-- | solenv/gbuild/BuildDirs.mk | 13 |
2 files changed, 23 insertions, 2 deletions
diff --git a/solenv/bin/build.pl b/solenv/bin/build.pl index 4957627d9c43..ec8dc1132e1d 100755 --- a/solenv/bin/build.pl +++ b/solenv/bin/build.pl @@ -76,6 +76,18 @@ # # ######################### + # This is to undo the EVIL in solenv/gbuild/BuildDirs.mk + if ($ENV{OS_FOR_BUILD} eq 'WNT') { + $ENV{WORKDIR} = `cygpath -m '$ENV{WORKDIR}'`; + $ENV{OUTDIR} = `cygpath -m '$ENV{OUTDIR}'`; + $ENV{OUTDIR_FOR_BUILD} = `cygpath -m '$ENV{OUTDIR_FOR_BUILD}'`; + $ENV{SRCDIR} = `cygpath -m '$ENV{SRCDIR}'`; + chomp($ENV{WORKDIR}); + chomp($ENV{OUTDIR}); + chomp($ENV{OUTDIR_FOR_BUILD}); + chomp($ENV{SRCDIR}); + } + my $modules_number++; my $perl = 'perl'; my $remove_command = 'rm -rf'; diff --git a/solenv/gbuild/BuildDirs.mk b/solenv/gbuild/BuildDirs.mk index 6a0933b33c2e..5955082d54d7 100644 --- a/solenv/gbuild/BuildDirs.mk +++ b/solenv/gbuild/BuildDirs.mk @@ -35,8 +35,17 @@ ifeq ($(strip $(SOLARENV)),) $(error SOLARENV variable is empty, no environment set, aborting) endif -# HACK -# unixify windoze paths +# The entire gbuild operates in unix paths, and then when calling the +# native tools, converts them back to the Windows native paths. +# +# The path overwriting below is EVIL, because after the recent changes when +# every module (even build.pl-based) is routed through gbuild, the modules +# using build.pl-based build will get OUTDIR in the cygwin format. +# +# To undo this, we explicitly set these vars to native Windows paths in +# build.pl again, otherwise we would have potentially different behavior in +# build.pl-based modules when you build them from the toplevel (using make +# all), and from the module itself (using cd module ; build ) ifeq ($(OS_FOR_BUILD),WNT) override WORKDIR := $(shell cygpath -u $(WORKDIR)) override OUTDIR := $(shell cygpath -u $(OUTDIR)) |