# We have a conf and classes directory, append to BBPATH
BBPATH .= ":${LAYERDIR}"

# We have a recipes directory, add to BBFILES
BBFILES += "${LAYERDIR}/recipes*/*/*.bb ${LAYERDIR}/recipes*/*/*.bbappend"

BBFILE_COLLECTIONS += "clang-layer"
BBFILE_PATTERN_clang-layer := "^${LAYERDIR}/"
BBFILE_PRIORITY_clang-layer = "7"
LAYERSERIES_COMPAT_clang-layer = "gatesgarth"
LAYERDEPENDS_clang-layer = "core"

BBFILES_DYNAMIC += " \
    browser-layer:${LAYERDIR}/dynamic-layers/browser-layer/*/*.bb \
    browser-layer:${LAYERDIR}/dynamic-layers/browser-layer/*/*.bbappend \
    openembedded-layer:${LAYERDIR}/dynamic-layers/openembedded-layer/*/*/*.bb \
    openembedded-layer:${LAYERDIR}/dynamic-layers/openembedded-layer/*/*/*.bbappend \
    networking-layer:${LAYERDIR}/dynamic-layers/networking-layer/*/*/*.bb \
    networking-layer:${LAYERDIR}/dynamic-layers/networking-layer/*/*/*.bbappend \
"

PREFERRED_PROVIDER_libgcc-initial = "libgcc-initial"
#PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}compilerlibs_forcevariable = "libcxx"
PREFERRED_PROVIDER_llvm = "clang"
PREFERRED_PROVIDER_llvm-native = "clang-native"
PREFERRED_PROVIDER_nativesdk-llvm = "nativesdk-clang"
INHERIT += "clang"

# Do not include clang in SDK unless user wants to
CLANGSDK ??= "0"

LLVMVERSION = "11.0.0"

require conf/nonclangable.conf
require conf/nonscanable.conf

NON_MULTILIB_RECIPES_append = " bcc bpftrace"
