CSC209H1 Lecture Notes - Makefile, Gnu Compiler Collection

38 views1 pages
24 Apr 2013
School
Course
Professor

Document Summary

Assignment 4 makefile: makefiles were originally designed to support separate compiltation of c files, ex. Flags = -wall -g all : query printlog query : query. o message. o queue. o gcc -o $^ printlog : printlog. o message. o queue. o gcc -o $^ %. o : %. c message. h gcc -c $< clean : rm *. o query printlog: terminology. Cflags= -dport=$(port) -wall werror -g all: buxserver buxfer buxserver: buxserver. o lists. o wrapsock. o. -o buxserver buxserver. o lists. o wrapsock. o buxfer: buxfer. o lists. o. -o buxfer buxfer. o lists. o wrapsock. o: wrapsock. c wrapsock. h. -c $< clean: rm *. o buxfer buxserver: the action for each executable links together the . o files to create the executable. Each . o file included is also in the prereq for the target as well: the pattern rule can be expanded out with the following. Notice wrapsock. o doesn"t follow the pattern and needs its own target before the pattern rule buxfer. o: buxfer. c lists. h.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents