blob: 27f261d73231de9aa803063bfe671439f12ef69c [file] [log] [blame]
# Copyright 2020 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
#
# SPDX-License-Identifier: BSD-3-Clause
# == libabr ==
obj-y += \
abr_sysdeps.o \
pkg/abr/flow.o \
pkg/abr/util.o
# Global includes are added via symlinks in the top-level include/ dir.
#
# To match u-boot convention global includes don't use a lib/ prefix, but
# Fuchsia source does so we need some extra local include paths to compile
# these files without modification.
ccflags-y += -Ilib/fuchsia/pkg/abr/include
# == libavb and libavb_atx ==
obj-$(CONFIG_LIBAVB) += \
avb_sysdeps.o \
pkg/avb/libavb/avb_chain_partition_descriptor.o \
pkg/avb/libavb/avb_cmdline.o \
pkg/avb/libavb/avb_crc32.o \
pkg/avb/libavb/avb_crypto.o \
pkg/avb/libavb/avb_descriptor.o \
pkg/avb/libavb/avb_footer.o \
pkg/avb/libavb/avb_hash_descriptor.o \
pkg/avb/libavb/avb_hashtree_descriptor.o \
pkg/avb/libavb/avb_kernel_cmdline_descriptor.o \
pkg/avb/libavb/avb_property_descriptor.o \
pkg/avb/libavb/avb_rsa.o \
pkg/avb/libavb/avb_sha256.o \
pkg/avb/libavb/avb_sha512.o \
pkg/avb/libavb/avb_slot_verify.o \
pkg/avb/libavb/avb_util.o \
pkg/avb/libavb/avb_vbmeta_image.o \
pkg/avb/libavb/avb_version.o \
pkg/avb/libavb_atx/avb_atx_validate.o
# Flags from libavb's Android.bp build file.
ccflags-$(CONFIG_LIBAVB) += \
-D_FILE_OFFSET_BITS=64 \
-D_POSIX_C_SOURCE=199309L \
-Wa,--noexecstack \
-Werror \
-Wall \
-Wextra \
-Wformat=2 \
-Wmissing-prototypes \
-Wno-psabi \
-Wno-unused-parameter \
-Wno-format \
-ffunction-sections \
-DAVB_ENABLE_DEBUG \
-DAVB_COMPILATION
# Custom additions for Estelle compilation.
# Use C99 for new syntax (e.g. declaring vars in for-loop) + GNU variant for
# non-standard extensions like asm().
ccflags-$(CONFIG_LIBAVB) += \
-std=gnu99
# == libzbi ==
obj-y += \
pkg/zbi/zbi.o
ccflags-y += -Ilib/fuchsia/pkg/zbi/include