mirror of
https://github.com/clearlinux/graphene.git
synced 2026-08-28 13:25:43 +00:00
06ec21be32
Also check for unsupported architecture in Makefile.configs.
33 lines
714 B
Makefile
33 lines
714 B
Makefile
all_hosts = Skeleton Linux Linux-SGX
|
|
|
|
ifneq ($(MAKEFILE_CONFIGS_INCLUDED),y)
|
|
$(error do not include Makefile.Host directly. include Makefile.configs)
|
|
endif
|
|
|
|
ifeq ($(PAL_HOST),)
|
|
ifeq ($(findstring linux,$(SYS)),linux)
|
|
PAL_HOST := Linux
|
|
else
|
|
$(error Unsupported platform: $(SYS))
|
|
endif
|
|
endif
|
|
|
|
ifeq ($(SGX_RUN),1)
|
|
$(error "SGX_RUN has been removed. Always set SGX=1 if building for SGX and use the 'sgx-tokens' make target to build launch/EINIT tokens")
|
|
endif
|
|
|
|
ifeq ($(SGX),1)
|
|
PAL_HOST := $(patsubst %-SGX,%,$(PAL_HOST))-SGX
|
|
endif
|
|
|
|
ifeq ($(findstring $(PAL_HOST),$(all_hosts)),)
|
|
$(error Unsupported platform: $(PAL_HOST))
|
|
endif
|
|
|
|
export PAL_HOST
|
|
|
|
.DEFAULT_GOAL := all
|
|
.PHONY: print_host
|
|
print_host:
|
|
@echo $(PAL_HOST)
|