Hi,

I believe the parallel archive example from the documentation is outdated
as it does not work on 3.8.2 nor 4.4.

Given the recipe:

```
(%) : % ;
%.a : ; $(AR) $(ARFLAGS) $@ $?

ztest.a: ztest.a(aa.o bb.o)
```

Run:

```
...$ /bin/ls
aa.o  bb.o  makefile
...$ make
ar rv ztest.a aa.o bb.o
ar: creating ztest.a
a - aa.o
a - bb.o
...$ touch *.o
...$ make
make: `ztest.a' is up to date.
```


And finally, debug (elided):

```
Updating goal targets....
Considering target file 'ztest.a'.
 Looking for an implicit rule for 'ztest.a'.
 Trying pattern rule '%.a:' with stem 'ztest'.
 Found implicit rule '%.a:' for 'ztest.a'.
  Considering target file 'ztest.a(aa.o)'.
   Looking for an implicit rule for 'ztest.a(aa.o)'.
   Trying harder.
   No implicit rule found for 'ztest.a(aa.o)'.
   Looking for archive-member implicit rule for 'ztest.a(aa.o)'.
   Trying pattern rule '(%): %' with stem 'aa.o'.
   Trying implicit prerequisite 'aa.o'.
   Found 'aa.o'.
   Found implicit rule '(%): %' for '(aa.o)'.
    Considering target file 'aa.o'.
     Looking for an implicit rule for 'aa.o'.
     Trying harder.
     No implicit rule found for 'aa.o'.
     Finished prerequisites of target file 'aa.o'.
    No need to remake target 'aa.o'.
   Finished prerequisites of target file 'ztest.a(aa.o)'.
   Prerequisite 'aa.o' is newer than target 'ztest.a(aa.o)'.
  Must remake target 'ztest.a(aa.o)'.
  Successfully remade target file 'ztest.a(aa.o)'.
  Considering target file 'ztest.a(bb.o)'.
   Looking for an implicit rule for 'ztest.a(bb.o)'.
   Trying harder.
   No implicit rule found for 'ztest.a(bb.o)'.
   Looking for archive-member implicit rule for 'ztest.a(bb.o)'.
   Trying pattern rule '(%): %' with stem 'bb.o'.
   Trying implicit prerequisite 'bb.o'.
   Found 'bb.o'.
   Found implicit rule '(%): %' for '(bb.o)'.
    Considering target file 'bb.o'.
     Looking for an implicit rule for 'bb.o'.
     Trying harder.
     No implicit rule found for 'bb.o'.
     Finished prerequisites of target file 'bb.o'.
    No need to remake target 'bb.o'.
   Finished prerequisites of target file 'ztest.a(bb.o)'.
   Prerequisite 'bb.o' is newer than target 'ztest.a(bb.o)'.
  Must remake target 'ztest.a(bb.o)'.
  Successfully remade target file 'ztest.a(bb.o)'.
 Finished prerequisites of target file 'ztest.a'.
 Prerequisite 'ztest.a(aa.o)' is older than target 'ztest.a'.
 Prerequisite 'ztest.a(bb.o)' is older than target 'ztest.a'.
No need to remake target 'ztest.a'.
make: 'ztest.a' is up to date.
```

Perhaps the documentation meant to say:

```
%.a:
$(AR) $(ARFLAGS) $@ $?

ztest.a: aa.o bb.o
```


Regards,

Reply via email to