as the path to "perl" is hardcoded in
src/scripts/contrib/g.html2man/g.html2man
the command:
gmake5 html
fails on several platforms (like CRAY where it is in
/opt/gnu/bin/perl
Today I have added the missding
PERL = @PERL@
into src/CMD/head/head.in
Can we utilize this? Maybe similar to the wrapper
line used for tcltkgrass?
Markus
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
as the path to "perl" is hardcoded in
src/scripts/contrib/g.html2man/g.html2man
the command:
gmake5 html
fails on several platforms (like CRAY where it is in
/opt/gnu/bin/perl
Today I have added the missding
PERL = @PERL@
into src/CMD/head/head.in
Can we utilize this? Maybe similar to the wrapper
line used for tcltkgrass?
Yes, perl has a similar method. The following is from the "Programming
Perl" book:
#!/bin/sh -- #perl, to stop looping
eval 'exec /usr/bin/perl -S $0 ${1+"$@"}'
if 0;
.. rest of perl script ...
It's strange but it seems to work for me. In this case you simply
substitute maybe $GRASS_PERL for /usr/bin/perl.
--
Sincerely,
Jazzman (a.k.a. Justin Hickey) e-mail: jhickey@hpcc.nectec.or.th
High Performance Computing Center
National Electronics and Computer Technology Center (NECTEC)
Bangkok, Thailand
People who think they know everything are very irritating to those
of us who do. ---Anonymous
Jazz and Trek Rule!!!
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
On Thu, Mar 01, 2001 at 04:45:07PM +0700, Justin Hickey wrote:
Hi Markus
Markus Neteler wrote:
>
> Hi all,
>
> as the path to "perl" is hardcoded in
> src/scripts/contrib/g.html2man/g.html2man
>
> the command:
> gmake5 html
> fails on several platforms (like CRAY where it is in
> /opt/gnu/bin/perl
>
> Today I have added the missding
> PERL = @PERL@
> into src/CMD/head/head.in
>
> Can we utilize this? Maybe similar to the wrapper
> line used for tcltkgrass?
Yes, perl has a similar method. The following is from the "Programming
Perl" book:
#!/bin/sh -- #perl, to stop looping
eval 'exec /usr/bin/perl -S $0 ${1+"$@"}'
if 0;
.. rest of perl script ...
It's strange but it seems to work for me. In this case you simply
substitute maybe $GRASS_PERL for /usr/bin/perl.
s@/usr/bin/perl@perl@ in the above "eval 'exec ...'", then it shouldn't
matter where perl lives as long as it's in $PATH. Some other techniques
are in "man perlrun". One other, which may not always exist:
#! /usr/bin/env perl
--
Eric G. Miller <egm2@jps.net>
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
> Yes, perl has a similar method. The following is from the
> "Programming Perl" book:
>
> #!/bin/sh -- #perl, to stop looping
> eval 'exec /usr/bin/perl -S $0 ${1+"$@"}'
> if 0;
>
> .. rest of perl script ...
>
> It's strange but it seems to work for me. In this case you simply
> substitute maybe $GRASS_PERL for /usr/bin/perl.
Looks funny! However, the "--" is not supported here:
g.html2man
sh: -- #perl, to stop looping: unrecognized option
Usage: sh [GNU long option] [option] ...
sh [GNU long option] [option] script-file ...
This is strange. -- is definitely a valid option for sh on Linux. You
can try it on the command line. In fact, I could not use *any* option
after #! /bin/sh, strange. So, I checked the perl newsgroup archive and
there was a post similar to this and the reply was that it was probably
a bug in the GNU sh. However, I found a workaround. Simply call
g.html2man with sh. That is:
sh g.html2man.
This should work, at least my test cases worked here on both Linux and
SGI.
And also not the -S:
export GRASS_PERL=/usr/bin/perl
g.html2man
/bin/sh: -S: unrecognized option
Shall I simply remove these flags?
The -S option is an option to perl, not sh, so please do not remove it.
--
Sincerely,
Jazzman (a.k.a. Justin Hickey) e-mail: jhickey@hpcc.nectec.or.th
High Performance Computing Center
National Electronics and Computer Technology Center (NECTEC)
Bangkok, Thailand
People who think they know everything are very irritating to those
of us who do. ---Anonymous
Jazz and Trek Rule!!!
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
On Fri, Mar 02, 2001 at 11:12:55AM +0700, Justin Hickey wrote:
Hi Markus
Markus Neteler wrote:
> > Yes, perl has a similar method. The following is from the
> > "Programming Perl" book:
> >
> > #!/bin/sh -- #perl, to stop looping
> > eval 'exec /usr/bin/perl -S $0 ${1+"$@"}'
> > if 0;
> >
> > .. rest of perl script ...
> >
Simply call
g.html2man with sh. That is:
sh g.html2man.
This should work, at least my test cases worked here on both Linux and
SGI.
Yes, now it's o.k.
> And also not the -S:
>
> export GRASS_PERL=/usr/bin/perl
> g.html2man
> /bin/sh: -S: unrecognized option
> Shall I simply remove these flags?
The -S option is an option to perl, not sh, so please do not remove it.
Accepted now
Final question: How can we set
GRASS_PERL (from src/CMD/head/head.$ARCH)? I just get no idea,
Yours
Markus
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
On Fri, Mar 02, 2001 at 11:12:55AM +0700, Justin Hickey wrote:
Final question: How can we set
GRASS_PERL (from src/CMD/head/head.$ARCH)? I just get no idea,
We can handle it just like we do GISBASE in src/general/grass.src. That
is, we put something like
GRASS_PERL=PERL_COMMAND
in grass.src and then add the appropriate substitution to the sed
command in the Gmakefile. Do you want me to make the change, or wait on
it?
--
Sincerely,
Jazzman (a.k.a. Justin Hickey) e-mail: jhickey@hpcc.nectec.or.th
High Performance Computing Center
National Electronics and Computer Technology Center (NECTEC)
Bangkok, Thailand
People who think they know everything are very irritating to those
of us who do. ---Anonymous
Jazz and Trek Rule!!!
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
On Fri, Mar 02, 2001 at 05:14:30PM +0700, Justin Hickey wrote:
Hi Markus
Markus Neteler wrote:
>
> On Fri, Mar 02, 2001 at 11:12:55AM +0700, Justin Hickey wrote:
> Final question: How can we set
> GRASS_PERL (from src/CMD/head/head.$ARCH)? I just get no idea,
We can handle it just like we do GISBASE in src/general/grass.src. That
is, we put something like
GRASS_PERL=PERL_COMMAND
in grass.src and then add the appropriate substitution to the sed
command in the Gmakefile. Do you want me to make the change, or wait on
it?
Justin,
please go ahead...
Thanks
Markus
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
> That is, we put something like
>
> GRASS_PERL=PERL_COMMAND
>
> in grass.src and then add the appropriate substitution to the sed
> command in the Gmakefile. Do you want me to make the change, or
> wait on it?
Justin,
please go ahead...
Done and it seems to substitute fine for me.
--
Sincerely,
Jazzman (a.k.a. Justin Hickey) e-mail: jhickey@hpcc.nectec.or.th
High Performance Computing Center
National Electronics and Computer Technology Center (NECTEC)
Bangkok, Thailand
People who think they know everything are very irritating to those
of us who do. ---Anonymous
Jazz and Trek Rule!!!
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
On Fri, Mar 02, 2001 at 06:14:54PM +0700, Justin Hickey wrote:
Markus Neteler wrote:
> > That is, we put something like
> >
> > GRASS_PERL=PERL_COMMAND
> >
> > in grass.src and then add the appropriate substitution to the sed
> > command in the Gmakefile. Do you want me to make the change, or
> > wait on it?
> Justin,
>
> please go ahead...
Done and it seems to substitute fine for me.
I have updated html/Gmakefile and
src/scripts/contrib/g.html2man/g.html2man
but it seems that GRASS_PERL is not sent to g.html2man. Do I have
to add it as parameter in above html/Gmakefile?
Markus
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
On Fri, Mar 02, 2001 at 05:14:30PM +0700, Justin Hickey wrote:
Hi Markus
Markus Neteler wrote:
>
> On Fri, Mar 02, 2001 at 11:12:55AM +0700, Justin Hickey wrote:
> Final question: How can we set
> GRASS_PERL (from src/CMD/head/head.$ARCH)? I just get no idea,
We can handle it just like we do GISBASE in src/general/grass.src. That
is, we put something like
GRASS_PERL=PERL_COMMAND
in grass.src and then add the appropriate substitution to the sed
command in the Gmakefile. Do you want me to make the change, or wait on
it?
unfortunately I don't get g.html2man working properly. It seems not
to recognize the parameters given in html/Gmakefile
If anyone could look into this...
Thanks!
Markus
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
unfortunately I don't get g.html2man working properly. It seems not
to recognize the parameters given in html/Gmakefile
If anyone could look into this...
Fixed. The environment variable is defined in make.mid, but it was not
being passed to the html2man script. Please let me know of any other
problems.
--
Sincerely,
Jazzman (a.k.a. Justin Hickey) e-mail: jhickey@hpcc.nectec.or.th
High Performance Computing Center
National Electronics and Computer Technology Center (NECTEC)
Bangkok, Thailand
People who think they know everything are very irritating to those
of us who do. ---Anonymous
Jazz and Trek Rule!!!
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'
On Mon, Mar 05, 2001 at 12:13:00PM +0700, Justin Hickey wrote:
Hi Markus
Markus Neteler wrote:
> unfortunately I don't get g.html2man working properly. It seems not
> to recognize the parameters given in html/Gmakefile
> If anyone could look into this...
Fixed. The environment variable is defined in make.mid, but it was not
being passed to the html2man script. Please let me know of any other
problems.
Great, works perfectly now!
Thanks, Justin,
Markus
----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'