File tree Expand file tree Collapse file tree 6 files changed +1464
-12
lines changed Expand file tree Collapse file tree 6 files changed +1464
-12
lines changed Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ TRTS1_OBJS := init_enclave.o \
7171 trts_emm_sim.o
7272
7373TRTS2_OBJS := trts_nsp.o
74- TRTS_OBJS := $(TRTS1_OBJS ) $(TRTS2_OBJS )
74+ TRTS_OBJS := $(TRTS1_OBJS ) $(TRTS2_OBJS ) ctd.o
7575
7676TINST_OBJS := t_instructions.o \
7777 deriv.o
@@ -93,6 +93,15 @@ TLDR_C_OBJS := elf_parser.o \
9393
9494TLDR_OBJS := $(TLDR_ASM_OBJS ) $(TLDR_C_OBJS )
9595
96+ ctd.o : $(TRTS_DIR ) /ctd.c
97+ $(CC ) -mavx2 -O3 -masm=intel $(filter-out -O2,$(CFLAGS ) ) $(TCFLAGS ) -c $< -o $@ \
98+ -I$(COMMON_DIR)/inc/ \
99+ -I$(COMMON_DIR)/inc/tlibc/ \
100+ -I$(COMMON_DIR)/inc/internal \
101+ -I$(LINUX_SDK_DIR)/trts/ \
102+ -I$(LINUX_SDK_DIR)/pthread/ \
103+ -I$(LINUX_SDK_DIR)/tlibcxx/include
104+
96105LIBTRTS := libsgx_trts_sim.a
97106
98107vpath % .cpp $(TRTS_DIR ) :$(TINST_DIR )
Original file line number Diff line number Diff line change @@ -60,7 +60,9 @@ OBJS2 := trts_nsp.o
6060
6161OBJS3 := ema_rt.o
6262
63- OBJS := $(OBJS1 ) $(OBJS2 ) $(OBJ3 )
63+ OBJS4 := ctd.o # The CTD requires AVX2
64+
65+ OBJS := $(OBJS1 ) $(OBJS2 ) $(OBJ3 ) $(OBJS4 )
6466
6567all : $(OBJS ) elf_parser
6668
@@ -74,6 +76,10 @@ $(OBJS2): %.o: %.cpp
7476$(OBJS3 ) : % .o: % .c
7577 $(CC ) -c $(TCFLAGS ) $(CFLAGS ) -fPIC $< -o $@
7678
79+ $(OBJS4 ) : % .o: % .c
80+ $(CC ) -mavx2 -O3 -masm=intel $(filter-out -O2,$(CFLAGS ) ) $(TCFLAGS ) \
81+ -I$(COMMON_DIR ) /inc/internal -I$(COMMON_DIR ) /inc -c $< -o $@
82+
7783.PHONY : elf_parser
7884elf_parser : $(OBJS )
7985 $(MAKE ) -C linux
You can’t perform that action at this time.
0 commit comments