Re: False positive "doesn't match the target pattern" error

2022-08-20 Thread Dmitry Goncharov
On Sat, Aug 20, 2022 at 8:28 PM Masahiro Yamada wrote: > build-dirs := . drivers sound net virt arch/x86/pci arch/x86/power lib > arch/x86/lib > subdir-modorder := $(addsuffix /.modules.order, $(build-dirs)) > $(sort $(subdir-modorder)): %/.modules.order: % Can you remove . from build-dirs and

[bug #62929] Normalize foo/./bar

2022-08-20 Thread Dmitry Goncharov
Additional Item Attachment, bug #62929 (project make): File name: sv62929_fix.diff Size:3 KB File name: sv62929_test.diff Size:1 KB

[bug #62929] Normalize foo/./bar

2022-08-20 Thread Dmitry Goncharov
Follow-up Comment #1, bug #62929 (project make): Make fails to normalize foo/./bar as foo/bar. The original bug report is here https://lists.gnu.org/archive/html/bug-make/2022-08/msg00064.html ___ Reply to this item at:

[bug #62929] Normalize foo/./bar

2022-08-20 Thread Dmitry Goncharov
URL: Summary: Normalize foo/./bar Project: make Submitter: dgoncharov Submitted: Sun 21 Aug 2022 03:38:36 AM UTC Severity: 3 - Normal Item Group: Bug

Re: False positive "doesn't match the target pattern" error

2022-08-20 Thread Masahiro Yamada
On Sun, Aug 21, 2022 at 12:48 AM Dmitry Goncharov wrote: > > On Sat, Aug 20, 2022 at 11:36 AM Alejandro Colomar > wrote: > > Why does make(1) need to special-case a leading ./ ? > > If your makefile has a rule like > foo.x: foo.z; cp $< $@ > then make foo.x and make ./foo.x both produce the

Re: False positive "doesn't match the target pattern" error

2022-08-20 Thread Masahiro Yamada
On Sun, Aug 21, 2022 at 12:32 AM Dmitry Goncharov wrote: > > On Sat, Aug 20, 2022 at 5:52 AM Masahiro Yamada wrote: > > I appreciate GNU Make normalize the path > > by removing "./" > > > > This is helpful in some cases, but I think it is a bad side-effect > > in this case. > > Is there a reason

Re: False positive "doesn't match the target pattern" error

2022-08-20 Thread Dmitry Goncharov
On Sat, Aug 20, 2022 at 11:36 AM Alejandro Colomar wrote: > Why does make(1) need to special-case a leading ./ ? If your makefile has a rule like foo.x: foo.z; cp $< $@ then make foo.x and make ./foo.x both produce the same file. regards, Dmitry

Re: False positive "doesn't match the target pattern" error

2022-08-20 Thread Alejandro Colomar
Hi Dmitry, On 8/20/22 17:32, Dmitry Goncharov wrote: On Sat, Aug 20, 2022 at 5:52 AM Masahiro Yamada wrote: I appreciate GNU Make normalize the path by removing "./" This is helpful in some cases, but I think it is a bad side-effect in this case. Is there a reason to treat './foo.x' as

Re: False positive "doesn't match the target pattern" error

2022-08-20 Thread Dmitry Goncharov
On Sat, Aug 20, 2022 at 5:52 AM Masahiro Yamada wrote: > I appreciate GNU Make normalize the path > by removing "./" > > This is helpful in some cases, but I think it is a bad side-effect > in this case. Is there a reason to treat './foo.x' as different from 'foo.x'? > If this is a bug, I can

False positive "doesn't match the target pattern" error

2022-08-20 Thread Masahiro Yamada
Hi. [Sample Makefile] ./foo.x: %/foo.x: %/foo.z cp $< $@ ./foo.z: touch $@ [Test result] $ make Makefile:2: target 'foo.x' doesn't match the target pattern cp foo.x cp: missing destination file operand after 'foo.x' Try 'cp --help' for more information. make: ***