This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: GCC headers and DJGPP port


DJ Delorie wrote:
> 
> > Suppose the GCC-supplied "stddef.h" were to do stuff like:
> > ...
> > and the DJGPP headers were to do the same?  :-)
> 
> If you can guarantee that gcc won't change it's mind *again* I suppose
> we could agree on something like this.

The fixincludes hackery that uses this mechanism dates from the
shell script I used as the basis for the new, improved fixincludes.
I won't be changing it.

> Unfortunately, DJGPP is a *dos* program, not a Win32 program.  That
> makes things even harder (but not impossible).  We have popen()
> and system(), but not fork().

Then it would seem possible that the "process()" fixincl routine
could be reworked for DOS such that the fork(2) calls get
replaced with system(3) calls, a la:

   sprintf( buf,
   "src=%s ; dest=%s ; fix=%s\n"
   "fixincfix $fix $src FIXINC.TMP\n"
   "mv -f FIXINC.TMP $dest", pz_src, pz_dest, pz_fix_name );
   system( buf );

(modified as required for the DOS environment).
I think the shell server could be disposed of with a little
effort.  It is not widely used inside of fixincl anymore.
Obviously, the "fixincfixer" program would have to be
resurrected.  That would not be too hard.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]