Makefile.Host 749 B

1234567891011121314151617181920212223242526272829303132
  1. all_hosts = Skeleton Linux Linux-SGX
  2. ifneq ($(MAKEFILE_CONFIGS_INCLUDED),y)
  3. $(error do not include Makefile.Host directly. include Makefile.configs)
  4. endif
  5. ifeq ($(PAL_HOST),)
  6. ifeq ($(findstring x86_64,$(SYS))$(findstring linux,$(SYS)),x86_64linux)
  7. PAL_HOST := Linux
  8. else
  9. $(error Unsupported platform: $(SYS))
  10. endif
  11. endif
  12. ifeq ($(SGX_RUN),1)
  13. $(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")
  14. endif
  15. ifeq ($(SGX),1)
  16. PAL_HOST := $(patsubst %-SGX,%,$(PAL_HOST))-SGX
  17. endif
  18. ifeq ($(findstring $(PAL_HOST),$(all_hosts)),)
  19. $(error Unsupported platform: $(PAL_HOST))
  20. endif
  21. export PAL_HOST
  22. .DEFAULT_GOAL := all
  23. .PHONY: print_host
  24. print_host:
  25. @echo $(PAL_HOST)