-
Notifications
You must be signed in to change notification settings - Fork 7
/
product.mk
35 lines (29 loc) · 1.31 KB
/
product.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
BORT_PATH := vendor/memfault/bort
GRADLE_PROPERTIES := MemfaultPackages/gradle.properties
BORT_MAJOR_VERSION := $(shell cat $(BORT_PATH)/$(GRADLE_PROPERTIES) | grep UPSTREAM_MAJOR_VERSION | cut -f2 -d"=")
BORT_MINOR_VERSION := $(shell cat $(BORT_PATH)/$(GRADLE_PROPERTIES) | grep UPSTREAM_MINOR_VERSION | cut -f2 -d"=")
BORT_PATCH_VERSION := $(shell cat $(BORT_PATH)/$(GRADLE_PROPERTIES) | grep UPSTREAM_PATCH_VERSION | cut -f2 -d"=")
BORT_VERSION := $(BORT_MAJOR_VERSION).$(BORT_MINOR_VERSION).$(BORT_PATCH_VERSION)
PRODUCT_PROPERTY_OVERRIDES += \
vendor.memfault.bort.version.sdk=$(BORT_VERSION)
PRODUCT_PACKAGES += \
MemfaultBort \
MemfaultDumpstateRunner \
MemfaultDumpster \
MemfaultStructuredLogd \
MemfaultUsageReporter \
TARGET_USES_MFLT_OTA ?= 0
TARGET_BUILD_BORT_UNDER_TEST ?= 0
ifeq ($(TARGET_USES_MFLT_OTA),1)
$(warning "Building with MemfaultBortOta")
PRODUCT_PACKAGES += MemfaultBortOta
endif
ifeq ($(TARGET_BUILD_BORT_UNDER_TEST),1)
$(warning "Building with Memfault test dependencies")
PRODUCT_PACKAGES += structured-client-example-c \
structured-client-example-cpp \
reporting-client-example-cpp \
reporting-client-example-c \
ReportingJavaTestApp
endif
include $(BORT_PATH)/version_check.mk