Skip to content

ldAIX4 does not generate Rlapack.exp (PR#2893)

2 messages · rgrubbfink@cox.net, Kurt Hornik

#
Full_Name: Richard L. Grubb
Version: 1.7.0
OS: AIX 4.3.3
Submission from: (NULL) (130.76.96.17)


src/modules/lapack/Makefile executes the tools/ldAIX4 script and supplies,
as arguments to ldAIX4, several object file names with filename extensions of
.lo.
The ldAIX4 script did not generate the file etc/Rlapack.exp until I changed
ldAIX4
as follows:

Original context:
# Check for object or archive files
ofiles=""
for arg; do
    case $arg in *.o) ofiles="$ofiles $arg";; esac
    case $arg in *.a) ofiles="$ofiles $arg";; esac
done

Changed context:
# Check for object or archive files
ofiles=""
for arg; do
    case $arg in *.o) ofiles="$ofiles $arg";; esac
    case $arg in *.lo) ofiles="$ofiles $arg";; esac
    case $arg in *.a) ofiles="$ofiles $arg";; esac
done

See also Bug reports 2887 and 2888
3 days later
#
Thanks for spotting this.  Will change to

  case $arg in *.o | *.lo | *.a)

Re the two other bug reports.  If I recall correctly, the current
version of ldAIX4 was provided by Tom Vogels a long time ago.  Not sure
if R Core members currently still have access to an AIX4 system ...

I see that Tcl/Tk has a script called ldAix which I think does something
similar and hard-wires nm to /usr/ccs/bin/nm, and that libtool has

    # If we're using GNU nm, then we don't want the "-C" option.
    # -C means demangle to AIX nm, but means don't demangle with GNU nm
    if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
    else
      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
    fi

As the libtool configure code is run anyway, I'd prefer making the $NM
configure value available and testing its value for being GNU nm or not,
if possible.  But see above: do you have a fix to the current version of
ldAIX4 that works with GNU nm?

-k