On Apr 4, 2007, at 8:44 AM, Marcin Dulak wrote:

Thank your for comments.
1) I'am using
GNU bash, version 3.00.15(1)-release (i686-redhat-linux-gnu)
To see the problem with the original
eval "set %{configure_options}" I start the configure_options with -- in buildrpm.sh, like this: configure_options="--with-tm=/usr/ local FC=pgf90 F77=pgf90 CC=pgcc CXX=pgCC CFLAGS=-Msignextend CXXFLAGS=-Msignextend --with-wrapper-cflags=-Msignextend --with- wrapper-cxxflags=-Msignextend FFLAGS=-Msignextend FCFLAGS=- Msignextend --with-wrapper-fflags=-Msignextend --with-wrapper- fcflags=-Msignextend" Or to see the problem directly, I go to the shell: sh; set --w sh: set: --: invalid option set: usage: set [-- abefhkmnptuvxBCHP] [-o option] [arg ...]

(wow, my mail client really munged your formatting... :-\ )

I see why I didn't run into this before. I did all my testing within the context of the OFED 1.2 installer, and we always pass in configure_options that start with a token that does not start with --. Hence, "set" knew to ignore the -- prefixed options.

So it looks like a slightly less intrusive fix would actually be to use the following:

   eval "set -- %{configure_options}"

2) if ("\$LD_LIBRARY_PATH" !~ *%{_libdir}*) then is the only possibility which works for me. I'am using tcsh 6.13.00 (Astron) 2004-05-19 (i386-intel-linux) options 8b,nls,dl,al,kan,rh,color,dspm,filec If I use "%{_libdir}", then every time I source /opt/openmpi/1.2/bin/mpivars-1.2.csh a new entry of opemnpi is prepended, so the LD_LIBRARY_PATH is growing. The same if I use "*%{_libdir}*" it seems that with the double quotes the shell despite the pattern comparison requested by !~ uses literal matching.

I just went and read the man page on this (should have done this before): it says that the =~ and !~ operators are glob-style matching. So the * prefix and suffix is correct -- thanks for pointing that out.

I was trying to use "" to protect multi-word strings, but I can't seem to find a syntax that works for multi-word strings on the right hand side. Oh well; there's probably other stuff in OMPI that will break if use you spaces in the prefix -- I'm ok with this for now.

I'll fix up these in SVN.

3) using setenv MANPATH %{_mandir}: (with the colon (:) included), if I start from empty MANPATH

unsetenv MANPATH

and run
source /opt/openmpi/1.2/bin/mpivars-1.2.csh
I get
echo $MANPATH

/opt/openmpi/1.2/man:

Right.

I tried to google for something like
also include the default MANPATHbut I cannot find anything. What is the meaning of this colon at the end?

I believe that I found this option long ago by trial and error in the OSCAR project. I just trolled through the man documentation right now and [still] can't find it documented anywhere. :-\

The trailing : means "put all the options listed in man.conf here". If you don't do that, then the contents of MANPATH wholly replaces what is listed in man.conf. For example (I'm a C shell kind of guy):

# With no $MANPATH
shell% man ls
...get ls man page...

# Set MANPATH to a directory with no trailing :
shell% setenv MANPATH /opt/intel/9.1/man
shell% man icc
...get icc man page...
shell% man ls
No manual entry for ls

# Set MANPATH to a directory with a trailing :
shell% setenv MANPATH /opt/intel/9.1/man:
shell% man icc
...get icc man page...
shell% man ls
...get ls man page...

Thanks for the bug reports and your persistence!

--
Jeff Squyres
Cisco Systems

Reply via email to