Makefile 301 B

1234567891011121314151617
  1. # SPDX-License-Identifier: GPL-2.0
  2. ifndef CROSS_COMPILE
  3. uname_M := $(shell uname -m 2>/dev/null || echo not)
  4. ARCH ?= $(shell echo $(uname_M) | sed -e s/i.86/x86/ -e s/x86_64/x86/)
  5. ifeq ($(ARCH),x86)
  6. CC := $(CROSS_COMPILE)gcc
  7. PROGS := hpet_example
  8. all: $(PROGS)
  9. clean:
  10. rm -fr $(PROGS)
  11. endif
  12. endif