Commit 30c240da authored by Jack Doerner's avatar Jack Doerner

Merge branch 'master' into flatoram

parents acc368b7 ce02194a
CC ?= gcc
CPP ?= cpp
AR ?= ar
OBLIVCC = $(OBLIVC_PATH)/bin/oblivcc
OBLIVCH = $(OBLIVC_PATH)/src/ext/oblivc
OBLIVCA = $(OBLIVC_PATH)/_build/libobliv.a
......@@ -32,13 +35,13 @@ $(TEST_BINS:%=$(TEST_OUT_PATH)/%): $(TEST_OUT_PATH)/%: $(TEST_PATH)/%.oo $(TEST_
$(ACKLIB): $(OBJS:%=$(SRC_PATH)/%)
mkdir -p $(LIB_OUT_PATH)
ar rcs $@ $^
$(AR) rcs $@ $^
-include $(patsubst %.oo,%.od,$(OBJS:.o=.d))
%.o: %.c
gcc -c $(CFLAGS) $*.c -o $*.o -I $(OBLIVCH)
cpp -MM $(CFLAGS) $*.c -I $(OBLIVCH) > $*.d
$(CC) -c $(CFLAGS) $*.c -o $*.o -I $(OBLIVCH)
$(CPP) -MM $(CFLAGS) $*.c -I $(OBLIVCH) > $*.d
%.fssl.oo: %.oc
......@@ -46,19 +49,19 @@ $(ACKLIB): $(OBJS:%=$(SRC_PATH)/%)
%.sqrt.oo: %.oc
cpp -MM $(CFLAGS) -DORAM_OVERRIDE=ORAM_TYPE_SQRT $*.oc -MT $*.sqrt.oo > $*.sqrt.od
$(CPP) -MM $(CFLAGS) -DORAM_OVERRIDE=ORAM_TYPE_SQRT $*.oc -MT $*.sqrt.oo > $*.sqrt.od
%.circuit.oo: %.oc
cpp -MM $(CFLAGS) -DORAM_OVERRIDE=ORAM_TYPE_CIRCUIT $*.oc -MT $*.circuit.oo > $*.circuit.od
$(CPP) -MM $(CFLAGS) -DORAM_OVERRIDE=ORAM_TYPE_CIRCUIT $*.oc -MT $*.circuit.oo > $*.circuit.od
%.linear.oo: %.oc
cpp -MM $(CFLAGS) -DORAM_OVERRIDE=ORAM_TYPE_LINEAR $*.oc -MT $*.linear.oo > $*.linear.od
$(CPP) -MM $(CFLAGS) -DORAM_OVERRIDE=ORAM_TYPE_LINEAR $*.oc -MT $*.linear.oo > $*.linear.od
%.oo: %.oc
$(OBLIVCC) -c $(CFLAGS) $*.oc -o $*.oo
cpp -MM $(CFLAGS) $*.oc -MT $*.oo > $*.od
$(CPP) -MM $(CFLAGS) $*.oc -MT $*.oo > $*.od
rm -f $(OBJS:%=$(SRC_PATH)/%) $(patsubst %.oo,$(SRC_PATH)/%.od,$(patsubst %.o,$(SRC_PATH)/%.d,$(OBJS))) $(ACKLIB)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment