Phil Edwards <[EMAIL PROTECTED]> writes:

> Been playing with 1.5 and have been pretty pleased with the support for
> source files in subdirectories.  I have noticed however something which
> strikes me as odd:
>
>    % make
>    make  all-am
>    make[1]: Entering directory `/tmp/pme/foo'
>    source='/home/pme/easysems/main.cc' object='main.o' libtool=no \
>    depfile='.deps/main.Po' tmpdepfile='.deps/main.TPo' \
>    depmode=gcc3 /bin/sh /home/pme/easysems/depcomp \
> *  g++ -DHAVE_CONFIG_H -I. -I/home/pme/easysems -I. -g -O2 -c -o
> *    main.o `test -f /home/pme/easysems/main.cc ||
> *    echo '/home/pme/easysems/'`/home/pme/easysems/main.cc
>    g++  -g -O2   -o semmanip  getopt.o getopt1.o semmanip_opts.o main.o
>    make[1]: Leaving directory `/tmp/pme/foo'
>    %
>
> The call to the compiler, broken across three lines here and marked with
> '*', uses a shell expansion which doesn't make any sense.  Something is
> visibly wrong here, but I don't know what.  Everything works, but it
> looks like it's trying to test for a failure condition and... I dunno,
> do something strang in that condition.

That code is there support non-srcdir builds in the face of 'make's
with broken VPATH implementations.  If you look at the Makefile,
you'll see that it is checking to see whether 'make' said that the
source file was in $(srcdir), and if not, the 'echo' supplies the
$(srcdir).

- Hari
-- 
Raja R Harinath ------------------------------ [EMAIL PROTECTED]
"When all else fails, read the instructions."      -- Cahn's Axiom
"Our policy is, when in doubt, do the right thing."   -- Roy L Ash

Reply via email to