File tree Expand file tree Collapse file tree 3 files changed +6
-5
lines changed
Expand file tree Collapse file tree 3 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -148,10 +148,6 @@ GO_TAGS := $(build_tags)
148148# -ldflags
149149LD_FLAGS := $(ldflags )
150150
151- ifeq ($(SGX_MODE ) , HW)
152- CGO_LDFLAGS += $(shell pkg-config --libs libsgx_epid)
153- endif
154-
155151all : build_all
156152
157153go.sum : go.mod
Original file line number Diff line number Diff line change @@ -63,6 +63,11 @@ build: build-rust build-go
6363
6464.PHONY : build-rust
6565build-rust : build-enclave
66+ if [[ $( SGX_MODE) == HW ]]; then \
67+ sed -i ' s/sgx_epid_sim/sgx_epid/' ./api/link_std.go; \
68+ else \
69+ sed -i ' s/sgx_epid/sgx_epid_sim/' ./api/link_std.go; \
70+ fi ;
6671 cargo build -Z unstable-options --profile $(BUILD_PROFILE ) --features " $( FEATURES_U) "
6772 cp target/$(BUILD_PROFILE ) /libgo_cosmwasm.$(DLL_EXT ) api
6873 @ # this pulls out ELF symbols, 80% size reduction!
Original file line number Diff line number Diff line change 33
44package api
55
6- // #cgo LDFLAGS: -Wl,-rpath,${SRCDIR} -L${SRCDIR} -lgo_cosmwasm -lsgx_dcap_ql -lsgx_dcap_quoteverify
6+ // #cgo LDFLAGS: -Wl,-rpath,${SRCDIR} -L${SRCDIR} -lgo_cosmwasm -lsgx_dcap_ql -lsgx_dcap_quoteverify -lsgx_epid
77import "C"
You can’t perform that action at this time.
0 commit comments