This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
RE: command line options
- From: "Rupert Wood" <me at rupey dot net>
- To: "'abdul'" <abdul at cmcltd dot com>
- Cc: <gcc-help at gcc dot gnu dot org>
- Date: Sun, 20 Jul 2003 13:28:49 +0100
- Subject: RE: command line options
Abdul wrote:
> How to put all the command line options in a file, so that I need
> not type it every time?
Depending on which system you're using, you could write a shell script or
batch file to perform the compile. (I saw a discussion about adding
'@inputfile' to read the contents of inputfile as command line arguments
c.f. DJGPP but I haven't seen that implemented yet.)
However, probably the best thing to do is to write a makefile. See 'info
make' or 'man make' on your system. You tell make which source files are
used in your project, how to compile them (CFLAGS) and how to link them and
then run make; it will recompile only the source files that have changed,
etc. It's very useful for large projects.
Rup.