[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Changes in mkdir definition cause problems
- Date: Mon, 12 Jul 1999 08:52:01 -0500 (CDT)
- From: joel at OARcorp.com (joel at OARcorp.com)
- Subject: Changes in mkdir definition cause problems
On Mon, 12 Jul 1999, Ralf Corsepius wrote:
> VALETTE Eric wrote:
>
> > >>>>> "Ralf" == Ralf Corsepius <corsepiu at faw.uni-ulm.de> writes:
> >
> > Ralf> VALETTE Eric wrote:
> > >> Previously MKDIR was defined as "/bin/mkdir -p"
> > >> now MKDIR is defined as "/bin/mkdir"
> > >>
> > >> Causing every Makefile that contains $(MKDIR) to fail.
> >
> > Ralf> AFAIS, only the mcp750 BSP is affected :-.
> >
> > >>
> > >> What is the rationale for the change and what is the correct
> > >> way to make it?
> > >>
> >
> > Ralf> The rationale behind is further adaptation to automake standards:
> > Ralf> automake uses mkinstalldirs for "recursive mkdir" and "mkdir" for
> > Ralf> "non-recursive mkdir", because mkdir -p and mkdir -m XXX are not
> > Ralf> portable. Therefore the checks for mkdir -p, which we had in
> > Ralf> configure.in and aclocal/mkdir.m4 until recently, now have been deleted
> > Ralf> and places where $(MKDIR) had been used before, have been replaced with
> > Ralf> either mkinstalldirs or mkdir.
> >
> > If you use mkdir, then the second compilation will fail because the directory
> > exists which is a pain...
> >
>
> In this case, either use
> test -d $(dir) || mkdir $(dir)
> or use
> $(SHELL) $(RTEMS_ROOT)/mkinstalldirs $(dirs)
I would also add that I would only put the "make directory" operation in
one Makefile.in.
--joel