diff options
author | NAKAMURA Takumi <geek4civic@gmail.com> | 2011-03-08 12:25:10 +0000 |
---|---|---|
committer | NAKAMURA Takumi <geek4civic@gmail.com> | 2011-03-08 12:25:10 +0000 |
commit | 027248567b91440b0625cb184bb69d6171deaac5 (patch) | |
tree | 5c0549d04a0a7ca9a5b3dd89ad5c15f52c48d917 /Makefile.rules | |
parent | caa5a5dedbe3dba7b54d872fa66cdabd9fe70d12 (diff) | |
download | llvm-027248567b91440b0625cb184bb69d6171deaac5.tar.gz llvm-027248567b91440b0625cb184bb69d6171deaac5.tar.bz2 llvm-027248567b91440b0625cb184bb69d6171deaac5.tar.xz |
Reapply r127073(partially): Introduce $(ECHOPATH) to print DOSish path string on MSYS bash for alternative of $(ECHO).
On mingw and python/w32, lit would not be expected to understand MSYS-style path.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127239 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'Makefile.rules')
-rw-r--r-- | Makefile.rules | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Makefile.rules b/Makefile.rules index 57198844f5..a04eba1f45 100644 --- a/Makefile.rules +++ b/Makefile.rules @@ -719,6 +719,24 @@ BaseNameSources := $(sort $(basename $(Sources))) ObjectsO := $(BaseNameSources:%=$(ObjDir)/%.o) ObjectsBC := $(BaseNameSources:%=$(ObjDir)/%.bc) +#---------------------------------------------------------- +# For Mingw MSYS bash and Python/w32: +# +# $(ECHOPATH) prints DOSish pathstring. +# ex) $(ECHOPATH) /include/sys/types.h +# --> C:/mingw/include/sys/types.h +# built-in "echo" does not transform path to DOSish path. +# +# FIXME: It would not be needed when MSYS's python +# were provided. +#---------------------------------------------------------- + +ifeq (-mingw32,$(findstring -mingw32,$(BUILD_TRIPLE))) + ECHOPATH := $(Verb)python -u -c "import sys;print ' '.join(sys.argv[1:])" +else + ECHOPATH := $(Verb)$(ECHO) +endif + ############################################################################### # DIRECTORIES: Handle recursive descent of directory structure ############################################################################### |