[Top][All Lists]

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

$whole_archive_flag_spec and AIX

From: libtool
Subject: $whole_archive_flag_spec and AIX
Date: Thu, 10 May 2001 10:08:41 -0500
User-agent: Mutt/1.1.12i

I think the proper way to get $whole_archive_flag_spec set for AIX is
to use the -bnogc option or one of its equivalents. The
whole_archive_flag_spec variable is set for Solaris as follows (1.4):
  whole_archive_flag_spec='-z allextract$convenience -z defaultextract'

Looking at ld(1) for AIX, I cannot find an equivalent command. We have:
  -bnogc        Turn off garbage collection for all objects
                being linked in
  -bgcbypass:#  Turn off garbage collection for # many files
                following this option
  -bkeepfile:F  Turn off garbage collection for file `F'

I tried -bnogc and -bgc to determine if object files inbetween them
would not have garbage collection activated but these flags apply to
all objects on the command line. I think I could set
whole_archive_flag_spec in such a way as to split $convenience into
space-separated filenames and pass that through wc to get the number
of object files allowing us to use -bgcbypass. Two solutions using
this method:

  whole_archive_flag_spec='-bgcbypass:`echo $convenience |
  tr ' ' '\012' | wc -l` $convenience'

  whole_archive_flag_spec='-bgcbypass:`set -- \`echo $convenience\`;
  echo $#` $convenience'

Look like an acceptable solution? The only problem with this is if
files in $convenience have spaces in the filename. But the Solaris
solution above has the same problem.

albert chin (address@hidden)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]