Assignment 13Due Nov 19, on line
Part of
the homework for CS:2820, Fall 2020
|
a: b c d e
In this file:
a) files b and c must exist for the makefile to be valid.
b) target a depends on files b and c.
c) d e must be the shell command to create file a.
d) target a must be a file name.
e) e is the name of a file passed to shell command d.
Road.class: Road.java Intersection.class javac Road.java Intersection.class: Intersection.java Road.class javac Intersection.java
Make has a special case to detect and deal with circular dependencies like
the above. What would happen here if it did not have this special case?
a) Nothing, because the Java compiler deals with this issue for make.
b) It might miss the commands to build some required make target.
c) It could go into an infinite loop.
d) Nothing, because it just runs the shell commands in the order listed.
e) It might fail to notice some of the make dependencies.
(Note: In the above question, you will probably need to develop a hypothesis about what data structures make builds and how it uses them to process the makefile.)
Write a makefile for the Epidemic simulator. This makefile shoud do a careful jog of documenting all of the interfile dependencies in the project and it should be nicely written. It should work with either the solution to MP9 or MP10 (while these have different simulation frameworks, the interfile dependencies and the names of the source files are the same).
Note that you will be completely responsible for issues of style, and that your code will be checked by running it to actually build and test the simulator.
You should include support for:
Submit your code for the file Makefile.
A student asked: What kind of file type should the makefile have?
On Unix/Linux systems, the makefile is typically named Makefile with no dot or other suffix. Unix/Linux systems do not require that files have some kind of type. Mandatory file types are a foible of Microsoft systems.