Skip to content

Commit

Permalink
Modified my first Makefile!
Browse files Browse the repository at this point in the history
  • Loading branch information
mblair committed Oct 7, 2010
1 parent 20d9489 commit b22de59
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 8 deletions.
15 changes: 7 additions & 8 deletions book_code/unix-xwindows/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,14 @@ OBJECTS = \

CSLIB = cslib.a

CC = gcc
CFLAGS = -g -I. $(CCFLAGS)
CONFIG = `csh config.csh -DHasPoll $(CC) -E -DHasPoll xcompat.c`
CC = clang
CFLAGS = -I. $(CCFLAGS)

# ***************************************************************
# Entry to bring the package up to date
# The "make all" entry should be the first real entry

all: $(CSLIB) gccx
all: $(CSLIB)

# ***************************************************************
# Standard entries to remove files from the directories
Expand Down Expand Up @@ -58,18 +57,18 @@ random.o: random.c random.h genlib.h

graphics.o: graphics.c graphics.h extgraph.h xmanager.h xcompat.h \
glibrary.h genlib.h gcalloc.h simpio.h strlib.h Makefile
$(CC) $(CONFIG) $(CFLAGS) -c graphics.c
$(CC) $(CFLAGS) -c graphics.c

xmanager.o: xmanager.c xmanager.h xdisplay.h xcompat.h glibrary.h \
genlib.h exception.h simpio.h Makefile
$(CC) $(CONFIG) $(CFLAGS) -c xmanager.c
$(CC) $(CFLAGS) -c xmanager.c

xdisplay.o: xdisplay.c xdisplay.h xmanager.h glibrary.h genlib.h strlib.h \
Makefile
$(CC) $(CONFIG) $(CFLAGS) -c xdisplay.c
$(CC) $(CFLAGS) -c xdisplay.c

xcompat.o: xcompat.c xcompat.h Makefile
$(CC) $(CONFIG) $(CFLAGS) -c xcompat.c
$(CC) $(CFLAGS) -c xcompat.c

glibrary.o: glibrary.c glibrary.h genlib.h
$(CC) $(CFLAGS) -c glibrary.c
Expand Down
5 changes: 5 additions & 0 deletions book_code/unix-xwindows/README
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
This is eroberts' original README. It no longer applies, but has been kept for completeness.
--------------------------------------------------------------------------------------------



README file for the unix-xwindows subdirectory
Last modified on Thu Oct 20 00:01:05 1994 by eroberts
________________________________________________________________________
Expand Down

0 comments on commit b22de59

Please sign in to comment.