[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Complex pattern rules broken in win32-make (MINGW).
From: |
Paul Smith |
Subject: |
Re: Complex pattern rules broken in win32-make (MINGW). |
Date: |
Mon, 01 Jan 2007 23:45:42 -0500 |
On Sun, 2006-12-31 at 06:28 +0200, Eli Zaretskii wrote:
> > This rule breaks down:
> >
> > obj\%.o: src\%.c
> >
> > This should however be handled correctly on windows... no ?
>
> It cannot be fixed easily, as the backslash is required to be able to
> use a literal percent character.
Eli is correct. The GNU make manual defines the sequence "\%" to be a
literal "%" (the backslash escapes the percent so it's not treated as a
pattern match character).
It's remotely possible that you can get what you want this way:
obj\\%.o: src\\%.c
since GNU make defines that a backslash can be used to escape a
backslash that would otherwise escape a percent; so the above should
resolve to what you want.
However, I can't say for sure this will work. In general it's best to
follow Eli's excellent advice and use "/" instead of "\" in your
makefiles, even on Windows.
--
-------------------------------------------------------------------------------
Paul D. Smith <address@hidden> Find some GNU make tips at:
http://www.gnu.org http://make.paulandlesley.org
"Please remain calm...I may be mad, but I am a professional." --Mad Scientist
- Re: Complex pattern rules broken in win32-make (MINGW).,
Paul Smith <=