diff options
author | Calvin Morrison <mutantturkey@gmail.com> | 2013-10-17 10:50:15 -0400 |
---|---|---|
committer | Calvin Morrison <mutantturkey@gmail.com> | 2013-10-17 10:50:15 -0400 |
commit | c08ffceaaccd3d1140443fd29f81f8dc9c24ca3a (patch) | |
tree | 7d32d6c3dde6e5813eaa089fe037d8e1ac8f1b01 | |
parent | 87926cdc71d259eaff2146fe193424b264b7c627 (diff) |
add a static library to our makefile
-rw-r--r-- | Makefile | 12 |
1 files changed, 8 insertions, 4 deletions
@@ -1,15 +1,19 @@ VERSION=\"v0.0.1\" CC = gcc CFLAGS = -O3 -s -mtune=native -Wall -DVERSION=$(VERSION) -Wextra +CLIBS = -I. -L. -lkmer -all: libkmer.so kmer_total_count kmer_frequency_per_sequence +all: libkmer.so libkmer.a kmer_total_count kmer_frequency_per_sequence libkmer.so: $(CC) kmer_utils.c -o libkmer.so $(CFLAGS) -shared -fPIC -DSHARED=0 +libkmer.a: + ar rcs libkmer.a libkmer.so + chmod +x libkmer.a kmer_total_count: - $(CC) kmer_total_count.c -o kmer_total_count kmer_utils.c $(CFLAGS) -DSHARED=0 + $(CC) kmer_total_count.c -o kmer_total_count $(CLIBS) $(CFLAGS) -DSHARED=0 kmer_frequency_per_sequence: - $(CC) kmer_frequency_per_sequence.c kmer_utils.c -o kmer_frequency_per_sequence $(CFLAGS) + $(CC) kmer_frequency_per_sequence.c -o kmer_frequency_per_sequence $(CLIBS) $(CFLAGS) clean: - rm -vf kmer_total_count kmer_frequency_per_sequence libkmer.so + rm -vf kmer_total_count kmer_frequency_per_sequence libkmer.so libkmer.a |