2 # C++ source (with .cpp extension)
3 CPSOURCE= hashTimeSA.cpp
4 # C source (.c extension)
5 CSOURCE= SHA1_priv.c MD5.c SHA1.c
6 OFILES = $(CSOURCE:%.c=%.o) $(CPSOURCE:%.cpp=%.o)
8 LOCAL_BUILD= $(shell echo $(LOCAL_BUILD_DIR))
10 FRAMEWORKS= -framework CoreFoundation
13 PINCLUDES= -I$(LOCAL_BUILD)/include
14 CINCLUDES= $(FINCLUDES) $(PINCLUDES)
15 WFLAGS= -Wno-four-char-constants -Wno-deprecated-declarations
16 CFLAGS= -g $(CINCLUDES) $(WFLAGS) $(FRAME_SEARCH) -Os
19 # This assumes final load with cc, not ld
21 ###LIBS= -lstdc++ -lcommonCrypto
23 LIBPATH= -L$(LOCAL_BUILD) -L/usr/local/lib/system
24 LDFLAGS= $(LIBS) $(LIBPATH) $(FRAME_SEARCH)
28 $(EXECUTABLE): $(OFILES)
29 $(CC) -o $(EXECUTABLE) $(FRAMEWORKS) $(OFILES) $(LDFLAGS)
32 rm -f *.o $(EXECUTABLE)
39 $(CC) $(CFLAGS) -c -o $*.o $<
42 $(CC) $(CFLAGS) -c -o $*.o $<