Doc Id: 017218 Product: VCS
Last Modified: 04/07/2006 Print-Friendly Version Email Article
My Saved Articles
Rate this article: Not Useful Somewhat Useful Useful Very Useful
Argument list too long
Question:
I get the following message during linking:
make: execvp: gcc: Argument list too long
make: *** [product_timestamp] Error 127
Answer:
By default VCS compiles module definitions into individual object files
and sends all the object files in a command line to the linker. Some
platforms use a fixed-length buffer for the command line, and if VCS sends
too long a list of object files, this buffer overflows and the link fails.
A solution to this problem is to have the linker create temporary object
files containing more than one module definition so there are fewer object
files on the linker command line. You enable creating these temporary object
files, and specify how many module definitions are in these files, with the
following option
-Marchive=N
where N is the number of modules definitions to include in one temporary
object file.
i.e.
% vcs -f filelist.f -Marchive=100 ...
Using this option briefly doubles the amount of disk space used by the linker
because the object files containing more than one module definition are
copies of the object files for each module definition. After the linker
creates the simv executable it deletes the temporary object files.