Re: getting the list of input files of a gcc command line

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

 



On Wed, Dec 5, 2018 at 11:44 AM Vincent Lefevre <vincent+gcc@xxxxxxxxxx> wrote:
>
> I would like to write a gcc wrapper and get the list of input files
> of the gcc command line before executing gcc. As a heuristic, I could
> get all the arguments with some extension like .c and .h, but is
> there a more reliable way?
>
> The goal is to get a warning if I try to execute gcc while some input
> file has not been saved in Emacs (Emacs provides the way to do this,
> e.g. by creating a symbolic link .#tst.c when tst.c has not been
> saved).
>
> --
> Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
> 100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
> Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

Perhaps you can do it the other way around: make a script/macro that
saves all open files, then runs gcc.

-- 
Sent from my Game Boy.




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux