How to use protoize ?
Jim Wilson
wilson@tuliptree.org
Sun Aug 10 10:25:00 GMT 2003
Kaveh R. Ghazi wrote:
> Would someone please help me with using protoize? (I want to be able
> to run it as a test if I happen to change it as part of maintenance
> patches.)
In c-aux-info, in gen_aux_info_record, there is a comment that states
that protoize only works for files in the current working directory, and
hence it always emits "." for the directory.
Protoize fails when it tries to convert a relative pathname for an
include file to a full pathname. It ends up using the directory holding
the source file instead of using the current working directory, and that
gives a full pathname that is nonsense.
See invocation_filename in protoize.c. c-aux-info emits ".", and
process_aux_info_file converts this into the source file name. Later
on, in referenced_file_is_newer, we call abspath with
invocation_filename, and hence header file names which are relative to
the objdir get treated as relative to the srcdir. It isn't clear to me
if this has ever worked the way you want it to.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com
More information about the Gcc
mailing list