Make files

next - skip - up - start

I have included make files for a number of compilers. These provide an alternative way of compiling your programs than with the IDE that comes with PC compilers. See the files section for details. See the example for how to use them. Leave out the target name to compile and link all my examples and test files.

PC

I include make files for most of the various PC compilers I have access to. They all use the make utility that comes with the compiler. I don't know whether they work with versions of the compilers other than the ones I have. The make files for Borland need editing to show where you have stored your Borland compiler.

Unix

The make files for the Unix compilers link a .cxx file to each .cpp file since some of these compilers do not recognise .cpp as a legitimate extension for a C++ file. I suggest you delete this part of the make file and, if necessary, rename the .cpp files to something your compiler recognises.

My make files for Unix systems are for use with gmake rather than make. Ordinary make works with them on the Sun but not the Silicon Graphics or HP machines. On Linux use make.

To compile everything with the CC compiler use

   gmake -f cc.mak
or for the gnu compiler use
   gmake -f gnu.mak
I have set O2 optimisation for CC but not for gnu, since I couldn't get it to compile with O2 set. You may need to change these options.

There is a line in the make file rm -f -i $*.cxx. Some systems won't accept this line and you will need to delete it. In this case, if you have a bad compile and you are using my scheme for linking .cxx files, you will need to delete the .cxx file link generated by that compile before you can do the next one. You may get away with just deleting the option -i in which case you you won't be asked before a .cxx file is deleted.

next - skip - up - start