[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Cluster-devel] [RFC] cleaning up inconsistent usage of perl, python and sh/bash



Hi guys,

usual round of clean up.. we are way too inconsistent in the way in which we
invoke perl, python, sh and bash

For example: perl vs perl -w, /bin/sh vs /bin/bash and so on.

I would like to address it by:

- make all paths to perl configurable. There is no guarantee that the user wants
to use the default perl installation. Default to /usr/bin/perl.

- switch all perl scripts to use -w when building in debug mode as it did
uncover bugs before and it will enforce a round of tests on all perl scripts.
Default: no -w for release build (to switch permanently on once we can give all
the scripts a test run).

- (optional) make sure all perl scripts use strict;

- make all paths to python configurable. There is no guarantee that the user
wants to use the default python installation nor the default version.

- make all paths to the default shell configurable. We can only rely that
/bin/sh exists, but there is no guarantee that it is bash. I assume that most
scripts requires bash so we want to make the path to bash configurable as we
don't know if the user wants the default instance of bash in the system.

- switch all bash invocations to use -e by default.

- (optional) switch all bash invocation to use -x when using --debug_shell
configuration option.

As a consequence we can:

- simplify def2var script to do the right thing by parsing the first line of the
 TARGET
- simplify make/fence*.mk into one invocation.

Please let me know what you think and I will start to work on this.

Cheers
Fabio

-- 
I'm going to make him an offer he can't refuse.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]