On 13 Oct 2010, at 08:18, Bruce Korb wrote:
> Hi Gary,

Howdy Bruce!

> On 10/12/10 09:08, Gary V. Vaughan wrote:
> 
>> +++ b/libposix/bootstrap
>> @@ -0,0 +1,55 @@
>> +#! /bin/sh
>> +
>> +PATH=..:$PATH
>> +
>> +gnulib-tool --import --lib=libposix --makefile-name=gnulib.mk \
>> +  --macro-prefix=LIBPOSIX --libtool --no-changelog --symlink \
>> +  --with-tests --with-c++-tests --with-longrunning-tests \
>> +  libposix
> 
> The construction of the libposix project needs to happen inside
> of a build directory.  It makes the process much cleaner.
> I will rework this script to do that, please.  Thank you.

Why bother copying the template files into another tree before
running the bootstrap script?  Once bootstrapped you can run
a VPATH configure and build, which should rebootstrap itself
after pulling updates from the upstream repo too.  It just seems
like an extra unnecessary step to enforce... if you want to
bootstrap outside the source tree (and don't mind that git-
version-gen won't work in that case) you can always copy the
template files elsewhere and run bootstrap in the copy... but
why?

I guess that directory checking might be worthwhile:

  test ! -f ../gnulib-tool || test ! -f ../posix-modules || {
    echo >&2 "bootstrap only works in the source directory"
    exit 1
  }

  PATH=..:$PATH

  ...

Maybe I'm misunderstanding you?

>> +mv tests/gnulib.mk tests/Makefile.am
>> +
>> +# sanity check the module list for synchronisation issues.
>> +echo "posix-modules :
>> +`posix-modules`
>> +libposix :
>> +`gnulib-tool --extract-dependencies libposix`" |awk '
> 
>>  - A 36-lines awk script inside a Makefile? Isn't it more maintainable to
>>    put it in a separate file?
> 
> I don't mind that so much, as long as the quoting is clean.
> In this case, the script does not require any apostrophes,
> so it isn't too bad.  I do find it easier to read when dropped
> into a variable and then used as in:
> 
>   ... | awk "$awkcmd"
> 
> It disentangles the awk commands from the shell commands.

Sure, no problem.

The awk script was just an after thought to stop the libposix module from
going out of sync with `posix-modules`.

Cheers,
-- 
Gary V. Vaughan (g...@gnu.org)

Attachment: PGP.sig
Description: This is a digitally signed message part

Reply via email to