blob: dfa39f0a6f1ea1984e99bf4e40f336a91aa38c0a [file] [log] [blame]
Dan Pasanen03447712016-12-19 11:22:55 -06001PRODUCT_BRAND ?= LineageOS
Ricardo Cerqueira6ed03ff2011-11-28 16:37:47 +00002
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +00003PRODUCT_BUILD_PROP_OVERRIDES += BUILD_UTC_DATE=0
4
Steve Kondik5a27f632013-11-06 13:55:11 -08005ifeq ($(PRODUCT_GMS_CLIENTID_BASE),)
6PRODUCT_PROPERTY_OVERRIDES += \
7 ro.com.google.clientidbase=android-google
8else
9PRODUCT_PROPERTY_OVERRIDES += \
10 ro.com.google.clientidbase=$(PRODUCT_GMS_CLIENTID_BASE)
11endif
12
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +000013PRODUCT_PROPERTY_OVERRIDES += \
Zhao Wei Liewa18b0572017-01-13 15:41:01 +080014 keyguard.no_require_sim=true
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +000015
Ricardo Cerqueiraf3835632013-08-04 13:25:00 +010016PRODUCT_PROPERTY_OVERRIDES += \
Ricardo Cerqueiraa21887e2013-09-25 17:13:25 +010017 ro.build.selinux=1
Ricardo Cerqueiraf3835632013-08-04 13:25:00 +010018
Arne Coucheron61536d42016-09-09 00:04:09 +020019# Default notification/alarm sounds
20PRODUCT_PROPERTY_OVERRIDES += \
21 ro.config.notification_sound=Argon.ogg \
Zhao Wei Liew805a7a22016-10-03 15:30:05 +080022 ro.config.alarm_alert=Hassium.ogg
Arne Coucheron61536d42016-09-09 00:04:09 +020023
Ricardo Cerqueiraed634842015-09-12 00:13:01 +010024ifneq ($(TARGET_BUILD_VARIANT),user)
Steve Kondike4f938c2014-02-04 22:59:01 -080025# Thank you, please drive thru!
26PRODUCT_PROPERTY_OVERRIDES += persist.sys.dun.override=0
Ricardo Cerqueiraed634842015-09-12 00:13:01 +010027endif
Steve Kondike4f938c2014-02-04 22:59:01 -080028
Chirayu Desai88401db2013-03-20 16:17:17 +053029ifneq ($(TARGET_BUILD_VARIANT),eng)
Chirayu Desai59df3632013-02-15 21:16:39 +053030# Enable ADB authentication
Luca Stefanic22b0dc2017-08-17 22:11:34 +020031PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.adb.secure=1
Chirayu Desai88401db2013-03-20 16:17:17 +053032endif
Chirayu Desai59df3632013-02-15 21:16:39 +053033
Luca Stefani75a79d62017-08-17 22:44:27 +020034ifeq ($(BOARD_CACHEIMAGE_FILE_SYSTEM_TYPE),)
Luca Stefanic22b0dc2017-08-17 22:11:34 +020035 PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \
Luca Stefani75a79d62017-08-17 22:44:27 +020036 ro.device.cache_dir=/data/cache
37else
Luca Stefanic22b0dc2017-08-17 22:11:34 +020038 PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \
Luca Stefani75a79d62017-08-17 22:44:27 +020039 ro.device.cache_dir=/cache
40endif
41
Warren Togamib1637c82012-03-03 22:37:42 -100042# Backup Tool
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +000043PRODUCT_COPY_FILES += \
Dan Pasanen91f76202017-07-06 08:21:30 -050044 vendor/lineage/prebuilt/common/bin/backuptool.sh:install/bin/backuptool.sh \
45 vendor/lineage/prebuilt/common/bin/backuptool.functions:install/bin/backuptool.functions \
Luca Stefani5c60e4f2017-08-17 19:28:48 +020046 vendor/lineage/prebuilt/common/bin/50-lineage.sh:system/addon.d/50-lineage.sh \
Dan Pasanen91f76202017-07-06 08:21:30 -050047 vendor/lineage/prebuilt/common/bin/blacklist:system/addon.d/blacklist
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +000048
Abhisek Devkotaf1c5ab82016-07-06 15:18:29 -070049# Backup Services whitelist
50PRODUCT_COPY_FILES += \
Dan Pasanen91f76202017-07-06 08:21:30 -050051 vendor/lineage/config/permissions/backup.xml:system/etc/sysconfig/backup.xml
Abhisek Devkotaf1c5ab82016-07-06 15:18:29 -070052
Ricardo Cerqueiraaff5e542014-05-09 22:24:12 +010053# Signature compatibility validation
54PRODUCT_COPY_FILES += \
Dan Pasanen91f76202017-07-06 08:21:30 -050055 vendor/lineage/prebuilt/common/bin/otasigcheck.sh:install/bin/otasigcheck.sh
Ricardo Cerqueiraaff5e542014-05-09 22:24:12 +010056
Steve Kondik485527d2011-12-20 12:14:24 -080057# init.d support
58PRODUCT_COPY_FILES += \
Dan Pasanen91f76202017-07-06 08:21:30 -050059 vendor/lineage/prebuilt/common/etc/init.d/00banner:system/etc/init.d/00banner \
60 vendor/lineage/prebuilt/common/bin/sysinit:system/bin/sysinit
Steve Kondik485527d2011-12-20 12:14:24 -080061
Ricardo Cerqueirafd6bfe72015-03-16 12:22:11 +000062ifneq ($(TARGET_BUILD_VARIANT),user)
James Sullinseb7799c2012-04-05 20:18:18 -050063# userinit support
64PRODUCT_COPY_FILES += \
Dan Pasanen91f76202017-07-06 08:21:30 -050065 vendor/lineage/prebuilt/common/etc/init.d/90userinit:system/etc/init.d/90userinit
Ricardo Cerqueirafd6bfe72015-03-16 12:22:11 +000066endif
James Sullinseb7799c2012-04-05 20:18:18 -050067
Luca Stefani5c60e4f2017-08-17 19:28:48 +020068# Lineage-specific init file
Ricardo Cerqueira8f412cb2012-10-18 16:38:25 +010069PRODUCT_COPY_FILES += \
Luca Stefani5c60e4f2017-08-17 19:28:48 +020070 vendor/lineage/prebuilt/common/etc/init.local.rc:root/init.lineage.rc
Ricardo Cerqueira8f412cb2012-10-18 16:38:25 +010071
herriojr5d2c9982015-10-01 11:20:26 -070072# Copy over added mimetype supported in libcore.net.MimeUtils
73PRODUCT_COPY_FILES += \
Dan Pasanen91f76202017-07-06 08:21:30 -050074 vendor/lineage/prebuilt/common/lib/content-types.properties:system/lib/content-types.properties
herriojr5d2c9982015-10-01 11:20:26 -070075
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +000076# Enable SIP+VoIP on all targets
77PRODUCT_COPY_FILES += \
Ricardo Cerqueira3ff9b6f2012-07-11 11:21:50 +010078 frameworks/native/data/etc/android.software.sip.voip.xml:system/etc/permissions/android.software.sip.voip.xml
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +000079
sleeplessninja918a7ea2013-01-30 14:45:20 -060080# Enable wireless Xbox 360 controller support
81PRODUCT_COPY_FILES += \
82 frameworks/base/data/keyboards/Vendor_045e_Product_028e.kl:system/usr/keylayout/Vendor_045e_Product_0719.kl
83
Luca Stefani5c60e4f2017-08-17 19:28:48 +020084# This is Lineage!
Steve Kondike0c12da2012-03-25 17:21:32 -070085PRODUCT_COPY_FILES += \
Dan Pasanen91f76202017-07-06 08:21:30 -050086 vendor/lineage/config/permissions/com.cyanogenmod.android.xml:system/etc/permissions/com.cyanogenmod.android.xml
Steve Kondike0c12da2012-03-25 17:21:32 -070087
Luca Stefani5c60e4f2017-08-17 19:28:48 +020088# Include Lineage audio files
89include vendor/lineage/config/lineage_audio.mk
Arne Coucheron61536d42016-09-09 00:04:09 +020090
Luca Stefani25801972016-08-27 00:44:50 +020091ifneq ($(TARGET_DISABLE_CMSDK), true)
Adnan Begovicf3610f52016-03-15 14:17:47 -070092# CMSDK
Dan Pasanen91f76202017-07-06 08:21:30 -050093include vendor/lineage/config/cmsdk_common.mk
Luca Stefani25801972016-08-27 00:44:50 +020094endif
Adnan Begovicf3610f52016-03-15 14:17:47 -070095
Michael Bestasbeb05c82017-07-18 19:57:26 +030096# TWRP
97ifeq ($(WITH_TWRP),true)
Dan Pasanen91f76202017-07-06 08:21:30 -050098include vendor/lineage/config/twrp.mk
Michael Bestasbeb05c82017-07-18 19:57:26 +030099endif
100
Dan Pasanen24a1cc92016-12-28 22:59:21 -0600101# Bootanimation
Asher Simondse035b9a2017-01-16 21:52:24 -0600102PRODUCT_PACKAGES += \
103 bootanimation.zip
Dan Pasanen24a1cc92016-12-28 22:59:21 -0600104
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200105# Required Lineage packages
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +0000106PRODUCT_PACKAGES += \
Steve Kondik4992d382016-08-29 18:23:03 -0700107 BluetoothExt \
Roman Birgcdb0ea62016-07-25 08:45:42 -0700108 CMAudioService \
Steve Kondik21e414a2016-09-03 05:28:29 -0700109 CMParts \
Steve Kondike0c297d2011-12-20 16:16:01 -0800110 Development \
d34d851457a2016-07-20 13:19:32 -0700111 Profiles \
Luis Vidal049d4c52016-08-13 01:32:58 -0700112 WeatherManagerService
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +0000113
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200114# Optional packages
Ricardo Cerqueirae1f37382011-11-27 19:56:54 +0000115PRODUCT_PACKAGES += \
Ricardo Cerqueira117984f2015-01-04 01:55:24 +0000116 libemoji \
Arne Coucheron61536d42016-09-09 00:04:09 +0200117 LiveWallpapersPicker \
Steve Kondikdf96b442016-10-13 11:37:08 -0700118 PhotoTable \
119 Terminal
Koushik Dutta8387c322011-11-26 17:31:19 -0800120
Alexander Martinze7f40582016-12-01 18:57:48 +0100121# Include explicitly to work around GMS issues
Steve Kondikdac37852015-12-01 13:31:45 -0800122PRODUCT_PACKAGES += \
Alexander Martinze7f40582016-12-01 18:57:48 +0100123 libprotobuf-cpp-full \
Steve Kondikdac37852015-12-01 13:31:45 -0800124 librsjni
125
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200126# Custom Lineage packages
Steve Kondik04a49412011-12-14 14:02:19 -0800127PRODUCT_PACKAGES += \
Steve Kondikc4f6b972014-12-09 13:29:29 -0800128 AudioFX \
Arne Coucheron3ae1edd2015-11-05 02:35:12 +0100129 CMSettingsProvider \
Steve Kondikdf96b442016-10-13 11:37:08 -0700130 CMUpdater \
cretin457674e052017-02-11 11:39:59 -0800131 LineageSetupWizard \
Steve Kondikdf96b442016-10-13 11:37:08 -0700132 Eleven \
d34d2cf159c2016-03-08 09:12:04 -0800133 ExactCalculator \
Joey Rizzoli177ab032017-04-20 22:17:37 +0200134 Jelly \
Luis Vidal6d61d302016-03-21 10:18:29 -0700135 LiveLockScreenService \
Steve Kondikdf96b442016-10-13 11:37:08 -0700136 LockClock \
Steve Kondikdf96b442016-10-13 11:37:08 -0700137 Trebuchet \
138 WallpaperPicker \
139 WeatherProvider
Steve Kondik04a49412011-12-14 14:02:19 -0800140
Abhisek Devkotacf03e162016-03-14 12:45:43 -0800141# Exchange support
142PRODUCT_PACKAGES += \
143 Exchange2
144
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200145# Extra tools in Lineage
Sebastian Schmidt7d5de0c2012-04-15 11:39:25 +0200146PRODUCT_PACKAGES += \
Arne Coucheron61536d42016-09-09 00:04:09 +0200147 7z \
Arne Coucheron61536d42016-09-09 00:04:09 +0200148 bash \
149 bzip2 \
150 curl \
Steve Kondikdf96b442016-10-13 11:37:08 -0700151 fsck.ntfs \
152 gdbserver \
153 htop \
154 lib7z \
155 libsepol \
156 micro_bench \
157 mke2fs \
158 mkfs.ntfs \
159 mount.ntfs \
160 oprofiled \
161 pigz \
Arne Coucheron61536d42016-09-09 00:04:09 +0200162 powertop \
Steve Kondikdf96b442016-10-13 11:37:08 -0700163 sqlite3 \
164 strace \
165 tune2fs \
Arne Coucheron61536d42016-09-09 00:04:09 +0200166 unrar \
167 unzip \
168 vim \
169 wget \
170 zip
Sebastian Schmidt7d5de0c2012-04-15 11:39:25 +0200171
Steve Kondik75956202016-08-07 23:21:29 -0700172# Custom off-mode charger
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200173ifneq ($(WITH_LINEAGE_CHARGER),false)
Steve Kondik75956202016-08-07 23:21:29 -0700174PRODUCT_PACKAGES += \
175 charger_res_images \
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200176 lineage_charger_res_images \
Steve Kondik75956202016-08-07 23:21:29 -0700177 font_log.png \
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200178 libhealthd.lineage
Steve Kondik75956202016-08-07 23:21:29 -0700179endif
180
181# ExFAT support
Scott Mertz2911a0e2015-11-09 11:35:41 -0800182WITH_EXFAT ?= true
183ifeq ($(WITH_EXFAT),true)
184TARGET_USES_EXFAT := true
185PRODUCT_PACKAGES += \
186 mount.exfat \
187 fsck.exfat \
188 mkfs.exfat
189endif
190
Chirayu Desai8636d672012-07-19 16:04:25 +0530191# Openssh
192PRODUCT_PACKAGES += \
193 scp \
194 sftp \
195 ssh \
196 sshd \
197 sshd_config \
198 ssh-keygen \
Chirayu Desai4bacf672012-08-19 17:30:04 +0530199 start-ssh
200
201# rsync
202PRODUCT_PACKAGES += \
203 rsync
Chirayu Desai8636d672012-07-19 16:04:25 +0530204
Michael Bestas7d5d16d2014-06-10 20:06:48 +0300205# Stagefright FFMPEG plugin
Steve Kondikb5ee3772016-09-06 03:06:35 -0700206PRODUCT_PACKAGES += \
207 libffmpeg_extractor \
208 libffmpeg_omx \
209 media_codecs_ffmpeg.xml
210
211PRODUCT_PROPERTY_OVERRIDES += \
212 media.sf.omx-plugin=libffmpeg_omx.so \
213 media.sf.extractor-plugin=libffmpeg_extractor.so
Steve Kondik7c968692015-07-08 09:53:12 -0700214
Joey Rizzoli73a39652016-11-23 21:19:00 +0100215# Storage manager
216PRODUCT_PROPERTY_OVERRIDES += \
217 ro.storage_manager.enabled=true
218
Ricardo Cerqueiraa21887e2013-09-25 17:13:25 +0100219# These packages are excluded from user builds
220ifneq ($(TARGET_BUILD_VARIANT),user)
Ricardo Cerqueiraa21887e2013-09-25 17:13:25 +0100221PRODUCT_PACKAGES += \
Steve Kondik275701b2013-11-06 12:41:34 -0800222 procmem \
Abhisek Devkota6af9acb2016-12-27 22:30:35 -0800223 procrank
224
225# Conditionally build in su
226ifeq ($(WITH_SU),true)
227PRODUCT_PACKAGES += \
Ricardo Cerqueiraa21887e2013-09-25 17:13:25 +0100228 su
repo Shareef Ali4bcfc312014-12-29 17:52:04 -0600229endif
Abhisek Devkota6af9acb2016-12-27 22:30:35 -0800230endif
Ricardo Cerqueiraa21887e2013-09-25 17:13:25 +0100231
Dan Pasanen91f76202017-07-06 08:21:30 -0500232DEVICE_PACKAGE_OVERLAYS += vendor/lineage/overlay/common
Koushik Duttac6f7a492011-11-28 07:44:23 -0800233
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200234PRODUCT_VERSION_MAJOR = 15
235PRODUCT_VERSION_MINOR = 0
Dan Pasanen69354102016-08-24 10:19:50 -0500236PRODUCT_VERSION_MAINTENANCE := 0
Adrian DC3e85bf72016-08-06 21:47:23 +0200237
Scott Mertza9950592016-08-05 12:24:19 -0700238ifeq ($(TARGET_VENDOR_SHOW_MAINTENANCE_VERSION),true)
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200239 LINEAGE_VERSION_MAINTENANCE := $(PRODUCT_VERSION_MAINTENANCE)
Scott Mertza9950592016-08-05 12:24:19 -0700240else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200241 LINEAGE_VERSION_MAINTENANCE := 0
Scott Mertza9950592016-08-05 12:24:19 -0700242endif
Koushik Duttac6f7a492011-11-28 07:44:23 -0800243
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200244# Set LINEAGE_BUILDTYPE from the env RELEASE_TYPE, for jenkins compat
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100245
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200246ifndef LINEAGE_BUILDTYPE
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100247 ifdef RELEASE_TYPE
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200248 # Starting with "LINEAGE_" is optional
249 RELEASE_TYPE := $(shell echo $(RELEASE_TYPE) | sed -e 's|^LINEAGE_||g')
250 LINEAGE_BUILDTYPE := $(RELEASE_TYPE)
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100251 endif
Warren Togami2128e2f2012-05-06 19:49:33 -1000252endif
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100253
254# Filter out random types, so it'll reset to UNOFFICIAL
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200255ifeq ($(filter RELEASE NIGHTLY SNAPSHOT EXPERIMENTAL,$(LINEAGE_BUILDTYPE)),)
256 LINEAGE_BUILDTYPE :=
Warren Togami2128e2f2012-05-06 19:49:33 -1000257endif
258
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200259ifdef LINEAGE_BUILDTYPE
260 ifneq ($(LINEAGE_BUILDTYPE), SNAPSHOT)
261 ifdef LINEAGE_EXTRAVERSION
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100262 # Force build type to EXPERIMENTAL
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200263 LINEAGE_BUILDTYPE := EXPERIMENTAL
264 # Remove leading dash from LINEAGE_EXTRAVERSION
265 LINEAGE_EXTRAVERSION := $(shell echo $(LINEAGE_EXTRAVERSION) | sed 's/-//')
266 # Add leading dash to LINEAGE_EXTRAVERSION
267 LINEAGE_EXTRAVERSION := -$(LINEAGE_EXTRAVERSION)
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100268 endif
269 else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200270 ifndef LINEAGE_EXTRAVERSION
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100271 # Force build type to EXPERIMENTAL, SNAPSHOT mandates a tag
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200272 LINEAGE_BUILDTYPE := EXPERIMENTAL
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100273 else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200274 # Remove leading dash from LINEAGE_EXTRAVERSION
275 LINEAGE_EXTRAVERSION := $(shell echo $(LINEAGE_EXTRAVERSION) | sed 's/-//')
276 # Add leading dash to LINEAGE_EXTRAVERSION
277 LINEAGE_EXTRAVERSION := -$(LINEAGE_EXTRAVERSION)
Ricardo Cerqueira554f3702013-09-24 17:58:56 +0100278 endif
Ricardo Cerqueirad8e76662012-06-08 11:08:15 +0100279 endif
280else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200281 # If LINEAGE_BUILDTYPE is not defined, set to UNOFFICIAL
282 LINEAGE_BUILDTYPE := UNOFFICIAL
283 LINEAGE_EXTRAVERSION :=
Warren Togami2128e2f2012-05-06 19:49:33 -1000284endif
285
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200286ifeq ($(LINEAGE_BUILDTYPE), UNOFFICIAL)
Matt Mowerf4168392013-12-13 11:04:14 -0600287 ifneq ($(TARGET_UNOFFICIAL_BUILD_ID),)
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200288 LINEAGE_EXTRAVERSION := -$(TARGET_UNOFFICIAL_BUILD_ID)
Matt Mowerf4168392013-12-13 11:04:14 -0600289 endif
290endif
291
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200292ifeq ($(LINEAGE_BUILDTYPE), RELEASE)
Ricardo Cerqueiraae71f042013-11-11 00:55:51 +0000293 ifndef TARGET_VENDOR_RELEASE_BUILD_ID
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200294 LINEAGE_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR).$(PRODUCT_VERSION_MAINTENANCE)$(PRODUCT_VERSION_DEVICE_SPECIFIC)-$(LINEAGE_BUILD)
Ricardo Cerqueiraae71f042013-11-11 00:55:51 +0000295 else
296 ifeq ($(TARGET_BUILD_VARIANT),user)
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200297 ifeq ($(LINEAGE_VERSION_MAINTENANCE),0)
298 LINEAGE_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR)-$(TARGET_VENDOR_RELEASE_BUILD_ID)-$(LINEAGE_BUILD)
Jessica Wagantall79204e62016-07-14 15:42:08 -0700299 else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200300 LINEAGE_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR).$(LINEAGE_VERSION_MAINTENANCE)-$(TARGET_VENDOR_RELEASE_BUILD_ID)-$(LINEAGE_BUILD)
Jessica Wagantall79204e62016-07-14 15:42:08 -0700301 endif
Ricardo Cerqueiraae71f042013-11-11 00:55:51 +0000302 else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200303 LINEAGE_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR).$(PRODUCT_VERSION_MAINTENANCE)$(PRODUCT_VERSION_DEVICE_SPECIFIC)-$(LINEAGE_BUILD)
Ricardo Cerqueiraae71f042013-11-11 00:55:51 +0000304 endif
305 endif
Koushik Duttac6f7a492011-11-28 07:44:23 -0800306else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200307 ifeq ($(LINEAGE_VERSION_MAINTENANCE),0)
308 LINEAGE_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR)-$(shell date -u +%Y%m%d)-$(LINEAGE_BUILDTYPE)$(LINEAGE_EXTRAVERSION)-$(LINEAGE_BUILD)
Jessica Wagantall79204e62016-07-14 15:42:08 -0700309 else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200310 LINEAGE_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR).$(LINEAGE_VERSION_MAINTENANCE)-$(shell date -u +%Y%m%d)-$(LINEAGE_BUILDTYPE)$(LINEAGE_EXTRAVERSION)-$(LINEAGE_BUILD)
Jessica Wagantall79204e62016-07-14 15:42:08 -0700311 endif
Koushik Duttac6f7a492011-11-28 07:44:23 -0800312endif
Koushik Duttad69b2922012-02-23 14:07:44 -0800313
314PRODUCT_PROPERTY_OVERRIDES += \
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200315 ro.lineage.version=$(LINEAGE_VERSION) \
316 ro.lineage.releasetype=$(LINEAGE_BUILDTYPE) \
Zhao Wei Liew046484f2017-01-07 15:55:35 +0800317 ro.modversion=$(LINEAGE_VERSION) \
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200318 ro.lineagelegal.url=https://lineageos.org/legal
Ricardo Cerqueirad5422742012-11-13 10:42:11 +0000319
Tom Powelle4c8c822017-01-06 22:29:06 -0800320PRODUCT_EXTRA_RECOVERY_KEYS += \
Dan Pasanen91f76202017-07-06 08:21:30 -0500321 vendor/lineage/build/target/product/security/lineage
Tom Powelle4c8c822017-01-06 22:29:06 -0800322
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200323-include vendor/lineage-priv/keys/keys.mk
Ricardo Cerqueira178dbd62013-10-23 20:56:56 +0100324
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200325LINEAGE_DISPLAY_VERSION := $(LINEAGE_VERSION)
Ricardo Cerqueira46161372014-01-09 10:25:31 +0000326
Brint E. Kriebelac948f52014-01-24 09:58:36 -0800327ifneq ($(PRODUCT_DEFAULT_DEV_CERTIFICATE),)
328ifneq ($(PRODUCT_DEFAULT_DEV_CERTIFICATE),build/target/product/security/testkey)
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200329 ifneq ($(LINEAGE_BUILDTYPE), UNOFFICIAL)
Zhao Wei Liew046484f2017-01-07 15:55:35 +0800330 ifndef TARGET_VENDOR_RELEASE_BUILD_ID
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200331 ifneq ($(LINEAGE_EXTRAVERSION),)
332 # Remove leading dash from LINEAGE_EXTRAVERSION
333 LINEAGE_EXTRAVERSION := $(shell echo $(LINEAGE_EXTRAVERSION) | sed 's/-//')
334 TARGET_VENDOR_RELEASE_BUILD_ID := $(LINEAGE_EXTRAVERSION)
Zhao Wei Liew046484f2017-01-07 15:55:35 +0800335 else
336 TARGET_VENDOR_RELEASE_BUILD_ID := $(shell date -u +%Y%m%d)
337 endif
338 else
339 TARGET_VENDOR_RELEASE_BUILD_ID := $(TARGET_VENDOR_RELEASE_BUILD_ID)
340 endif
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200341 ifeq ($(LINEAGE_VERSION_MAINTENANCE),0)
342 LINEAGE_DISPLAY_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR)-$(TARGET_VENDOR_RELEASE_BUILD_ID)-$(LINEAGE_BUILD)
Zhao Wei Liew046484f2017-01-07 15:55:35 +0800343 else
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200344 LINEAGE_DISPLAY_VERSION := $(PRODUCT_VERSION_MAJOR).$(PRODUCT_VERSION_MINOR).$(LINEAGE_VERSION_MAINTENANCE)-$(TARGET_VENDOR_RELEASE_BUILD_ID)-$(LINEAGE_BUILD)
Zhao Wei Liew046484f2017-01-07 15:55:35 +0800345 endif
Ricardo Cerqueira46161372014-01-09 10:25:31 +0000346 endif
Ricardo Cerqueira46161372014-01-09 10:25:31 +0000347endif
Ricardo Cerqueira74b4f9b2014-01-11 16:00:16 +0000348endif
Ricardo Cerqueira46161372014-01-09 10:25:31 +0000349
350PRODUCT_PROPERTY_OVERRIDES += \
Luca Stefani5c60e4f2017-08-17 19:28:48 +0200351 ro.lineage.display.version=$(LINEAGE_DISPLAY_VERSION)
Ricardo Cerqueira46161372014-01-09 10:25:31 +0000352
Brint E. Kriebela1e49122014-01-31 11:59:56 -0800353-include $(WORKSPACE)/build_env/image-auto-bits.mk
Dan Pasanen91f76202017-07-06 08:21:30 -0500354-include vendor/lineage/config/partner_gms.mk
Koushik Dutta41fd0aa2013-12-07 22:04:17 -0800355-include vendor/cyngn/product.mk
Steve Kondikb9dd4002014-09-10 15:41:43 -0700356
Chris Sarbora39b9aa82014-12-17 14:41:28 -0800357$(call prepend-product-if-exists, vendor/extra/product.mk)