| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889 | include ../src/Makefile.HostCC	= gccCFLAGS	= -Wall -O2 -std=c11 -fno-builtin -nostdlib -mavx -no-pie \	  -I../include/pal -I../lib -I../srcpreloads    = $(patsubst %.c,%,$(wildcard *.so.c))executables = $(filter-out $(preloads),$(patsubst %.c,%,$(wildcard *.c))) ..Bootstrapmanifests   = manifest $(patsubst %.manifest.template,%.manifest,$(wildcard *.manifest.template))target = $(executables) $(manifests)graphene_lib = .lib/graphene-lib.apal_lib = ../../Runtime/libpal-$(PAL_HOST).soheaders = $(wildcard ../include/pal/*.h).PHONY: defaultdefault: allinclude ../src/Makefile.TestRUNTIME_DIR = $(CURDIR)/../../Runtimeexport PAL_LOADER = $(RUNTIME_DIR)/pal-$(PAL_HOST).PHONY: allall: $(call expand_target,$(target)) $(preloads)ifeq ($(DEBUG),1)CC += -gendifexport DEBUGifeq ($(WERROR),1)CFLAGS += -Werrorendifmanifest_rules = \	-e 's:\$$(PAL):$(abspath ../../Runtime/pal_loader):g' \	-e 's:\$$(PWD):$(shell pwd)/:g' \	$(extra_rules)manifest: manifest.template	sed $(manifest_rules) $< >$@%.manifest: %.manifest.template $(executables) $(pal_lib)	sed $(manifest_rules) $< >$@	(grep -q "#\!" $@ && chmod +x $@) || true../src/user_shared_start.o ../src/user_start.o: ../src/user_start.S	$(MAKE) -C ../src $(notdir $@)ifeq ($(findstring x86_64,$(SYS))$(findstring linux,$(SYS)),x86_64linux)$(preloads): %.so: %.so.c ../src/user_shared_start.o \	$(graphene_lib) $(pal_lib) ../include/pal/pal.h	@echo [ $@ ]	@$(CC) -shared -fPIC $(filter-out -no-pie,$(CFLAGS)) $^ -o $@$(executables): %: %.c ../src/user_start.o \	$(graphene_lib) $(pal_lib) $(preloads) ../include/pal/pal.h	@echo [ $@ ]	@$(CC) $(CFLAGS) $^ -o $@.lib/host_endian.h: ../src/host/$(PAL_HOST)/host_endian.h	@mkdir -p .lib	cp -f $< $@$(graphene_lib): .lib/host_endian.h	$(MAKE) -C ../lib target=$(abspath .lib)/Process2.manifest.sgx: Bootstrap.manifest.sgxelse.IGNORE: $(preloads) $(executables)$(preloads) $(executables):endifexport PYTHONPATH=../../Scripts.PHONY: regressionregression:	$(RM) pal-regression.xml	$(MAKE) pal-regression.xmlpal-regression.xml: test_pal.py $(call expand_target,$(target))	python3 -m pytest --junit-xml $@ -v test_pal.py.PHONY: cleanclean:	rm -rf $(call expand_target,$(target)) $(preloads) *.tmp .lib *.cached *.sig
 |