mirror of
https://github.com/Dasharo/coreboot.git
synced 2026-03-06 14:43:26 -08:00
46b6ef5b9f
Commands and parameters are passed as raw numbers, but that's the point, we want to test it with something more than normal SMMSTORE interface. Upstream-Status: Pending Change-Id: Ib3a32f0bdef038e4ccc2fb2bb8a6c98ae6d0cfbd Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
43 lines
737 B
Makefile
43 lines
737 B
Makefile
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
PRG := smmstore_debug
|
|
|
|
CC ?= $(CROSS_COMPILE)gcc
|
|
HOSTCC ?= $(CC)
|
|
INSTALL ?= /usr/bin/env install
|
|
PREFIX ?= /usr/local
|
|
|
|
HOSTCFLAGS ?= $(CFLAGS)
|
|
HOSTCFLAGS += -Wall -Wextra -MMD -MP -O3
|
|
|
|
HOSTLDFLAGS ?= $(LDFLAGS)
|
|
|
|
# there files are in this directory
|
|
SRC := smmstore_debug.c
|
|
|
|
OBJ := $(SRC:.c=.o)
|
|
DEP := $(SRC:.c=.o.d)
|
|
|
|
.PHONY: all debug clean install
|
|
|
|
all: $(PRG)
|
|
|
|
debug: HOSTCFLAGS += -O0 -g
|
|
debug: HOSTLDFLAGS += -g
|
|
debug: all
|
|
|
|
install: $(PRG)
|
|
$(INSTALL) -d $(DESTDIR)$(PREFIX)/bin/
|
|
$(INSTALL) $^ $(DESTDIR)$(PREFIX)/bin/
|
|
|
|
clean:
|
|
-$(RM) $(PRG) $(OBJ) $(DEP)
|
|
|
|
$(PRG): $(OBJ)
|
|
$(HOSTCC) -o $@ $^ $(HOSTLDFLAGS)
|
|
|
|
%.o: %.c
|
|
$(HOSTCC) $(HOSTCFLAGS) -c -o $@ -MF $@.d $<
|
|
|
|
-include $(DEP)
|