This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/35458] Dependency generation (-M) does not quote '#' in filenames
- From: "markus dot milleder at generali dot at" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 4 Mar 2008 14:10:00 -0000
- Subject: [Bug preprocessor/35458] Dependency generation (-M) does not quote '#' in filenames
- References: <bug-35458-15857@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #3 from markus dot milleder at generali dot at 2008-03-04 14:10 -------
(In reply to comment #2)
> Please note that quoting # in makefiles is not portable, but only supported
> by some make implementations. For example, with
> foo: a\#b
> bar: c#d
>
> AIX make will assume 'foo' depends on 'a\', and 'bar' on 'c'.
> Likewise HP-UX make. Consequently, both of these make's will error out on
> either line of:
> a#b:
> a\#b:
>
So it seems to me the patch is an improvement for make versions that understand
quoting and does not worsen the situation for those that do not, i.e. files
containing # are broken on e.g. AIX without the patch and with it.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35458