diff options
author | Kamil Kaminski <kamilkss@gmail.com> | 2010-11-27 15:06:25 -0600 |
---|---|---|
committer | Kamil Kaminski <kamilkss@gmail.com> | 2010-11-27 15:06:25 -0600 |
commit | 4466182539196d2a2379481f08f0b0cacdf8ca75 (patch) | |
tree | 49f24ccbe2e36ebf835d84359ab239a9298f6c33 /Makefile | |
download | hashtable-4466182539196d2a2379481f08f0b0cacdf8ca75.tar.gz hashtable-4466182539196d2a2379481f08f0b0cacdf8ca75.tar.bz2 hashtable-4466182539196d2a2379481f08f0b0cacdf8ca75.zip |
Initial commit
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..3e20c8c --- /dev/null +++ b/Makefile @@ -0,0 +1,24 @@ +PROG = hashtbl +OBJS = $(PROG).o hashfuncs.o +CC = gcc +DBGFLAGS = -g -O0 +ifdef DEBUG + CFLAGS = $(DBGFLAGS) -Wall -std=c99 +else + CFLAGS = -Wall -std=c99 -O2 -march=native -mtune=native +endif +LDFLAGS = -lm + +$(PROG): $(OBJS) + $(CC) $(LDFLAGS) $(OBJS) -o $(PROG) + +$(PROG).o: $(PROG).c hashtbl.h hashfuncs.h + $(CC) -c $(CFLAGS) $(PROG).c + +hashfuncs.o: hashfuncs.c hashfuncs.h + $(CC) -c $(CFLAGS) hashfuncs.c + +.PHONY: clean + +clean: + rm -f *.o ./$(PROG) |