Re: [AD] Patch for makefile issue when compiling MSVC with Cygwin |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
- To: "Coordination of admins/developers of the game programming library Allegro" <alleg-developers@xxxxxxxxxx>
- Subject: Re: [AD] Patch for makefile issue when compiling MSVC with Cygwin
- From: "Milan Mimica" <milan.mimica@xxxxxxxxxx>
- Date: Thu, 21 Dec 2006 00:06:02 +0100
On 19/12/06, Andrei Ellman <ae-a-alleg@xxxxxxxxxx> wrote:
+ifdef ALLEGRO_USE_CYGWIN
+
+# Note: Using ':=' instead of '=' to improve performance of parsing makefile.
+# ?: Is there a more elegant way of setting MSVCDIR_S? MSVCDIR_S := $(shell cygpath $(MSVCDIR_MSVCDIR)) does not seem to work.
+ifdef MSVCDIR
+ MSVCDIR_S := $(shell cygpath $$MSVCDIR)
+else
+ifdef MSVCDir
+ MSVCDIR_S := $(shell cygpath $$MSVCDir)
+endif
+endif
+
+ MSVCDIR_U = $(subst \,/,$(MSVCDIR_S))
+ MSVCDIR_D = $(subst /,\,$(MSVCDIR_S))
+else
+ MSVCDIR_U = $(subst \,/,$(MSVCDIR_MSVCDIR))
+ MSVCDIR_D = $(subst /,\,$(MSVCDIR_MSVCDIR))
+endif # ALLEGRO_USE_CYGWIN
First, there is also VCINSTALLDIR to check.
Second, this isn't working for me. The following works, can you also try it out?
ifdef ALLEGRO_USE_CYGWIN
# Note: Using ':=' instead of '=' to improve performance of parsing
makefile.
# ?: Is there a more elegant way of setting MSVCDIR_S? MSVCDIR_S :=
$(shell cygpath $(MSVCDIR_MSVCDIR)) does not seem to work.
ifdef MSVCDIR
MSVCDIR_S := $(shell cygpath -s -w "$(MSVCDIR)")
endif
ifdef MSVCDir
MSVCDIR_S := $(shell cygpath -s -w "$(MSVCDir)")
endif
ifdef VCINSTALLDIR
MSVCDIR_S := $(shell cygpath -s -w "$(VCINSTALLDIR)")
endif
MSVCDIR_U = $(subst \,/,$(MSVCDIR_S))
MSVCDIR_D = $(subst /,\,$(MSVCDIR_D))
else
MSVCDIR_U = $(subst \,/,$(MSVCDIR_MSVCDIR))
MSVCDIR_D = $(subst /,\,$(MSVCDIR_MSVCDIR))
endif # ALLEGRO_USE_CYGWIN
But it would be really nice if we could pass a makefile variable there.
--
Milan Mimica
http://sparklet.sf.net