• Compiling

    What is compiling?

    • compiling is what happens when you run the gcc command
    • there is a little more infor about compiling in Lecture 02
  • Make

    Why use Make?

    • with the way we've been using gcc, we have been compiling every file each time you run gcc; that can take a lot of time if you have a large program
    • make allows you the flexibility to only compile the parts of the program that has changed
    • make allows you to automatically repeat certain tasks, such as:
      • move files around before compiling
      • remove unnecessary files (i.e. clean up files)
    • make still uses a compiler underneath, such as gcc
    • if you are distributing software that requires certain tasks to be done, you can put those tasks in the makefile and your end users will not have to worry about those details; they can just run make

    What is Make?

    How to use Make?

    • by issuing the make command in a folder that has a makefile
    • you can also pick and run only specific rules defined in the makefile, such as make clean