mike@yunexus.yorku.ca (Mike Marques) (05/31/89)
Greetings...
In the manual for make 3.48:
--------------------------------------------------------------------
When a dependency's name has the form `-lNAME', `make' handles it
specially by searching for the file `libNAME.a' in the directories
`/lib' and `/usr/lib', and then using matching `vpath' search paths
and the `VPATH' search path.
For example,
foo : foo.c -lcurses
cc $^ -o $@
would cause the command `cc foo.c -lcurses -o foo' to be executed
when `foo' is older than `foo.c' or than `libcurses.a' (which has
probably been found by directory search in the file
`/usr/lib/libcurses.a').
----------------------------------------------------------------------
This does not seem to work when using VPATH.
The following illustrates the problem:
yunexus% cat Makefile
VPATH=.
file: file.c -lmy
cc $^ -o $@
yunexus% ls
Makefile file file.o
Makefile~ file.c libmy.a
yunexus% make -v
GNU Make version 3.48, by Richard Stallman and Roland McGrath.
Copyright (C) 1988, 1989 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
make: *** No way to make target `-lmy'. Stop.
yunexus%
Thanks.
Mike
--
Mike Marques | Usenet: ......!utzoo!yunexus!mike
York University (Computing Services) | mike@nexus.yorku.ca
-------------------------------------| Bitnet: mike@libra.yorku.ca
Only visiting this planet... | Voice: (416) 736-5257