nestakp.blogg.se

Generating a makefile for c program linux
Generating a makefile for c program linux





generating a makefile for c program linux

It is the responsibility of the configure script to take the Makfile.in and produce a customized Makefile specific to the system. They applied the fundamental theorem of Software Engineering and introduced the extra level of indirection – Makefile.in Programmers being programmers wanted these customizations to be done automatically. The Makefile had to be customized specific to the system. Programmers wanted to compile the same source across these diverse systems but the Makefile was a constraint. Enter ConfigureĪs times went by systems started to get diverse. The system worked flawlessly because it was built by programmers to be used by programmers. Failure mostly meant fixing compilation errors which programmers were adept at anyway. Success meant the program or library was immediately available for use. Given the source and the Makefile, programmer instinctively opened a terminal and wrote: Hence it was easy for programmers to create a Makefile, define the standard targets and expect Make to take care of the rest. Every self-respecting Unix system had a version of Make bundled with it. “Those who cannot remember the past are condemned to repeat it.”Īny library or executable that was made compiling more than a couple of source files involved Make.







Generating a makefile for c program linux