Hi,

after make clean, make failed with message:

make[2]: Entering directory /home/postgres/cvs/pgsql/src/backend'
prereqdir=`cd parser/ && pwd` && \
  cd ../../src/include/parser/ && rm -f parse.h && \
  ln -s $prereqdir/parse.h .
ln: ./parser: File exists
make[2]: *** [../../src/include/parser/parse.h] Error 1


	Regards,
		Oleg
_____________________________________________________________
Oleg Bartunov, sci.researcher, hostmaster of AstroNet,
Sternberg Astronomical Institute, Moscow University (Russia)
Internet: oleg@sai.msu.su, http://www.sai.msu.su/~megera/
phone: +007(095)939-16-83, +007(095)939-23-83


Tue, 6 Feb 2001 14:49:42 +0300 (GMT)
Oleg Bartunov <oleg@sai.msu.su>
little bug in current CVS
Oleg Bartunov <oleg@sai.msu.su> writes:
> make[2]: Entering directory /home/postgres/cvs/pgsql/src/backend'
> prereqdir=`cd parser/ && pwd` && \
>   cd ../../src/include/parser/ && rm -f parse.h && \
>   ln -s $prereqdir/parse.h .
> ln: ./parser: File exists
> make[2]: *** [../../src/include/parser/parse.h] Error 1

Hm.  I bet your shell is failing to strip whitespace from the output of
pwd, so that the ln command ends up looking like

	ln -s /home/postgres/cvs/pgsql/src/backend/parser /parse.h .

Can you check that theory by inserting an 'echo'?

			regards, tom lane

Tue, 06 Feb 2001 10:54:51 -0500
Tom Lane <tgl@sss.pgh.pa.us>
Re: little bug in current CVS 
On Tue, 6 Feb 2001, Tom Lane wrote:

> Oleg Bartunov <oleg@sai.msu.su> writes:
> > make[2]: Entering directory /home/postgres/cvs/pgsql/src/backend'
> > prereqdir=`cd parser/ && pwd` && \
> >   cd ../../src/include/parser/ && rm -f parse.h && \
> >   ln -s $prereqdir/parse.h .
> > ln: ./parser: File exists
> > make[2]: *** [../../src/include/parser/parse.h] Error 1
>
> Hm.  I bet your shell is failing to strip whitespace from the output of
> pwd, so that the ln command ends up looking like
>
> 	ln -s /home/postgres/cvs/pgsql/src/backend/parser /parse.h .
>
> Can you check that theory by inserting an 'echo'?

you're right. shell is BASH_VERSION='2.04.0(1)-release'
Makefile looks too complex:
$(top_builddir)/src/include/parser/parse.h: $(srcdir)/parser/parse.h
        prereqdir=`cd $(dir $<) && pwd` && \
          cd $(dir $@) && rm -f $(notdir $@) && \
          $(LN_S) $$prereqdir/$(notdir $<) .

We're already in src/backend directory, why not use
 ln -sf parser/parse.h .



>
> 			regards, tom lane
>

	Regards,
		Oleg
_____________________________________________________________
Oleg Bartunov, sci.researcher, hostmaster of AstroNet,
Sternberg Astronomical Institute, Moscow University (Russia)
Internet: oleg@sai.msu.su, http://www.sai.msu.su/~megera/
phone: +007(095)939-16-83, +007(095)939-23-83


Tue, 6 Feb 2001 20:16:26 +0300 (GMT)
Oleg Bartunov <oleg@sai.msu.su>
Re: little bug in current CVS 
Oleg Bartunov writes:

> after make clean, make failed with message:
>
> make[2]: Entering directory /home/postgres/cvs/pgsql/src/backend'
> prereqdir=`cd parser/ && pwd` && \
>   cd ../../src/include/parser/ && rm -f parse.h && \
>   ln -s $prereqdir/parse.h .
> ln: ./parser: File exists
> make[2]: *** [../../src/include/parser/parse.h] Error 1

Try changing the second line to this

prereqdir=`CDPATH=: ; cd parser/ && pwd` && \


-- 
Peter Eisentraut      peter_e@gmx.net       http://yi.org/peter-e/


Tue, 6 Feb 2001 18:27:18 +0100 (CET)
Peter Eisentraut <peter_e@gmx.net>
Re: little bug in current CVS