7835861f9d
Add build rules to build amdfwread tool. Also mark this as a dependency either while building tools or amdfw.rom. BUG=None TEST=Build and boot to OS in Skyrim with CBFS verification enabled. Signed-off-by: Karthikeyan Ramasubramanian <kramasub@google.com> Change-Id: I3fee4e4c77f62bb2840270b3eaaa58b894780d75 Reviewed-on: https://review.coreboot.org/c/coreboot/+/66939 Reviewed-by: Raul Rangel <rrangel@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
23 lines
860 B
Makefile
23 lines
860 B
Makefile
# SPDX-License-Identifier: BSD-3-Clause
|
|
|
|
amdfwtoolobj = amdfwtool.o data_parse.o
|
|
amdfwreadobj = amdfwread.o
|
|
|
|
AMDFWTOOLCFLAGS=-O2 -Wall -Wextra -Wshadow -Werror
|
|
AMDFWTOOLCFLAGS += -I $(top)/src/commonlib/bsd/include
|
|
|
|
HOSTPKGCONFIG ?= pkg-config
|
|
|
|
AMDFWTOOLCFLAGS += $(shell $(HOSTPKGCONFIG) --cflags libcrypto)
|
|
LDFLAGS += $(shell $(HOSTPKGCONFIG) --libs libcrypto)
|
|
|
|
$(objutil)/amdfwtool/%.o: $(top)/util/amdfwtool/%.c # $(HEADER)
|
|
$(HOSTCC) $(AMDFWTOOLCFLAGS) $(HOSTCFLAGS) -c -o $@ $<
|
|
|
|
$(objutil)/amdfwtool/amdfwtool: $(addprefix $(objutil)/amdfwtool/,$(amdfwtoolobj))
|
|
printf " AMDFWTOOL\n"
|
|
$(HOSTCC) $(addprefix $(objutil)/amdfwtool/,$(amdfwtoolobj)) $(LDFLAGS) -o $@
|
|
|
|
$(objutil)/amdfwtool/amdfwread: $(addprefix $(objutil)/amdfwtool/,$(amdfwreadobj))
|
|
printf " AMDFWREAD\n"
|
|
$(HOSTCC) $(addprefix $(objutil)/amdfwtool/,$(amdfwreadobj)) $(LDFLAGS) -o $@
|