$ cat /tmp/a.sh #!/bin/sh foo () { echo .$0. echo .$1. }
foo a b c $ uname -a SunOS vegeta 5.7 ... $ /tmp/a.sh ./home/china/a.sh. .a. $ uname -a IRIX64 puar 6.5 $ /tmp/a.sh .foo. .a. $ ksh /tmp/a.sh ./home/china/a.sh. .a. >From sh(1) on IRIX: Note: As of IRIX 6.4, sh is the Korn shell rather than the Bourne shell. See bsh(1) for the Bourne Shell description. See the COMPATIBILITY ISSUES section below for more detail. ... COMPATIBILITY ISSUES To retain some backward compatibility to the Bourne shell, certain Korn shell features are controlled by how the shell is invoked and/or the current value of the environment variable _XPG. ... When the shell is invoked as "sh" and the current value of the _XPG environment variable is not equal to 1 (one), the special positional parameter $0, within a function call, is the name of the function. Otherwise, it is the name of the invoking shell script. So this means func_infer_tag() is broken in branch-1-5 because it does this: func_infer_tag () { if test -n "$available_tags" && test -z "$tagname"; then CC_quoted= ... # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) for z in $available_tags; do if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$0" > /dev/null; then So, should I modify the top of ltmain.in from: # The name of this program. progname=`$echo "$0" | ${SED} 's%^.*/%%'` modename="$progname" to: # The name of this program. progname=`$echo "$0" | ${SED} 's%^.*/%%'` full_path_progname="$0" modename="$progname" and then we can use $full_path_progname in func_infer_tag(). -- albert chin ([EMAIL PROTECTED]) _______________________________________________ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool