diff --git a/Android.mk b/Android.mk
index 49666035c..14d69283a 100644
--- a/Android.mk
+++ b/Android.mk
@@ -39,4 +39,14 @@ $(IMS_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
ALL_DEFAULT_INSTALLED_MODULES += $(IMS_SYMLINKS)
+DM_LIBS := libdmengine.so libdmjavaplugin.so
+DM_SYMLINKS := $(addprefix $(TARGET_OUT)/priv-app/DMService/lib/arm/,$(notdir $(DM_LIBS)))
+$(DM_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
+ @echo "DMService lib link: $@"
+ @mkdir -p $(dir $@)
+ @rm -rf $@
+ $(hide) ln -sf /system/lib/$(notdir $@) $@
+
+ALL_DEFAULT_INSTALLED_MODULES += $(DM_SYMLINKS)
+
endif
diff --git a/BoardConfigLineage.mk b/BoardConfigLineage.mk
index 329a930c3..ae34f080a 100644
--- a/BoardConfigLineage.mk
+++ b/BoardConfigLineage.mk
@@ -1,9 +1,11 @@
# Common board config for marlin, sailfish
+# Build vendor image
+BOARD_VENDORIMAGE_PARTITION_SIZE := 314572800
+BOARD_VENDORIMAGE_FILE_SYSTEM_TYPE := ext4
+
# Kernel
BOARD_KERNEL_IMAGE_NAME := Image.lz4-dtb
TARGET_COMPILE_WITH_MSM_KERNEL := true
TARGET_KERNEL_CONFIG := lineageos_marlin_defconfig
TARGET_KERNEL_SOURCE := kernel/google/marlin
-
--include vendor/google/marlin/BoardConfigVendor.mk
diff --git a/device-lineage.mk b/device-lineage.mk
index ceb32858e..376f7fa1f 100644
--- a/device-lineage.mk
+++ b/device-lineage.mk
@@ -1,3 +1,18 @@
+# Build vendor img
+AB_OTA_PARTITIONS += vendor
+
+# Camera
+PRODUCT_PACKAGES += \
+ libmm-qcamera
+
+# DRM
+PRODUCT_PACKAGES += \
+ android.hardware.drm@1.1-service.clearkey
+
+PRODUCT_PROPERTY_OVERRIDES += \
+ drm.service.enabled=true \
+ media.mediadrmservice.enable=true
+
# Google Assistant
PRODUCT_PRODUCT_PROPERTIES += ro.opa.eligible_device=true
@@ -9,3 +24,11 @@ PRODUCT_PACKAGES += \
# Overlays
DEVICE_PACKAGE_OVERLAYS += device/google/marlin/overlay-lineage
+
+# Sensors
+PRODUCT_PACKAGES += \
+ libsensorndkbridge
+
+# Tool
+PRODUCT_PACKAGES += \
+ libtinyxml
diff --git a/extract-files.sh b/extract-files.sh
deleted file mode 100755
index 4ee1dfad1..000000000
--- a/extract-files.sh
+++ /dev/null
@@ -1,60 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) 2017 The LineageOS Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-set -e
-
-VENDOR=google
-DEVICE=marlin
-
-# Load extractutils and do some sanity checks
-MY_DIR="${BASH_SOURCE%/*}"
-if [[ ! -d "$MY_DIR" ]]; then MY_DIR="$PWD"; fi
-
-CM_ROOT="$MY_DIR"/../../..
-
-HELPER="$CM_ROOT"/vendor/lineage/build/tools/extract_utils.sh
-if [ ! -f "$HELPER" ]; then
- echo "Unable to find helper script at $HELPER"
- exit 1
-fi
-. "$HELPER"
-
-if [ $# -eq 0 ]; then
- SRC=adb
-else
- if [ $# -eq 1 ]; then
- SRC=$1
- else
- echo "$0: bad number of arguments"
- echo ""
- echo "usage: $0 [PATH_TO_EXPANDED_ROM]"
- echo ""
- echo "If PATH_TO_EXPANDED_ROM is not specified, blobs will be extracted from"
- echo "the device using adb pull."
- exit 1
- fi
-fi
-
-# Initialize the helper
-setup_vendor "$DEVICE" "$VENDOR" "$CM_ROOT"
-
-extract "$MY_DIR"/device-proprietary-files.txt "$SRC"
-
-# Don't disable MyVerizonServices app
-sed -i 's|||g'\
- "$CM_ROOT"/vendor/"$VENDOR"/"$DEVICE"/proprietary/etc/sysconfig/nexus.xml
-
-"$MY_DIR"/setup-makefiles.sh
diff --git a/extract-files.sh b/extract-files.sh
new file mode 120000
index 000000000..937477d69
--- /dev/null
+++ b/extract-files.sh
@@ -0,0 +1 @@
+marlin/extract-files.sh
\ No newline at end of file
diff --git a/lineage_sailfish.mk b/lineage_sailfish.mk
index 58c8328d6..a93cf1592 100644
--- a/lineage_sailfish.mk
+++ b/lineage_sailfish.mk
@@ -23,4 +23,4 @@ PRODUCT_BUILD_PROP_OVERRIDES += \
BUILD_FINGERPRINT := google/sailfish/sailfish:10/QP1A.190711.020/5800535:user/release-keys
-$(call inherit-product-if-exists, vendor/google/marlin/marlin-vendor.mk)
+$(call inherit-product-if-exists, vendor/google/sailfish/sailfish-vendor.mk)
diff --git a/marlin/BoardConfig.mk b/marlin/BoardConfig.mk
index f7ad64c93..9ac74ece6 100644
--- a/marlin/BoardConfig.mk
+++ b/marlin/BoardConfig.mk
@@ -102,7 +102,7 @@ BOARD_ROOT_EXTRA_FOLDERS := firmware firmware/radio persist
BOARD_ROOT_EXTRA_SYMLINKS := /vendor/lib/dsp:/dsp
BOARD_SEPOLICY_DIRS += device/google/marlin/sepolicy
-ifneq ($(filter marlin marlinf, $(TARGET_PRODUCT)),)
+ifneq ($(filter lineage_marlin marlin marlinf, $(TARGET_PRODUCT)),)
BOARD_SEPOLICY_DIRS += device/google/marlin/sepolicy/verizon
endif
BOARD_PLAT_PUBLIC_SEPOLICY_DIR := device/google/marlin/sepolicy/public
diff --git a/marlin/BoardConfigLineage.mk b/marlin/BoardConfigLineage.mk
index af21e4af9..43757e8d1 100644
--- a/marlin/BoardConfigLineage.mk
+++ b/marlin/BoardConfigLineage.mk
@@ -1,2 +1,4 @@
# BoardConfig for lineage_marlin
include device/google/marlin/BoardConfigLineage.mk
+
+-include vendor/google/marlin/BoardConfigVendor.mk
diff --git a/marlin/device-proprietary-files-vendor.txt b/marlin/device-proprietary-files-vendor.txt
new file mode 100644
index 000000000..eca05d119
--- /dev/null
+++ b/marlin/device-proprietary-files-vendor.txt
@@ -0,0 +1,677 @@
+-vendor/app/atfwd/atfwd.apk
+-vendor/app/colorservice/colorservice.apk
+-vendor/app/datastatusnotification/datastatusnotification.apk
+-vendor/app/embms/embms.apk
+vendor/app/embms/oem/config_params.xml
+vendor/app/embms/oem/provisioning_params.xml
+vendor/app/embms/oem/verizon_config_params.txt
+-vendor/app/fastdormancy/fastdormancy.apk
+-vendor/app/imssettings/imssettings.apk
+-vendor/app/QAS_DVC_MSP/QAS_DVC_MSP.apk
+-vendor/app/QtiTelephonyService/QtiTelephonyService.apk
+-vendor/app/radioconfig/radioconfig.apk
+-vendor/app/RCSBootstraputil/RCSBootstraputil.apk
+-vendor/app/SecureExtAuthService/SecureExtAuthService.apk
+-vendor/app/shutdownlistener/shutdownlistener.apk
+-vendor/app/TimeService/TimeService.apk
+-vendor/app/vzw_msdc_api/vzw_msdc_api.apk
+vendor/bin/adsprpcd
+vendor/bin/ATFWD-daemon
+vendor/bin/athdiag
+vendor/bin/cnd
+vendor/bin/cnss-daemon
+vendor/bin/cnss_diag
+vendor/bin/diag_callback_sample
+vendor/bin/diag_dci_sample
+vendor/bin/diag_mdlog
+vendor/bin/diag_socket_log
+vendor/bin/diag_uart_log
+vendor/bin/ftmdaemon
+vendor/bin/gptest
+vendor/bin/hdcp1prov
+vendor/bin/hw/android.hardware.bluetooth@1.0-service-qti
+vendor/bin/hw/android.hardware.drm@1.1-service.widevine
+vendor/bin/imsdatadaemon
+vendor/bin/imsqmidaemon
+vendor/bin/ims_rtp_daemon
+vendor/bin/irsc_util
+vendor/bin/loc_launcher
+vendor/bin/lowi-server
+vendor/bin/mct-unit-test-app
+vendor/bin/mdm_helper
+vendor/bin/mdm_helper_proxy
+vendor/bin/mm-qcamera-daemon
+vendor/bin/mm-qjpeg-dec-test
+vendor/bin/mm-qjpeg-enc-test
+vendor/bin/mm-qomx-idec-test
+vendor/bin/mm-qomx-ienc-test
+vendor/bin/msm_irqbalance
+vendor/bin/myftm
+vendor/bin/nanohub_slpi
+vendor/bin/netmgrd
+vendor/bin/nl_listener
+vendor/bin/perfd
+vendor/bin/PktRspTest
+vendor/bin/pm-proxy
+vendor/bin/pm-service
+vendor/bin/port-bridge
+vendor/bin/qfipsverify
+vendor/bin/qjpeg-dma-test
+vendor/bin/qseecomd
+vendor/bin/qseecom_sample_client
+vendor/bin/qti
+vendor/bin/radish
+vendor/bin/rmt_storage
+vendor/bin/slim_daemon
+vendor/bin/ssr_diag
+vendor/bin/ssr_setup
+vendor/bin/StoreKeybox
+vendor/bin/subsystem_ramdump
+vendor/bin/tbaseLoader
+vendor/bin/test_bet_8996
+vendor/bin/test_diag
+vendor/bin/test_module_pproc
+vendor/bin/thermal-engine
+vendor/bin/time_daemon
+vendor/bin/wdsdaemon
+vendor/bin/WifiLogger_app
+vendor/bin/xtra-daemon
+vendor/etc/acdbdata/Bluetooth_cal.acdb
+vendor/etc/acdbdata/General_cal.acdb
+vendor/etc/acdbdata/Global_cal.acdb
+vendor/etc/acdbdata/Handset_cal.acdb
+vendor/etc/acdbdata/Hdmi_cal.acdb
+vendor/etc/acdbdata/Headset_cal.acdb
+vendor/etc/acdbdata/Speaker_cal.acdb
+vendor/etc/camera/imx179_chromatix.xml
+vendor/etc/camera/imx378_chromatix.xml
+vendor/etc/camera/msm8996_camera.xml
+vendor/etc/data/dsi_config.xml
+vendor/etc/data/netmgr_config.xml
+vendor/etc/diag/CHRE.cfg
+vendor/etc/diag/IMS.cfg
+vendor/etc/diag/MarlinSailfish_Radio-generic.cfg
+vendor/etc/diag/wlan.cfg
+vendor/etc/flp.conf
+vendor/etc/init/android.hardware.bluetooth@1.0-service-qti.rc
+vendor/etc/init/android.hardware.drm@1.1-service.widevine.rc
+vendor/etc/izat.conf
+vendor/etc/lowi.conf
+vendor/etc/modem_stat.conf
+vendor/etc/perf-profile0.conf
+vendor/etc/permissions/LowPowerMonitorDeviceInterface.xml
+vendor/etc/permissions/LowPowerMonitorDeviceStub.xml
+vendor/etc/permissions/PowerAnomalyDataModemInterface.xml
+vendor/etc/permissions/PowerAnomalyStub.xml
+vendor/etc/permissions/embms.xml
+vendor/etc/permissions/qcrilhook.xml
+vendor/etc/permissions/qti_permissions.xml
+vendor/etc/permissions/qti-vzw-ims-internal.xml
+vendor/etc/permissions/rcsservice.xml
+vendor/etc/permissions/telephonyservice.xml
+vendor/etc/public.libraries.txt
+vendor/etc/qdcm_calib_data_M1_WQHD_SAMSUNG_S6E3HA3_5.5_command_mode_panel.xml
+vendor/etc/qfipsverify/bootimg.hmac
+vendor/etc/qfipsverify/qfipsverify.hmac
+vendor/etc/sap.conf
+vendor/firmware/a530_gpmu.fw2
+vendor/firmware/a530_pfp.fw
+vendor/firmware/a530_pm4.fw
+vendor/firmware/a530rnd.fw
+vendor/firmware/a530v3_gpmu.fw2
+vendor/firmware/a530v3_seq.fw2
+vendor/firmware/a530_zap.b00
+vendor/firmware/a530_zap.b01
+vendor/firmware/a530_zap.b02
+vendor/firmware/a530_zap.elf
+vendor/firmware/a530_zap.mdt
+vendor/firmware/a530_zap_signed.b00
+vendor/firmware/a530_zap_signed.b01
+vendor/firmware/a530_zap_signed.b02
+vendor/firmware/a530_zap_signed.elf
+vendor/firmware/a530_zap_signed.mbn
+vendor/firmware/a530_zap_signed.mdt
+vendor/firmware/activity.napp
+vendor/firmware/adsp.b00
+vendor/firmware/adsp.b01
+vendor/firmware/adsp.b02
+vendor/firmware/adsp.b03
+vendor/firmware/adsp.b04
+vendor/firmware/adsp.b05
+vendor/firmware/adsp.b06
+vendor/firmware/adsp.b08
+vendor/firmware/adsp.b09
+vendor/firmware/adsp.mdt
+vendor/firmware/adspver.cfg
+vendor/firmware/bdwlan30.b80
+vendor/firmware/bdwlan30.b81
+vendor/firmware/bdwlan30.b82
+vendor/firmware/bdwlan30.bin
+vendor/firmware/btfw32.tlv
+vendor/firmware/btnv32.bin
+vendor/firmware/cmnlib64.b00
+vendor/firmware/cmnlib64.b01
+vendor/firmware/cmnlib64.b02
+vendor/firmware/cmnlib64.b03
+vendor/firmware/cmnlib64.b04
+vendor/firmware/cmnlib64.b05
+vendor/firmware/cmnlib64.mdt
+vendor/firmware/cmnlib.b00
+vendor/firmware/cmnlib.b01
+vendor/firmware/cmnlib.b02
+vendor/firmware/cmnlib.b03
+vendor/firmware/cmnlib.b04
+vendor/firmware/cmnlib.b05
+vendor/firmware/cmnlib.mdt
+vendor/firmware/cpe_9335.b08
+vendor/firmware/cpe_9335.b09
+vendor/firmware/cpe_9335.b11
+vendor/firmware/cpe_9335.b14
+vendor/firmware/cpe_9335.b16
+vendor/firmware/cpe_9335.b18
+vendor/firmware/cpe_9335.b19
+vendor/firmware/cpe_9335.b20
+vendor/firmware/cpe_9335.b22
+vendor/firmware/cpe_9335.b24
+vendor/firmware/cpe_9335.b26
+vendor/firmware/cpe_9335.b28
+vendor/firmware/cpe_9335.b29
+vendor/firmware/cpe_9335.mdt
+vendor/firmware/cppf.b00
+vendor/firmware/cppf.b01
+vendor/firmware/cppf.b02
+vendor/firmware/cppf.b03
+vendor/firmware/cppf.b04
+vendor/firmware/cppf.b05
+vendor/firmware/cppf.b06
+vendor/firmware/cpp_firmware_v1_10_0.fw
+vendor/firmware/cpp_firmware_v1_1_1.fw
+vendor/firmware/cpp_firmware_v1_1_6.fw
+vendor/firmware/cpp_firmware_v1_2_0.fw
+vendor/firmware/cpp_firmware_v1_4_0.fw
+vendor/firmware/cpp_firmware_v1_5_0.fw
+vendor/firmware/cpp_firmware_v1_5_2.fw
+vendor/firmware/cpp_firmware_v1_6_0.fw
+vendor/firmware/cpp_firmware_v1_8_0.fw
+vendor/firmware/cppf.mdt
+vendor/firmware/Data.msc
+vendor/firmware/double_twist.napp
+vendor/firmware/fpctzappfingerprint.b00
+vendor/firmware/fpctzappfingerprint.b01
+vendor/firmware/fpctzappfingerprint.b02
+vendor/firmware/fpctzappfingerprint.b03
+vendor/firmware/fpctzappfingerprint.b04
+vendor/firmware/fpctzappfingerprint.b05
+vendor/firmware/fpctzappfingerprint.b06
+vendor/firmware/fpctzappfingerprint.mdt
+vendor/firmware/geofence.napp
+vendor/firmware/hotsound.sound_model
+vendor/firmware/nanohub.full.bin
+vendor/firmware/napp_list.cfg
+vendor/firmware/otp30.bin
+vendor/firmware/pickup_gesture.napp
+vendor/firmware/qwlan30.bin
+vendor/firmware/sig_motion.napp
+vendor/firmware/slpi.b00
+vendor/firmware/slpi.b01
+vendor/firmware/slpi.b02
+vendor/firmware/slpi.b03
+vendor/firmware/slpi.b04
+vendor/firmware/slpi.b05
+vendor/firmware/slpi.b06
+vendor/firmware/slpi.b07
+vendor/firmware/slpi.b08
+vendor/firmware/slpi.b09
+vendor/firmware/slpi.b10
+vendor/firmware/slpi.b11
+vendor/firmware/slpi.b12
+vendor/firmware/slpi.b13
+vendor/firmware/slpi.b14
+vendor/firmware/slpi.mdt
+vendor/firmware/slpiver.cfg
+vendor/firmware/synaptics_bl71.img
+vendor/firmware/synaptics_bl77.img
+vendor/firmware/tfa98xx.cnt
+vendor/firmware/utf30.bin
+vendor/firmware/venus.b00
+vendor/firmware/venus.b01
+vendor/firmware/venus.b02
+vendor/firmware/venus.b03
+vendor/firmware/venus.b04
+vendor/firmware/venus.flist
+vendor/firmware/venus.mbn
+vendor/firmware/venus.mdt
+vendor/firmware/widevine.b00
+vendor/firmware/widevine.b01
+vendor/firmware/widevine.b02
+vendor/firmware/widevine.b03
+vendor/firmware/widevine.b04
+vendor/firmware/widevine.b05
+vendor/firmware/widevine.b06
+vendor/firmware/widevine.mdt
+-vendor/framework/embmslibrary.jar
+-vendor/framework/QtiTelephonyServicelibrary.jar
+-vendor/framework/qti-vzw-ims-internal.jar
+-vendor/framework/rcsservice.jar
+vendor/lib64/egl/eglSubDriverAndroid.so
+vendor/lib64/egl/libEGL_adreno.so
+vendor/lib64/egl/libGLESv1_CM_adreno.so
+vendor/lib64/egl/libGLESv2_adreno.so
+vendor/lib64/egl/libq3dtools_adreno.so
+vendor/lib64/egl/libq3dtools_esx.so
+vendor/lib64/hw/android.hardware.bluetooth@1.0-impl-qti.so
+vendor/lib64/hw/fingerprint.marlin.so
+vendor/lib64/hw/flp.default.so
+vendor/lib64/hw/gatekeeper.msm8996.so
+vendor/lib64/hw/gps.default.so
+vendor/lib64/hw/keystore.msm8996.so
+vendor/lib64/hw/vulkan.msm8996.so
+vendor/lib64/libacdb-fts.so
+vendor/lib64/libacdbloader.so
+vendor/lib64/libacdbmapper.so
+vendor/lib64/libacdbrtac.so
+vendor/lib64/libadiertac.so
+vendor/lib64/libadreno_utils.so
+vendor/lib64/libadsp_default_listener.so
+vendor/lib64/libadsprpc.so
+vendor/lib64/libaudcal.so
+vendor/lib64/libaudioalsa.so
+vendor/lib64/libbccQTI.so
+vendor/lib64/libbtnv.so
+vendor/lib64/libC2D2.so
+vendor/lib64/libc2d30-a3xx.so
+vendor/lib64/libc2d30-a4xx.so
+vendor/lib64/libc2d30-a5xx.so
+vendor/lib64/libc2d30_bltlib.so
+vendor/lib64/libCB.so
+vendor/lib64/libcneapiclient.so
+vendor/lib64/libcne.so
+vendor/lib64/libconfigdb.so
+vendor/lib64/libdiag.so
+vendor/lib64/libdisp-aba.so
+vendor/lib64/lib-dplmedia.so
+vendor/lib64/libdrmfs.so
+vendor/lib64/libdrmtime.so
+vendor/lib64/libdsi_netctrl.so
+vendor/lib64/libdsutils.so
+vendor/lib64/libfastcvadsp_stub.so
+vendor/lib64/libfastcvopt.so
+vendor/lib64/libflp.so
+vendor/lib64/lib_fpc_tac_shared.so
+vendor/lib64/libgeofence.so
+vendor/lib64/libGPreqcancel.so
+vendor/lib64/libGPreqcancel_svc.so
+vendor/lib64/libgps.utils.so
+vendor/lib64/libGPTEE.so
+vendor/lib64/libgsl.so
+vendor/lib64/libhdcp1prov.so
+vendor/lib64/libidl.so
+vendor/lib64/lib-imsdpl.so
+vendor/lib64/lib-imsqimf.so
+vendor/lib64/lib-imsrcs.so
+vendor/lib64/lib-imsSDP.so
+vendor/lib64/lib-imsxml.so
+vendor/lib64/libizat_core.so
+vendor/lib64/liblbs_core.so
+vendor/lib64/libllvm-glnext.so
+vendor/lib64/libllvm-qcom.so
+vendor/lib64/libloc_api_v02.so
+vendor/lib64/libloc_core.so
+vendor/lib64/libloc_ds_api.so
+vendor/lib64/libloc_eng.so
+vendor/lib64/liblowi_client.so
+vendor/lib64/liblowi_wifihal.so
+vendor/lib64/liblqe.so
+vendor/lib64/libmdmdetect.so
+vendor/lib64/libmdmimgload.so
+vendor/lib64/libmdsprpc.so
+vendor/lib64/libmmcamera_dbg.so
+vendor/lib64/libmm-disp-apis.so
+vendor/lib64/libmm-hdcpmgr.so
+vendor/lib64/libmm-qdcm.so
+vendor/lib64/libnetmgr.so
+vendor/lib64/libperipheral_client.so
+vendor/lib64/libpvr.so
+vendor/lib64/libqcci_legacy.so
+vendor/lib64/libqcmaputils.so
+vendor/lib64/libqdi.so
+vendor/lib64/libqdp.so
+vendor/lib64/libqisl.so
+vendor/lib64/libqmi_cci.so
+vendor/lib64/libqmi_client_helper.so
+vendor/lib64/libqmi_client_qmux.so
+vendor/lib64/libqmi_common_so.so
+vendor/lib64/libqmi_csi.so
+vendor/lib64/libqmi_encdec.so
+vendor/lib64/libqmiservices_ext.so
+vendor/lib64/libqmiservices_htc.so
+vendor/lib64/libqmiservices.so
+vendor/lib64/libqmi.so
+vendor/lib64/libQSEEComAPI.so
+vendor/lib64/libqti-perfd-client.so
+vendor/lib64/libquipc_os_api.so
+vendor/lib64/lib-rcsjni.so
+vendor/lib64/libril-qc-qmi-1.so
+vendor/lib64/libril-qc-radioconfig.so
+vendor/lib64/libril-qcril-hook-oem.so
+vendor/lib64/librilqmiservices.so
+vendor/lib64/librmp.so
+vendor/lib64/librpmb.so
+vendor/lib64/librs_adreno_sha1.so
+vendor/lib64/librs_adreno.so
+vendor/lib64/libRSDriver_adreno.so
+vendor/lib64/lib-rtpcommon.so
+vendor/lib64/lib-rtpcore.so
+vendor/lib64/lib-rtpdaemoninterface.so
+vendor/lib64/lib-rtpsl.so
+vendor/lib64/libSampleAuthJNI.so
+vendor/lib64/libSampleExtAuthJNI.so
+vendor/lib64/libscalar.so
+vendor/lib64/libscale.so
+vendor/lib64/libsdm-color.so
+vendor/lib64/libsdm-diag.so
+vendor/lib64/libsdm-disp-apis.so
+vendor/lib64/libsdmextension.so
+vendor/lib64/libsd_sdk_display.so
+vendor/lib64/libsdsprpc.so
+vendor/lib64/lib-sec-disp.so
+vendor/lib64/libSecureExtAuthJNI.so
+vendor/lib64/libSecureSampleAuthJNI.so
+vendor/lib64/libSecureUILib.so
+vendor/lib64/libsecureui.so
+vendor/lib64/libsecureuisvc_jni.so
+vendor/lib64/libsecureui_svcsock.so
+vendor/lib64/libsi.so
+vendor/lib64/libsmemlog.so
+vendor/lib64/libssd.so
+vendor/lib64/libStDrvInt.so
+vendor/lib64/libsystem_health_mon.so
+vendor/lib64/libthermalclient.so
+vendor/lib64/libthermalioctl.so
+vendor/lib64/libtime_genoff.so
+vendor/lib64/libTimeService.so
+vendor/lib64/libtzdrmgenprov.so
+vendor/lib64/libwms.so
+vendor/lib64/libxml.so
+vendor/lib/dsp/EtsiEaacPlusEncAndCmnModule.so.1
+vendor/lib/dsp/fastrpc_shell_0
+vendor/lib/dsp/fluence_voiceplus_module.so.1
+vendor/lib/dsp/HeaacDecoderModule.so.1
+vendor/lib/dsp/libsysmon_skel.so
+vendor/lib/dsp/map_avs_shared_libs.txt
+vendor/lib/dsp/map_SHARED_LIBS_AAAAAAAAQ.txt
+vendor/lib/dsp/mmecns_module.so.1
+vendor/lib/dsp/SAPlusCmnModule.so.1
+vendor/lib/egl/eglSubDriverAndroid.so
+vendor/lib/egl/libEGL_adreno.so
+vendor/lib/egl/libGLESv1_CM_adreno.so
+vendor/lib/egl/libGLESv2_adreno.so
+vendor/lib/egl/libq3dtools_adreno.so
+vendor/lib/egl/libq3dtools_esx.so
+vendor/lib/hw/audio.primary.msm8996.so
+vendor/lib/hw/flp.default.so
+vendor/lib/hw/gatekeeper.msm8996.so
+vendor/lib/hw/gps.default.so
+vendor/lib/hw/keystore.msm8996.so
+vendor/lib/hw/sensors.vl530l0.tof.so
+vendor/lib/hw/sound_trigger.primary.msm8996.so
+vendor/lib/hw/vulkan.msm8996.so
+vendor/lib/libacdb-fts.so
+vendor/lib/libacdbloader.so
+vendor/lib/libacdbmapper.so
+vendor/lib/libacdbrtac.so
+vendor/lib/libactuator_lc898212xd_htc.so
+vendor/lib/libadiertac.so
+vendor/lib/libadm.so
+vendor/lib/libadpcmdec.so
+vendor/lib/libadreno_utils.so
+vendor/lib/libadsp_default_listener.so
+vendor/lib/libadsprpc.so
+vendor/lib/libaudcal.so
+vendor/lib/libaudioalsa.so
+vendor/lib/libbccQTI.so
+vendor/lib/libC2D2.so
+vendor/lib/libc2d30-a3xx.so
+vendor/lib/libc2d30-a4xx.so
+vendor/lib/libc2d30-a5xx.so
+vendor/lib/libc2d30_bltlib.so
+vendor/lib/libCB.so
+vendor/lib/libchromatix_imx179_common.so
+vendor/lib/libchromatix_imx179_postproc.so
+vendor/lib/libchromatix_imx179_video_16_9_3a.so
+vendor/lib/libchromatix_imx179_video_16_9_cpp.so
+vendor/lib/libchromatix_imx179_video_16_9_isp.so
+vendor/lib/libchromatix_imx179_video_qtr_16_9_3a.so
+vendor/lib/libchromatix_imx179_video_qtr_16_9_cpp.so
+vendor/lib/libchromatix_imx179_video_qtr_16_9_isp.so
+vendor/lib/libchromatix_imx179_zsl_snapshot_3a.so
+vendor/lib/libchromatix_imx179_zsl_snapshot_cpp.so
+vendor/lib/libchromatix_imx179_zsl_snapshot_isp.so
+vendor/lib/libchromatix_imx378_common.so
+vendor/lib/libchromatix_imx378_postproc.so
+vendor/lib/libchromatix_imx378_video_16_9_3a.so
+vendor/lib/libchromatix_imx378_video_16_9_cpp.so
+vendor/lib/libchromatix_imx378_video_16_9_isp.so
+vendor/lib/libchromatix_imx378_video_hfr_120_3a.so
+vendor/lib/libchromatix_imx378_video_hfr_120_cpp.so
+vendor/lib/libchromatix_imx378_video_hfr_120_isp.so
+vendor/lib/libchromatix_imx378_video_hfr_240_3a.so
+vendor/lib/libchromatix_imx378_video_hfr_240_cpp.so
+vendor/lib/libchromatix_imx378_video_hfr_240_isp.so
+vendor/lib/libchromatix_imx378_video_hfr_60_3a.so
+vendor/lib/libchromatix_imx378_video_hfr_60_cpp.so
+vendor/lib/libchromatix_imx378_video_hfr_60_isp.so
+vendor/lib/libchromatix_imx378_zsl_snapshot_3a.so
+vendor/lib/libchromatix_imx378_zsl_snapshot_cpp.so
+vendor/lib/libchromatix_imx378_zsl_snapshot_isp.so
+vendor/lib/libcneapiclient.so
+vendor/lib/libcne.so
+vendor/lib/libconfigdb.so
+vendor/lib/libcppf.so
+vendor/lib/libdiag.so
+vendor/lib/libdisp-aba.so
+vendor/lib/lib-dplmedia.so
+vendor/lib/libdrmfs.so
+vendor/lib/libdrmtime.so
+vendor/lib/libdsi_netctrl.so
+vendor/lib/libdsutils.so
+vendor/lib/libeglc2d.so
+vendor/lib/libfastcvadsp_stub.so
+vendor/lib/libfastcvopt.so
+vendor/lib/libflash_pmic.so
+vendor/lib/libflp.so
+vendor/lib/libgcam_ae.so
+vendor/lib/libgeofence.so
+vendor/lib/libgoog_eis_armeabi-v7a.so
+vendor/lib/libGPreqcancel.so
+vendor/lib/libGPreqcancel_svc.so
+vendor/lib/libgps.utils.so
+vendor/lib/libGPTEE.so
+vendor/lib/libgsl.so
+vendor/lib/libhdcp1prov.so
+vendor/lib/libidl.so
+vendor/lib/lib-imsdpl.so
+vendor/lib/lib-imsrcs.so
+vendor/lib/libizat_core.so
+vendor/lib/libjpegdhw.so
+vendor/lib/libjpegdmahw.so
+vendor/lib/libjpegehw.so
+vendor/lib/liblbs_core.so
+vendor/lib/libllvd_smore.so
+vendor/lib/libllvm-glnext.so
+vendor/lib/libllvm-qcom.so
+vendor/lib/libloc_api_v02.so
+vendor/lib/libloc_core.so
+vendor/lib/libloc_ds_api.so
+vendor/lib/libloc_eng.so
+vendor/lib/liblowi_client.so
+vendor/lib/libmdmdetect.so
+vendor/lib/libmdsprpc.so
+vendor/lib/libmmcamera2_c2d_module.so
+vendor/lib/libmmcamera2_cpp_module.so
+vendor/lib/libmmcamera2_frame_algorithm.so
+vendor/lib/libmmcamera2_iface_modules.so
+vendor/lib/libmmcamera2_imglib_modules.so
+vendor/lib/libmmcamera2_isp_modules.so
+vendor/lib/libmmcamera2_is.so
+vendor/lib/libmmcamera2_mct_shimlayer.so
+vendor/lib/libmmcamera2_mct.so
+vendor/lib/libmmcamera2_memleak.so
+vendor/lib/libmmcamera2_pp_buf_mgr.so
+vendor/lib/libmmcamera2_pproc_modules.so
+vendor/lib/libmmcamera2_q3a_core.so
+vendor/lib/libmmcamera2_sensor_modules.so
+vendor/lib/libmmcamera2_stats_algorithm.so
+vendor/lib/libmmcamera2_stats_modules.so
+vendor/lib/libmmcamera_dbg.so
+vendor/lib/libmmcamera_eeprom_util.so
+vendor/lib/libmmcamera_eztune_module.so
+vendor/lib/libmmcamera_facedetection_lib.so
+vendor/lib/libmmcamera_faceproc2.so
+vendor/lib/libmmcamera_faceproc.so
+vendor/lib/libmmcamera_imglib.so
+vendor/lib/libmmcamera_imx179_htc.so
+vendor/lib/libmmcamera_imx378_htc.so
+vendor/lib/libmmcamera_isp_abf47.so
+vendor/lib/libmmcamera_isp_aec_bg_stats47.so
+vendor/lib/libmmcamera_isp_bf_stats47.so
+vendor/lib/libmmcamera_isp_bg_stats46.so
+vendor/lib/libmmcamera_isp_bhist_stats44.so
+vendor/lib/libmmcamera_isp_black_level47.so
+vendor/lib/libmmcamera_isp_bpc47.so
+vendor/lib/libmmcamera_isp_cac47.so
+vendor/lib/libmmcamera_isp_chroma_enhan40.so
+vendor/lib/libmmcamera_isp_chroma_suppress40.so
+vendor/lib/libmmcamera_isp_clamp_encoder40.so
+vendor/lib/libmmcamera_isp_clamp_video40.so
+vendor/lib/libmmcamera_isp_clamp_viewfinder40.so
+vendor/lib/libmmcamera_isp_color_correct46.so
+vendor/lib/libmmcamera_isp_color_xform_encoder46.so
+vendor/lib/libmmcamera_isp_color_xform_video46.so
+vendor/lib/libmmcamera_isp_color_xform_viewfinder46.so
+vendor/lib/libmmcamera_isp_cs_stats46.so
+vendor/lib/libmmcamera_isp_demosaic47.so
+vendor/lib/libmmcamera_isp_demux40.so
+vendor/lib/libmmcamera_isp_fovcrop_encoder46.so
+vendor/lib/libmmcamera_isp_fovcrop_video46.so
+vendor/lib/libmmcamera_isp_fovcrop_viewfinder46.so
+vendor/lib/libmmcamera_isp_gamma44.so
+vendor/lib/libmmcamera_isp_gic46.so
+vendor/lib/libmmcamera_isp_gtm46.so
+vendor/lib/libmmcamera_isp_hdr46.so
+vendor/lib/libmmcamera_isp_hdr_be_stats46.so
+vendor/lib/libmmcamera_isp_ihist_stats46.so
+vendor/lib/libmmcamera_isp_linearization40.so
+vendor/lib/libmmcamera_isp_ltm47.so
+vendor/lib/libmmcamera_isp_mce40.so
+vendor/lib/libmmcamera_isp_mesh_rolloff44.so
+vendor/lib/libmmcamera_isp_pedestal_correct46.so
+vendor/lib/libmmcamera_isp_rs_stats46.so
+vendor/lib/libmmcamera_isp_scaler_encoder46.so
+vendor/lib/libmmcamera_isp_scaler_video46.so
+vendor/lib/libmmcamera_isp_scaler_viewfinder46.so
+vendor/lib/libmmcamera_isp_sce40.so
+vendor/lib/libmmcamera_isp_snr47.so
+vendor/lib/libmmcamera_isp_sub_module.so
+vendor/lib/libmmcamera_llvd.so
+vendor/lib/libmmcamera_paaf_lib.so
+vendor/lib/libmmcamera_pdafcamif.so
+vendor/lib/libmmcamera_pdaf.so
+vendor/lib/libmmcamera_ppbase_module.so
+vendor/lib/libmmcamera_sony_imx179_eeprom.so
+vendor/lib/libmmcamera_sony_imx378_eeprom.so
+vendor/lib/libmmcamera_thread_services.so
+vendor/lib/libmmcamera_tintless_algo.so
+vendor/lib/libmmcamera_tintless_bg_pca_algo.so
+vendor/lib/libmmcamera_tuning_lookup.so
+vendor/lib/libmmcamera_tuning.so
+vendor/lib/libmm-disp-apis.so
+vendor/lib/libmm-hdcpmgr.so
+vendor/lib/libmmjpeg.so
+vendor/lib/libmm-qdcm.so
+vendor/lib/libmmqjpeg_codec.so
+vendor/lib/libmmqjpegdma.so
+vendor/lib/libnetmgr.so
+vendor/lib/liboemcrypto.so
+vendor/lib/libperipheral_client.so
+vendor/lib/libpvr.so
+vendor/lib/libqcci_legacy.so
+vendor/lib/libqcmaputils.so
+vendor/lib/libqdi.so
+vendor/lib/libqisl.so
+vendor/lib/libqmi_cci.so
+vendor/lib/libqmi_client_helper.so
+vendor/lib/libqmi_client_qmux.so
+vendor/lib/libqmi_common_so.so
+vendor/lib/libqmi_csi.so
+vendor/lib/libqmi_encdec.so
+vendor/lib/libqmiservices_ext.so
+vendor/lib/libqmiservices.so
+vendor/lib/libqmi.so
+vendor/lib/libqomx_jpegdec.so
+vendor/lib/libqomx_jpegenc_pipe.so
+vendor/lib/libqomx_jpegenc.so
+vendor/lib/libQSEEComAPI.so
+vendor/lib/libqti-perfd-client.so
+vendor/lib/libquipc_os_api.so
+vendor/lib/lib-rcsjni.so
+vendor/lib/libril-qcril-hook-oem.so
+vendor/lib/librmp.so
+vendor/lib/librpmb.so
+vendor/lib/librs_adreno_sha1.so
+vendor/lib/librs_adreno.so
+vendor/lib/libRSDriver_adreno.so
+vendor/lib/lib-rtpcommon.so
+vendor/lib/lib-rtpcore.so
+vendor/lib/lib-rtpdaemoninterface.so
+vendor/lib/lib-rtpsl.so
+vendor/lib/libSampleAuthJNI.so
+vendor/lib/libSampleExtAuthJNI.so
+vendor/lib/libscale.so
+vendor/lib/libsdm-disp-apis.so
+vendor/lib/libsd_sdk_display.so
+vendor/lib/libsdsprpc.so
+vendor/lib/lib-sec-disp.so
+vendor/lib/libSecureExtAuthJNI.so
+vendor/lib/libSecureSampleAuthJNI.so
+vendor/lib/libSecureUILib.so
+vendor/lib/libsecureui.so
+vendor/lib/libsecureuisvc_jni.so
+vendor/lib/libsecureui_svcsock.so
+vendor/lib/libseemore.so
+vendor/lib/libsi.so
+vendor/lib/libsmemlog.so
+vendor/lib/libSonyIMX378PdafLibrary.so
+vendor/lib/libssd.so
+vendor/lib/libStDrvInt.so
+vendor/lib/libsystem_health_mon.so
+vendor/lib/libthermalclient.so
+vendor/lib/libtime_genoff.so
+vendor/lib/libTimeService.so
+vendor/lib/libtm_interface.so
+vendor/lib/libtzdrmgenprov.so
+vendor/lib/libwms.so
+vendor/lib/libwvhidl.so
+vendor/lib/libxml.so
+vendor/lib/rfsa/adsp/chre_drv_loc.so
+vendor/lib/rfsa/adsp/chre_drv_modem.so
+vendor/lib/rfsa/adsp/chre_drv_wifi.so
+vendor/lib/rfsa/adsp/chre_platform.so
+vendor/lib/rfsa/adsp/chre.so
+vendor/lib/rfsa/adsp/libnanohub_slpi_skel.so
+vendor/lib/rfsa/adsp/libseemore_hexagon_skel.so
+vendor/lib/rfsa/adsp/lowi_client.so
+vendor/lib/rfsa/adsp/nano_bridge.so
+vendor/lib/soundfx/libfmas.so
+vendor/lib/test_suite_all_modules.so
+vendor/lib/test_suite_no_sensor.so
+vendor/lib/test_suite_pproc.so
+vendor/lib/test_suite_vfe.so
+vendor/media/LMspeed_508.emd
+vendor/media/PFFprec_600.emd
+vendor/qcril_database/upgrade/1_version_intro.sql
+vendor/qcril_database/upgrade/2_db_upgrade.sql
+vendor/qcril_database/upgrade/3_remove_ecc_999_from_us_and_canada.sql
+vendor/qcril_database/upgrade/4_db_upgrade.sql
+vendor/qcril_database/upgrade/5_update_india_ecc.sql
+vendor/qcril.db
diff --git a/device-proprietary-files.txt b/marlin/device-proprietary-files.txt
similarity index 73%
rename from device-proprietary-files.txt
rename to marlin/device-proprietary-files.txt
index 7eb1bc863..b802d082b 100644
--- a/device-proprietary-files.txt
+++ b/marlin/device-proprietary-files.txt
@@ -13,6 +13,9 @@ etc/cne/Nexus/ATT/ATT_profiles.xml
etc/cne/Nexus/ROW/ROW_profiles.xml
etc/cne/Nexus/VZW/VZW_profiles.xml
+# DRM
+bin/move_widevine_data.sh
+
# Hotword Enrollment
-priv-app/HotwordEnrollmentOKGoogleWCD9335/HotwordEnrollmentOKGoogleWCD9335.apk;PRESIGNED
-priv-app/HotwordEnrollmentTGoogleWCD9335/HotwordEnrollmentTGoogleWCD9335.apk;PRESIGNED
@@ -38,13 +41,24 @@ lib/librcc.so
etc/permissions/privapp-permissions-google.xml
# RIL
+-framework/LowPowerMonitorDeviceInterface.jar
+-framework/LowPowerMonitorDeviceStub.jar
+-framework/PowerAnomalyDataModemInterface.jar
+-framework/PowerAnomalyStub.jar
-framework/qcrilhook.jar
+-priv-app/Asdiv/Asdiv.apk
-priv-app/qcrilmsgtunnel/qcrilmsgtunnel.apk
lib64/vendor.qti.atcmdfwd@1.0.so
lib64/vendor.qti.qcril.am@1.0.so
# Sprint
+etc/permissions/com.android.omadm.service.xml
etc/permissions/com.android.sdm.plugins.sprintdm.xml
+etc/sysconfig/whitelist_com.android.omadm.service.xml
+lib/libdmengine.so
+lib/libdmjavaplugin.so
+-priv-app/DMService/DMService.apk
+-priv-app/DiagMon/DiagMon.apk
-priv-app/SprintDM/SprintDM.apk
-priv-app/SprintHM/SprintHM.apk
@@ -54,18 +68,25 @@ etc/sysconfig/pixel_2016_exclusive.xml
# VZW
-app/VZWAPNLib/VZWAPNLib.apk;PRESIGNED
+etc/permissions/com.android.sdm.plugins.connmo.xml
etc/permissions/com.android.vzwomatrigger.xml
etc/permissions/com.verizon.apn.xml
etc/permissions/com.verizon.embms.xml
-etc/permissions/com.verizon.llkagent.xml
etc/permissions/com.verizon.provider.xml
etc/permissions/com.verizon.services.xml
etc/permissions/features-verizon.xml
+etc/permissions/obdm_permissions.xml
etc/permissions/vzw_mvs_permissions.xml
-framework/VerizonUnifiedSettings.jar;PRESIGNED
+-priv-app/CarrierSetup/CarrierSetup.apk
+-priv-app/ConnMO/ConnMO.apk
+-priv-app/DCMO/DCMO.apk
priv-app/MyVerizonServices/lib/arm64/libakuaf.so
priv-app/MyVerizonServices/lib/arm64/libmotricity.so
-priv-app/MyVerizonServices/MyVerizonServices.apk;PRESIGNED
+-priv-app/OBDM_Permissions/OBDM_Permissions.apk
+-priv-app/OemDmTrigger/OemDmTrigger.apk
-priv-app/VerizonAuthDialog/VerizonAuthDialog.apk;PRESIGNED
-priv-app/VzwOmaTrigger/VzwOmaTrigger.apk;PRESIGNED
-priv-app/WfcActivation/WfcActivation.apk;PRESIGNED
+-priv-app/obdm_stub/obdm_stub.apk;PRESIGNED
diff --git a/marlin/extract-files.sh b/marlin/extract-files.sh
new file mode 100755
index 000000000..d3f3ea93a
--- /dev/null
+++ b/marlin/extract-files.sh
@@ -0,0 +1,61 @@
+#!/bin/bash
+#
+# Copyright (C) 2017-2019 The LineageOS Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -e
+
+VENDOR=google
+DEVICE=marlin
+
+# Load extractutils and do some sanity checks
+MY_DIR="${BASH_SOURCE%/*}"
+if [[ ! -d "$MY_DIR" ]]; then MY_DIR="$PWD"; fi
+
+LINEAGE_ROOT="$MY_DIR"/../../..
+
+HELPER="$LINEAGE_ROOT"/vendor/lineage/build/tools/extract_utils.sh
+if [ ! -f "$HELPER" ]; then
+ echo "Unable to find helper script at $HELPER"
+ exit 1
+fi
+. "$HELPER"
+
+if [ $# -eq 0 ]; then
+ SRC=adb
+else
+ if [ $# -eq 1 ]; then
+ SRC=$1
+ else
+ echo "$0: bad number of arguments"
+ echo ""
+ echo "usage: $0 [PATH_TO_EXPANDED_ROM]"
+ echo ""
+ echo "If PATH_TO_EXPANDED_ROM is not specified, blobs will be extracted from"
+ echo "the device using adb pull."
+ exit 1
+ fi
+fi
+
+# Initialize the helper
+setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT"
+
+extract "$MY_DIR/$DEVICE"/device-proprietary-files.txt "$SRC"
+extract "$MY_DIR/$DEVICE"/device-proprietary-files-vendor.txt "$SRC"
+
+# Don't disable MyVerizonServices app
+sed -i 's|||g'\
+ "$LINEAGE_ROOT"/vendor/"$VENDOR"/"$DEVICE"/proprietary/etc/sysconfig/nexus.xml
+
+"$MY_DIR/$DEVICE"/setup-makefiles.sh
diff --git a/setup-makefiles.sh b/marlin/setup-makefiles.sh
similarity index 70%
rename from setup-makefiles.sh
rename to marlin/setup-makefiles.sh
index 1e39ca8a6..1a3385f60 100755
--- a/setup-makefiles.sh
+++ b/marlin/setup-makefiles.sh
@@ -1,6 +1,6 @@
#!/bin/bash
#
-# Copyright (C) 2017-2018 The LineageOS Project
+# Copyright (C) 2017-2019 The LineageOS Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -25,7 +25,7 @@ INITIAL_COPYRIGHT_YEAR=2017
MY_DIR="${BASH_SOURCE%/*}"
if [[ ! -d "$MY_DIR" ]]; then MY_DIR="$PWD"; fi
-LINEAGE_ROOT="$MY_DIR"/../../..
+LINEAGE_ROOT="$MY_DIR"/../../../..
HELPER="$LINEAGE_ROOT"/vendor/lineage/build/tools/extract_utils.sh
if [ ! -f "$HELPER" ]; then
@@ -34,35 +34,15 @@ if [ ! -f "$HELPER" ]; then
fi
. "$HELPER"
-# Write custom header to allow sailfish to inherit
-function write_marlin_headers() {
- write_header "$ANDROIDMK"
-
- cat << EOF >> "$ANDROIDMK"
-LOCAL_PATH := \$(call my-dir)
-
-EOF
- cat << EOF >> "$ANDROIDMK"
-ifneq (\$(filter marlin sailfish,\$(TARGET_DEVICE)),)
-
-EOF
-
- write_header "$BOARDMK"
- write_header "$PRODUCTMK"
-}
-
# Initialize the helper
setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT"
# Copyright headers and guards
-write_marlin_headers
+write_headers
# The standard blobs
write_makefiles "$MY_DIR"/device-proprietary-files.txt
-
-cat << EOF >> "$ANDROIDMK"
-
-EOF
+write_makefiles "$MY_DIR"/device-proprietary-files-vendor.txt true
# Finish
write_footers
diff --git a/sailfish/BoardConfig.mk b/sailfish/BoardConfig.mk
index 49ac98d9e..9af4cdd38 100644
--- a/sailfish/BoardConfig.mk
+++ b/sailfish/BoardConfig.mk
@@ -101,7 +101,7 @@ BOARD_ROOT_EXTRA_FOLDERS := firmware firmware/radio persist
BOARD_ROOT_EXTRA_SYMLINKS := /vendor/lib/dsp:/dsp
BOARD_SEPOLICY_DIRS += device/google/marlin/sepolicy
-ifneq ($(filter sailfish sailfishf, $(TARGET_PRODUCT)),)
+ifneq ($(filter lineage_sailfish sailfish sailfishf, $(TARGET_PRODUCT)),)
BOARD_SEPOLICY_DIRS += device/google/marlin/sepolicy/verizon
endif
BOARD_PLAT_PUBLIC_SEPOLICY_DIR := device/google/marlin/sepolicy/public
diff --git a/sailfish/BoardConfigLineage.mk b/sailfish/BoardConfigLineage.mk
index 5543f1ac8..124fc7a04 100644
--- a/sailfish/BoardConfigLineage.mk
+++ b/sailfish/BoardConfigLineage.mk
@@ -1,2 +1,4 @@
# BoardConfig for lineage_sailfish
include device/google/marlin/BoardConfigLineage.mk
+
+-include vendor/google/sailfish/BoardConfigVendor.mk
diff --git a/sailfish/device-proprietary-files-vendor.txt b/sailfish/device-proprietary-files-vendor.txt
new file mode 100644
index 000000000..96ee41f33
--- /dev/null
+++ b/sailfish/device-proprietary-files-vendor.txt
@@ -0,0 +1,676 @@
+-vendor/app/atfwd/atfwd.apk
+-vendor/app/colorservice/colorservice.apk
+-vendor/app/datastatusnotification/datastatusnotification.apk
+-vendor/app/embms/embms.apk
+vendor/app/embms/oem/config_params.xml
+vendor/app/embms/oem/provisioning_params.xml
+vendor/app/embms/oem/verizon_config_params.txt
+-vendor/app/fastdormancy/fastdormancy.apk
+-vendor/app/imssettings/imssettings.apk
+-vendor/app/QAS_DVC_MSP/QAS_DVC_MSP.apk
+-vendor/app/QtiTelephonyService/QtiTelephonyService.apk
+-vendor/app/radioconfig/radioconfig.apk
+-vendor/app/RCSBootstraputil/RCSBootstraputil.apk
+-vendor/app/SecureExtAuthService/SecureExtAuthService.apk
+-vendor/app/shutdownlistener/shutdownlistener.apk
+-vendor/app/TimeService/TimeService.apk
+-vendor/app/vzw_msdc_api/vzw_msdc_api.apk
+vendor/bin/adsprpcd
+vendor/bin/ATFWD-daemon
+vendor/bin/athdiag
+vendor/bin/cnd
+vendor/bin/cnss-daemon
+vendor/bin/cnss_diag
+vendor/bin/diag_callback_sample
+vendor/bin/diag_dci_sample
+vendor/bin/diag_mdlog
+vendor/bin/diag_socket_log
+vendor/bin/diag_uart_log
+vendor/bin/ftmdaemon
+vendor/bin/gptest
+vendor/bin/hdcp1prov
+vendor/bin/hw/android.hardware.bluetooth@1.0-service-qti
+vendor/bin/hw/android.hardware.drm@1.1-service.widevine
+vendor/bin/imsdatadaemon
+vendor/bin/imsqmidaemon
+vendor/bin/ims_rtp_daemon
+vendor/bin/irsc_util
+vendor/bin/loc_launcher
+vendor/bin/lowi-server
+vendor/bin/mct-unit-test-app
+vendor/bin/mdm_helper
+vendor/bin/mdm_helper_proxy
+vendor/bin/mm-qcamera-daemon
+vendor/bin/mm-qjpeg-dec-test
+vendor/bin/mm-qjpeg-enc-test
+vendor/bin/mm-qomx-idec-test
+vendor/bin/mm-qomx-ienc-test
+vendor/bin/msm_irqbalance
+vendor/bin/myftm
+vendor/bin/nanohub_slpi
+vendor/bin/netmgrd
+vendor/bin/nl_listener
+vendor/bin/perfd
+vendor/bin/PktRspTest
+vendor/bin/pm-proxy
+vendor/bin/pm-service
+vendor/bin/port-bridge
+vendor/bin/qfipsverify
+vendor/bin/qjpeg-dma-test
+vendor/bin/qseecomd
+vendor/bin/qseecom_sample_client
+vendor/bin/qti
+vendor/bin/radish
+vendor/bin/rmt_storage
+vendor/bin/slim_daemon
+vendor/bin/ssr_diag
+vendor/bin/ssr_setup
+vendor/bin/StoreKeybox
+vendor/bin/subsystem_ramdump
+vendor/bin/tbaseLoader
+vendor/bin/test_bet_8996
+vendor/bin/test_diag
+vendor/bin/test_module_pproc
+vendor/bin/thermal-engine
+vendor/bin/time_daemon
+vendor/bin/wdsdaemon
+vendor/bin/WifiLogger_app
+vendor/bin/xtra-daemon
+vendor/etc/acdbdata/Bluetooth_cal.acdb
+vendor/etc/acdbdata/General_cal.acdb
+vendor/etc/acdbdata/Global_cal.acdb
+vendor/etc/acdbdata/Handset_cal.acdb
+vendor/etc/acdbdata/Hdmi_cal.acdb
+vendor/etc/acdbdata/Headset_cal.acdb
+vendor/etc/acdbdata/Speaker_cal.acdb
+vendor/etc/camera/imx179_chromatix.xml
+vendor/etc/camera/imx378_chromatix.xml
+vendor/etc/camera/msm8996_camera.xml
+vendor/etc/data/dsi_config.xml
+vendor/etc/data/netmgr_config.xml
+vendor/etc/diag/CHRE.cfg
+vendor/etc/diag/IMS.cfg
+vendor/etc/diag/MarlinSailfish_Radio-generic.cfg
+vendor/etc/diag/wlan.cfg
+vendor/etc/flp.conf
+vendor/etc/init/android.hardware.bluetooth@1.0-service-qti.rc
+vendor/etc/init/android.hardware.drm@1.1-service.widevine.rc
+vendor/etc/izat.conf
+vendor/etc/lowi.conf
+vendor/etc/modem_stat.conf
+vendor/etc/perf-profile0.conf
+vendor/etc/permissions/LowPowerMonitorDeviceInterface.xml
+vendor/etc/permissions/LowPowerMonitorDeviceStub.xml
+vendor/etc/permissions/PowerAnomalyDataModemInterface.xml
+vendor/etc/permissions/PowerAnomalyStub.xml
+vendor/etc/permissions/embms.xml
+vendor/etc/permissions/qcrilhook.xml
+vendor/etc/permissions/qti_permissions.xml
+vendor/etc/permissions/qti-vzw-ims-internal.xml
+vendor/etc/permissions/rcsservice.xml
+vendor/etc/permissions/telephonyservice.xml
+vendor/etc/public.libraries.txt
+vendor/etc/qdcm_calib_data_S1_FHD_SAMSUNG_EA8064TG_5.0_command_mode_panel.xml
+vendor/etc/qfipsverify/bootimg.hmac
+vendor/etc/qfipsverify/qfipsverify.hmac
+vendor/etc/sap.conf
+vendor/firmware/a530_gpmu.fw2
+vendor/firmware/a530_pfp.fw
+vendor/firmware/a530_pm4.fw
+vendor/firmware/a530rnd.fw
+vendor/firmware/a530v3_gpmu.fw2
+vendor/firmware/a530v3_seq.fw2
+vendor/firmware/a530_zap.b00
+vendor/firmware/a530_zap.b01
+vendor/firmware/a530_zap.b02
+vendor/firmware/a530_zap.elf
+vendor/firmware/a530_zap.mdt
+vendor/firmware/a530_zap_signed.b00
+vendor/firmware/a530_zap_signed.b01
+vendor/firmware/a530_zap_signed.b02
+vendor/firmware/a530_zap_signed.elf
+vendor/firmware/a530_zap_signed.mbn
+vendor/firmware/a530_zap_signed.mdt
+vendor/firmware/activity.napp
+vendor/firmware/adsp.b00
+vendor/firmware/adsp.b01
+vendor/firmware/adsp.b02
+vendor/firmware/adsp.b03
+vendor/firmware/adsp.b04
+vendor/firmware/adsp.b05
+vendor/firmware/adsp.b06
+vendor/firmware/adsp.b08
+vendor/firmware/adsp.b09
+vendor/firmware/adsp.mdt
+vendor/firmware/adspver.cfg
+vendor/firmware/bdwlan30.b80
+vendor/firmware/bdwlan30.b81
+vendor/firmware/bdwlan30.b82
+vendor/firmware/bdwlan30.bin
+vendor/firmware/btfw32.tlv
+vendor/firmware/btnv32.bin
+vendor/firmware/cmnlib64.b00
+vendor/firmware/cmnlib64.b01
+vendor/firmware/cmnlib64.b02
+vendor/firmware/cmnlib64.b03
+vendor/firmware/cmnlib64.b04
+vendor/firmware/cmnlib64.b05
+vendor/firmware/cmnlib64.mdt
+vendor/firmware/cmnlib.b00
+vendor/firmware/cmnlib.b01
+vendor/firmware/cmnlib.b02
+vendor/firmware/cmnlib.b03
+vendor/firmware/cmnlib.b04
+vendor/firmware/cmnlib.b05
+vendor/firmware/cmnlib.mdt
+vendor/firmware/cpe_9335.b08
+vendor/firmware/cpe_9335.b09
+vendor/firmware/cpe_9335.b11
+vendor/firmware/cpe_9335.b14
+vendor/firmware/cpe_9335.b16
+vendor/firmware/cpe_9335.b18
+vendor/firmware/cpe_9335.b19
+vendor/firmware/cpe_9335.b20
+vendor/firmware/cpe_9335.b22
+vendor/firmware/cpe_9335.b24
+vendor/firmware/cpe_9335.b26
+vendor/firmware/cpe_9335.b28
+vendor/firmware/cpe_9335.b29
+vendor/firmware/cpe_9335.mdt
+vendor/firmware/cppf.b00
+vendor/firmware/cppf.b01
+vendor/firmware/cppf.b02
+vendor/firmware/cppf.b03
+vendor/firmware/cppf.b04
+vendor/firmware/cppf.b05
+vendor/firmware/cppf.b06
+vendor/firmware/cpp_firmware_v1_10_0.fw
+vendor/firmware/cpp_firmware_v1_1_1.fw
+vendor/firmware/cpp_firmware_v1_1_6.fw
+vendor/firmware/cpp_firmware_v1_2_0.fw
+vendor/firmware/cpp_firmware_v1_4_0.fw
+vendor/firmware/cpp_firmware_v1_5_0.fw
+vendor/firmware/cpp_firmware_v1_5_2.fw
+vendor/firmware/cpp_firmware_v1_6_0.fw
+vendor/firmware/cpp_firmware_v1_8_0.fw
+vendor/firmware/cppf.mdt
+vendor/firmware/Data.msc
+vendor/firmware/double_twist.napp
+vendor/firmware/fpctzappfingerprint.b00
+vendor/firmware/fpctzappfingerprint.b01
+vendor/firmware/fpctzappfingerprint.b02
+vendor/firmware/fpctzappfingerprint.b03
+vendor/firmware/fpctzappfingerprint.b04
+vendor/firmware/fpctzappfingerprint.b05
+vendor/firmware/fpctzappfingerprint.b06
+vendor/firmware/fpctzappfingerprint.mdt
+vendor/firmware/geofence.napp
+vendor/firmware/hotsound.sound_model
+vendor/firmware/nanohub.full.bin
+vendor/firmware/napp_list.cfg
+vendor/firmware/otp30.bin
+vendor/firmware/pickup_gesture.napp
+vendor/firmware/qwlan30.bin
+vendor/firmware/sig_motion.napp
+vendor/firmware/slpi.b00
+vendor/firmware/slpi.b01
+vendor/firmware/slpi.b02
+vendor/firmware/slpi.b03
+vendor/firmware/slpi.b04
+vendor/firmware/slpi.b05
+vendor/firmware/slpi.b06
+vendor/firmware/slpi.b07
+vendor/firmware/slpi.b08
+vendor/firmware/slpi.b09
+vendor/firmware/slpi.b10
+vendor/firmware/slpi.b11
+vendor/firmware/slpi.b12
+vendor/firmware/slpi.b13
+vendor/firmware/slpi.b14
+vendor/firmware/slpi.mdt
+vendor/firmware/slpiver.cfg
+vendor/firmware/synaptics_bl71.img
+vendor/firmware/tfa98xx.cnt
+vendor/firmware/utf30.bin
+vendor/firmware/venus.b00
+vendor/firmware/venus.b01
+vendor/firmware/venus.b02
+vendor/firmware/venus.b03
+vendor/firmware/venus.b04
+vendor/firmware/venus.flist
+vendor/firmware/venus.mbn
+vendor/firmware/venus.mdt
+vendor/firmware/widevine.b00
+vendor/firmware/widevine.b01
+vendor/firmware/widevine.b02
+vendor/firmware/widevine.b03
+vendor/firmware/widevine.b04
+vendor/firmware/widevine.b05
+vendor/firmware/widevine.b06
+vendor/firmware/widevine.mdt
+-vendor/framework/embmslibrary.jar
+-vendor/framework/QtiTelephonyServicelibrary.jar
+-vendor/framework/qti-vzw-ims-internal.jar
+-vendor/framework/rcsservice.jar
+vendor/lib64/egl/eglSubDriverAndroid.so
+vendor/lib64/egl/libEGL_adreno.so
+vendor/lib64/egl/libGLESv1_CM_adreno.so
+vendor/lib64/egl/libGLESv2_adreno.so
+vendor/lib64/egl/libq3dtools_adreno.so
+vendor/lib64/egl/libq3dtools_esx.so
+vendor/lib64/hw/android.hardware.bluetooth@1.0-impl-qti.so
+vendor/lib64/hw/fingerprint.sailfish.so
+vendor/lib64/hw/flp.default.so
+vendor/lib64/hw/gatekeeper.msm8996.so
+vendor/lib64/hw/gps.default.so
+vendor/lib64/hw/keystore.msm8996.so
+vendor/lib64/hw/vulkan.msm8996.so
+vendor/lib64/libacdb-fts.so
+vendor/lib64/libacdbloader.so
+vendor/lib64/libacdbmapper.so
+vendor/lib64/libacdbrtac.so
+vendor/lib64/libadiertac.so
+vendor/lib64/libadreno_utils.so
+vendor/lib64/libadsp_default_listener.so
+vendor/lib64/libadsprpc.so
+vendor/lib64/libaudcal.so
+vendor/lib64/libaudioalsa.so
+vendor/lib64/libbccQTI.so
+vendor/lib64/libbtnv.so
+vendor/lib64/libC2D2.so
+vendor/lib64/libc2d30-a3xx.so
+vendor/lib64/libc2d30-a4xx.so
+vendor/lib64/libc2d30-a5xx.so
+vendor/lib64/libc2d30_bltlib.so
+vendor/lib64/libCB.so
+vendor/lib64/libcneapiclient.so
+vendor/lib64/libcne.so
+vendor/lib64/libconfigdb.so
+vendor/lib64/libdiag.so
+vendor/lib64/libdisp-aba.so
+vendor/lib64/lib-dplmedia.so
+vendor/lib64/libdrmfs.so
+vendor/lib64/libdrmtime.so
+vendor/lib64/libdsi_netctrl.so
+vendor/lib64/libdsutils.so
+vendor/lib64/libfastcvadsp_stub.so
+vendor/lib64/libfastcvopt.so
+vendor/lib64/libflp.so
+vendor/lib64/lib_fpc_tac_shared.so
+vendor/lib64/libgeofence.so
+vendor/lib64/libGPreqcancel.so
+vendor/lib64/libGPreqcancel_svc.so
+vendor/lib64/libgps.utils.so
+vendor/lib64/libGPTEE.so
+vendor/lib64/libgsl.so
+vendor/lib64/libhdcp1prov.so
+vendor/lib64/libidl.so
+vendor/lib64/lib-imsdpl.so
+vendor/lib64/lib-imsqimf.so
+vendor/lib64/lib-imsrcs.so
+vendor/lib64/lib-imsSDP.so
+vendor/lib64/lib-imsxml.so
+vendor/lib64/libizat_core.so
+vendor/lib64/liblbs_core.so
+vendor/lib64/libllvm-glnext.so
+vendor/lib64/libllvm-qcom.so
+vendor/lib64/libloc_api_v02.so
+vendor/lib64/libloc_core.so
+vendor/lib64/libloc_ds_api.so
+vendor/lib64/libloc_eng.so
+vendor/lib64/liblowi_client.so
+vendor/lib64/liblowi_wifihal.so
+vendor/lib64/liblqe.so
+vendor/lib64/libmdmdetect.so
+vendor/lib64/libmdmimgload.so
+vendor/lib64/libmdsprpc.so
+vendor/lib64/libmmcamera_dbg.so
+vendor/lib64/libmm-disp-apis.so
+vendor/lib64/libmm-hdcpmgr.so
+vendor/lib64/libmm-qdcm.so
+vendor/lib64/libnetmgr.so
+vendor/lib64/libperipheral_client.so
+vendor/lib64/libpvr.so
+vendor/lib64/libqcci_legacy.so
+vendor/lib64/libqcmaputils.so
+vendor/lib64/libqdi.so
+vendor/lib64/libqdp.so
+vendor/lib64/libqisl.so
+vendor/lib64/libqmi_cci.so
+vendor/lib64/libqmi_client_helper.so
+vendor/lib64/libqmi_client_qmux.so
+vendor/lib64/libqmi_common_so.so
+vendor/lib64/libqmi_csi.so
+vendor/lib64/libqmi_encdec.so
+vendor/lib64/libqmiservices_ext.so
+vendor/lib64/libqmiservices_htc.so
+vendor/lib64/libqmiservices.so
+vendor/lib64/libqmi.so
+vendor/lib64/libQSEEComAPI.so
+vendor/lib64/libqti-perfd-client.so
+vendor/lib64/libquipc_os_api.so
+vendor/lib64/lib-rcsjni.so
+vendor/lib64/libril-qc-qmi-1.so
+vendor/lib64/libril-qc-radioconfig.so
+vendor/lib64/libril-qcril-hook-oem.so
+vendor/lib64/librilqmiservices.so
+vendor/lib64/librmp.so
+vendor/lib64/librpmb.so
+vendor/lib64/librs_adreno_sha1.so
+vendor/lib64/librs_adreno.so
+vendor/lib64/libRSDriver_adreno.so
+vendor/lib64/lib-rtpcommon.so
+vendor/lib64/lib-rtpcore.so
+vendor/lib64/lib-rtpdaemoninterface.so
+vendor/lib64/lib-rtpsl.so
+vendor/lib64/libSampleAuthJNI.so
+vendor/lib64/libSampleExtAuthJNI.so
+vendor/lib64/libscalar.so
+vendor/lib64/libscale.so
+vendor/lib64/libsdm-color.so
+vendor/lib64/libsdm-diag.so
+vendor/lib64/libsdm-disp-apis.so
+vendor/lib64/libsdmextension.so
+vendor/lib64/libsd_sdk_display.so
+vendor/lib64/libsdsprpc.so
+vendor/lib64/lib-sec-disp.so
+vendor/lib64/libSecureExtAuthJNI.so
+vendor/lib64/libSecureSampleAuthJNI.so
+vendor/lib64/libSecureUILib.so
+vendor/lib64/libsecureui.so
+vendor/lib64/libsecureuisvc_jni.so
+vendor/lib64/libsecureui_svcsock.so
+vendor/lib64/libsi.so
+vendor/lib64/libsmemlog.so
+vendor/lib64/libssd.so
+vendor/lib64/libStDrvInt.so
+vendor/lib64/libsystem_health_mon.so
+vendor/lib64/libthermalclient.so
+vendor/lib64/libthermalioctl.so
+vendor/lib64/libtime_genoff.so
+vendor/lib64/libTimeService.so
+vendor/lib64/libtzdrmgenprov.so
+vendor/lib64/libwms.so
+vendor/lib64/libxml.so
+vendor/lib/dsp/EtsiEaacPlusEncAndCmnModule.so.1
+vendor/lib/dsp/fastrpc_shell_0
+vendor/lib/dsp/fluence_voiceplus_module.so.1
+vendor/lib/dsp/HeaacDecoderModule.so.1
+vendor/lib/dsp/libsysmon_skel.so
+vendor/lib/dsp/map_avs_shared_libs.txt
+vendor/lib/dsp/map_SHARED_LIBS_AAAAAAAAQ.txt
+vendor/lib/dsp/mmecns_module.so.1
+vendor/lib/dsp/SAPlusCmnModule.so.1
+vendor/lib/egl/eglSubDriverAndroid.so
+vendor/lib/egl/libEGL_adreno.so
+vendor/lib/egl/libGLESv1_CM_adreno.so
+vendor/lib/egl/libGLESv2_adreno.so
+vendor/lib/egl/libq3dtools_adreno.so
+vendor/lib/egl/libq3dtools_esx.so
+vendor/lib/hw/audio.primary.msm8996.so
+vendor/lib/hw/flp.default.so
+vendor/lib/hw/gatekeeper.msm8996.so
+vendor/lib/hw/gps.default.so
+vendor/lib/hw/keystore.msm8996.so
+vendor/lib/hw/sensors.vl530l0.tof.so
+vendor/lib/hw/sound_trigger.primary.msm8996.so
+vendor/lib/hw/vulkan.msm8996.so
+vendor/lib/libacdb-fts.so
+vendor/lib/libacdbloader.so
+vendor/lib/libacdbmapper.so
+vendor/lib/libacdbrtac.so
+vendor/lib/libactuator_lc898212xd_htc.so
+vendor/lib/libadiertac.so
+vendor/lib/libadm.so
+vendor/lib/libadpcmdec.so
+vendor/lib/libadreno_utils.so
+vendor/lib/libadsp_default_listener.so
+vendor/lib/libadsprpc.so
+vendor/lib/libaudcal.so
+vendor/lib/libaudioalsa.so
+vendor/lib/libbccQTI.so
+vendor/lib/libC2D2.so
+vendor/lib/libc2d30-a3xx.so
+vendor/lib/libc2d30-a4xx.so
+vendor/lib/libc2d30-a5xx.so
+vendor/lib/libc2d30_bltlib.so
+vendor/lib/libCB.so
+vendor/lib/libchromatix_imx179_common.so
+vendor/lib/libchromatix_imx179_postproc.so
+vendor/lib/libchromatix_imx179_video_16_9_3a.so
+vendor/lib/libchromatix_imx179_video_16_9_cpp.so
+vendor/lib/libchromatix_imx179_video_16_9_isp.so
+vendor/lib/libchromatix_imx179_video_qtr_16_9_3a.so
+vendor/lib/libchromatix_imx179_video_qtr_16_9_cpp.so
+vendor/lib/libchromatix_imx179_video_qtr_16_9_isp.so
+vendor/lib/libchromatix_imx179_zsl_snapshot_3a.so
+vendor/lib/libchromatix_imx179_zsl_snapshot_cpp.so
+vendor/lib/libchromatix_imx179_zsl_snapshot_isp.so
+vendor/lib/libchromatix_imx378_common.so
+vendor/lib/libchromatix_imx378_postproc.so
+vendor/lib/libchromatix_imx378_video_16_9_3a.so
+vendor/lib/libchromatix_imx378_video_16_9_cpp.so
+vendor/lib/libchromatix_imx378_video_16_9_isp.so
+vendor/lib/libchromatix_imx378_video_hfr_120_3a.so
+vendor/lib/libchromatix_imx378_video_hfr_120_cpp.so
+vendor/lib/libchromatix_imx378_video_hfr_120_isp.so
+vendor/lib/libchromatix_imx378_video_hfr_240_3a.so
+vendor/lib/libchromatix_imx378_video_hfr_240_cpp.so
+vendor/lib/libchromatix_imx378_video_hfr_240_isp.so
+vendor/lib/libchromatix_imx378_video_hfr_60_3a.so
+vendor/lib/libchromatix_imx378_video_hfr_60_cpp.so
+vendor/lib/libchromatix_imx378_video_hfr_60_isp.so
+vendor/lib/libchromatix_imx378_zsl_snapshot_3a.so
+vendor/lib/libchromatix_imx378_zsl_snapshot_cpp.so
+vendor/lib/libchromatix_imx378_zsl_snapshot_isp.so
+vendor/lib/libcneapiclient.so
+vendor/lib/libcne.so
+vendor/lib/libconfigdb.so
+vendor/lib/libcppf.so
+vendor/lib/libdiag.so
+vendor/lib/libdisp-aba.so
+vendor/lib/lib-dplmedia.so
+vendor/lib/libdrmfs.so
+vendor/lib/libdrmtime.so
+vendor/lib/libdsi_netctrl.so
+vendor/lib/libdsutils.so
+vendor/lib/libeglc2d.so
+vendor/lib/libfastcvadsp_stub.so
+vendor/lib/libfastcvopt.so
+vendor/lib/libflash_pmic.so
+vendor/lib/libflp.so
+vendor/lib/libgcam_ae.so
+vendor/lib/libgeofence.so
+vendor/lib/libgoog_eis_armeabi-v7a.so
+vendor/lib/libGPreqcancel.so
+vendor/lib/libGPreqcancel_svc.so
+vendor/lib/libgps.utils.so
+vendor/lib/libGPTEE.so
+vendor/lib/libgsl.so
+vendor/lib/libhdcp1prov.so
+vendor/lib/libidl.so
+vendor/lib/lib-imsdpl.so
+vendor/lib/lib-imsrcs.so
+vendor/lib/libizat_core.so
+vendor/lib/libjpegdhw.so
+vendor/lib/libjpegdmahw.so
+vendor/lib/libjpegehw.so
+vendor/lib/liblbs_core.so
+vendor/lib/libllvd_smore.so
+vendor/lib/libllvm-glnext.so
+vendor/lib/libllvm-qcom.so
+vendor/lib/libloc_api_v02.so
+vendor/lib/libloc_core.so
+vendor/lib/libloc_ds_api.so
+vendor/lib/libloc_eng.so
+vendor/lib/liblowi_client.so
+vendor/lib/libmdmdetect.so
+vendor/lib/libmdsprpc.so
+vendor/lib/libmmcamera2_c2d_module.so
+vendor/lib/libmmcamera2_cpp_module.so
+vendor/lib/libmmcamera2_frame_algorithm.so
+vendor/lib/libmmcamera2_iface_modules.so
+vendor/lib/libmmcamera2_imglib_modules.so
+vendor/lib/libmmcamera2_isp_modules.so
+vendor/lib/libmmcamera2_is.so
+vendor/lib/libmmcamera2_mct_shimlayer.so
+vendor/lib/libmmcamera2_mct.so
+vendor/lib/libmmcamera2_memleak.so
+vendor/lib/libmmcamera2_pp_buf_mgr.so
+vendor/lib/libmmcamera2_pproc_modules.so
+vendor/lib/libmmcamera2_q3a_core.so
+vendor/lib/libmmcamera2_sensor_modules.so
+vendor/lib/libmmcamera2_stats_algorithm.so
+vendor/lib/libmmcamera2_stats_modules.so
+vendor/lib/libmmcamera_dbg.so
+vendor/lib/libmmcamera_eeprom_util.so
+vendor/lib/libmmcamera_eztune_module.so
+vendor/lib/libmmcamera_facedetection_lib.so
+vendor/lib/libmmcamera_faceproc2.so
+vendor/lib/libmmcamera_faceproc.so
+vendor/lib/libmmcamera_imglib.so
+vendor/lib/libmmcamera_imx179_htc.so
+vendor/lib/libmmcamera_imx378_htc.so
+vendor/lib/libmmcamera_isp_abf47.so
+vendor/lib/libmmcamera_isp_aec_bg_stats47.so
+vendor/lib/libmmcamera_isp_bf_stats47.so
+vendor/lib/libmmcamera_isp_bg_stats46.so
+vendor/lib/libmmcamera_isp_bhist_stats44.so
+vendor/lib/libmmcamera_isp_black_level47.so
+vendor/lib/libmmcamera_isp_bpc47.so
+vendor/lib/libmmcamera_isp_cac47.so
+vendor/lib/libmmcamera_isp_chroma_enhan40.so
+vendor/lib/libmmcamera_isp_chroma_suppress40.so
+vendor/lib/libmmcamera_isp_clamp_encoder40.so
+vendor/lib/libmmcamera_isp_clamp_video40.so
+vendor/lib/libmmcamera_isp_clamp_viewfinder40.so
+vendor/lib/libmmcamera_isp_color_correct46.so
+vendor/lib/libmmcamera_isp_color_xform_encoder46.so
+vendor/lib/libmmcamera_isp_color_xform_video46.so
+vendor/lib/libmmcamera_isp_color_xform_viewfinder46.so
+vendor/lib/libmmcamera_isp_cs_stats46.so
+vendor/lib/libmmcamera_isp_demosaic47.so
+vendor/lib/libmmcamera_isp_demux40.so
+vendor/lib/libmmcamera_isp_fovcrop_encoder46.so
+vendor/lib/libmmcamera_isp_fovcrop_video46.so
+vendor/lib/libmmcamera_isp_fovcrop_viewfinder46.so
+vendor/lib/libmmcamera_isp_gamma44.so
+vendor/lib/libmmcamera_isp_gic46.so
+vendor/lib/libmmcamera_isp_gtm46.so
+vendor/lib/libmmcamera_isp_hdr46.so
+vendor/lib/libmmcamera_isp_hdr_be_stats46.so
+vendor/lib/libmmcamera_isp_ihist_stats46.so
+vendor/lib/libmmcamera_isp_linearization40.so
+vendor/lib/libmmcamera_isp_ltm47.so
+vendor/lib/libmmcamera_isp_mce40.so
+vendor/lib/libmmcamera_isp_mesh_rolloff44.so
+vendor/lib/libmmcamera_isp_pedestal_correct46.so
+vendor/lib/libmmcamera_isp_rs_stats46.so
+vendor/lib/libmmcamera_isp_scaler_encoder46.so
+vendor/lib/libmmcamera_isp_scaler_video46.so
+vendor/lib/libmmcamera_isp_scaler_viewfinder46.so
+vendor/lib/libmmcamera_isp_sce40.so
+vendor/lib/libmmcamera_isp_snr47.so
+vendor/lib/libmmcamera_isp_sub_module.so
+vendor/lib/libmmcamera_llvd.so
+vendor/lib/libmmcamera_paaf_lib.so
+vendor/lib/libmmcamera_pdafcamif.so
+vendor/lib/libmmcamera_pdaf.so
+vendor/lib/libmmcamera_ppbase_module.so
+vendor/lib/libmmcamera_sony_imx179_eeprom.so
+vendor/lib/libmmcamera_sony_imx378_eeprom.so
+vendor/lib/libmmcamera_thread_services.so
+vendor/lib/libmmcamera_tintless_algo.so
+vendor/lib/libmmcamera_tintless_bg_pca_algo.so
+vendor/lib/libmmcamera_tuning_lookup.so
+vendor/lib/libmmcamera_tuning.so
+vendor/lib/libmm-disp-apis.so
+vendor/lib/libmm-hdcpmgr.so
+vendor/lib/libmmjpeg.so
+vendor/lib/libmm-qdcm.so
+vendor/lib/libmmqjpeg_codec.so
+vendor/lib/libmmqjpegdma.so
+vendor/lib/libnetmgr.so
+vendor/lib/liboemcrypto.so
+vendor/lib/libperipheral_client.so
+vendor/lib/libpvr.so
+vendor/lib/libqcci_legacy.so
+vendor/lib/libqcmaputils.so
+vendor/lib/libqdi.so
+vendor/lib/libqisl.so
+vendor/lib/libqmi_cci.so
+vendor/lib/libqmi_client_helper.so
+vendor/lib/libqmi_client_qmux.so
+vendor/lib/libqmi_common_so.so
+vendor/lib/libqmi_csi.so
+vendor/lib/libqmi_encdec.so
+vendor/lib/libqmiservices_ext.so
+vendor/lib/libqmiservices.so
+vendor/lib/libqmi.so
+vendor/lib/libqomx_jpegdec.so
+vendor/lib/libqomx_jpegenc_pipe.so
+vendor/lib/libqomx_jpegenc.so
+vendor/lib/libQSEEComAPI.so
+vendor/lib/libqti-perfd-client.so
+vendor/lib/libquipc_os_api.so
+vendor/lib/lib-rcsjni.so
+vendor/lib/libril-qcril-hook-oem.so
+vendor/lib/librmp.so
+vendor/lib/librpmb.so
+vendor/lib/librs_adreno_sha1.so
+vendor/lib/librs_adreno.so
+vendor/lib/libRSDriver_adreno.so
+vendor/lib/lib-rtpcommon.so
+vendor/lib/lib-rtpcore.so
+vendor/lib/lib-rtpdaemoninterface.so
+vendor/lib/lib-rtpsl.so
+vendor/lib/libSampleAuthJNI.so
+vendor/lib/libSampleExtAuthJNI.so
+vendor/lib/libscale.so
+vendor/lib/libsdm-disp-apis.so
+vendor/lib/libsd_sdk_display.so
+vendor/lib/libsdsprpc.so
+vendor/lib/lib-sec-disp.so
+vendor/lib/libSecureExtAuthJNI.so
+vendor/lib/libSecureSampleAuthJNI.so
+vendor/lib/libSecureUILib.so
+vendor/lib/libsecureui.so
+vendor/lib/libsecureuisvc_jni.so
+vendor/lib/libsecureui_svcsock.so
+vendor/lib/libseemore.so
+vendor/lib/libsi.so
+vendor/lib/libsmemlog.so
+vendor/lib/libSonyIMX378PdafLibrary.so
+vendor/lib/libssd.so
+vendor/lib/libStDrvInt.so
+vendor/lib/libsystem_health_mon.so
+vendor/lib/libthermalclient.so
+vendor/lib/libtime_genoff.so
+vendor/lib/libTimeService.so
+vendor/lib/libtm_interface.so
+vendor/lib/libtzdrmgenprov.so
+vendor/lib/libwms.so
+vendor/lib/libwvhidl.so
+vendor/lib/libxml.so
+vendor/lib/rfsa/adsp/chre_drv_loc.so
+vendor/lib/rfsa/adsp/chre_drv_modem.so
+vendor/lib/rfsa/adsp/chre_drv_wifi.so
+vendor/lib/rfsa/adsp/chre_platform.so
+vendor/lib/rfsa/adsp/chre.so
+vendor/lib/rfsa/adsp/libnanohub_slpi_skel.so
+vendor/lib/rfsa/adsp/libseemore_hexagon_skel.so
+vendor/lib/rfsa/adsp/lowi_client.so
+vendor/lib/rfsa/adsp/nano_bridge.so
+vendor/lib/soundfx/libfmas.so
+vendor/lib/test_suite_all_modules.so
+vendor/lib/test_suite_no_sensor.so
+vendor/lib/test_suite_pproc.so
+vendor/lib/test_suite_vfe.so
+vendor/media/LMspeed_508.emd
+vendor/media/PFFprec_600.emd
+vendor/qcril_database/upgrade/1_version_intro.sql
+vendor/qcril_database/upgrade/2_db_upgrade.sql
+vendor/qcril_database/upgrade/3_remove_ecc_999_from_us_and_canada.sql
+vendor/qcril_database/upgrade/4_db_upgrade.sql
+vendor/qcril_database/upgrade/5_update_india_ecc.sql
+vendor/qcril.db
diff --git a/sailfish/device-proprietary-files.txt b/sailfish/device-proprietary-files.txt
new file mode 100644
index 000000000..b802d082b
--- /dev/null
+++ b/sailfish/device-proprietary-files.txt
@@ -0,0 +1,92 @@
+# Bluetooth
+lib64/libaptX_encoder.so
+lib64/libaptXHD_encoder.so
+lib/libaptX_encoder.so
+lib/libaptXHD_encoder.so
+
+# Camera
+etc/permissions/com.google.android.camera.experimental2016.xml
+-framework/com.google.android.camera.experimental2016.jar;PRESIGNED
+
+# CNE
+etc/cne/Nexus/ATT/ATT_profiles.xml
+etc/cne/Nexus/ROW/ROW_profiles.xml
+etc/cne/Nexus/VZW/VZW_profiles.xml
+
+# DRM
+bin/move_widevine_data.sh
+
+# Hotword Enrollment
+-priv-app/HotwordEnrollmentOKGoogleWCD9335/HotwordEnrollmentOKGoogleWCD9335.apk;PRESIGNED
+-priv-app/HotwordEnrollmentTGoogleWCD9335/HotwordEnrollmentTGoogleWCD9335.apk;PRESIGNED
+-priv-app/HotwordEnrollmentXGoogleWCD9335/HotwordEnrollmentXGoogleWCD9335.apk;PRESIGNED
+
+# IMS/HD Voice
+-app/ims/ims.apk
+-priv-app/CNEService/CNEService.apk
+lib64/lib-imsvideocodec.so
+lib64/lib-imsvtextutils.so
+lib64/lib-imsvt.so
+lib64/lib-imsvtutils.so
+lib64/libimscamera_jni.so
+lib64/libimsmedia_jni.so
+lib64/librcc.so
+lib/lib-imsvideocodec.so
+lib/lib-imsvtextutils.so
+lib/lib-imsvt.so
+lib/lib-imsvtutils.so
+lib/librcc.so
+
+# Permissions
+etc/permissions/privapp-permissions-google.xml
+
+# RIL
+-framework/LowPowerMonitorDeviceInterface.jar
+-framework/LowPowerMonitorDeviceStub.jar
+-framework/PowerAnomalyDataModemInterface.jar
+-framework/PowerAnomalyStub.jar
+-framework/qcrilhook.jar
+-priv-app/Asdiv/Asdiv.apk
+-priv-app/qcrilmsgtunnel/qcrilmsgtunnel.apk
+lib64/vendor.qti.atcmdfwd@1.0.so
+lib64/vendor.qti.qcril.am@1.0.so
+
+# Sprint
+etc/permissions/com.android.omadm.service.xml
+etc/permissions/com.android.sdm.plugins.sprintdm.xml
+etc/sysconfig/whitelist_com.android.omadm.service.xml
+lib/libdmengine.so
+lib/libdmjavaplugin.so
+-priv-app/DMService/DMService.apk
+-priv-app/DiagMon/DiagMon.apk
+-priv-app/SprintDM/SprintDM.apk
+-priv-app/SprintHM/SprintHM.apk
+
+# Sysconfig
+etc/sysconfig/nexus.xml
+etc/sysconfig/pixel_2016_exclusive.xml
+
+# VZW
+-app/VZWAPNLib/VZWAPNLib.apk;PRESIGNED
+etc/permissions/com.android.sdm.plugins.connmo.xml
+etc/permissions/com.android.vzwomatrigger.xml
+etc/permissions/com.verizon.apn.xml
+etc/permissions/com.verizon.embms.xml
+etc/permissions/com.verizon.provider.xml
+etc/permissions/com.verizon.services.xml
+etc/permissions/features-verizon.xml
+etc/permissions/obdm_permissions.xml
+etc/permissions/vzw_mvs_permissions.xml
+-framework/VerizonUnifiedSettings.jar;PRESIGNED
+-priv-app/CarrierSetup/CarrierSetup.apk
+-priv-app/ConnMO/ConnMO.apk
+-priv-app/DCMO/DCMO.apk
+priv-app/MyVerizonServices/lib/arm64/libakuaf.so
+priv-app/MyVerizonServices/lib/arm64/libmotricity.so
+-priv-app/MyVerizonServices/MyVerizonServices.apk;PRESIGNED
+-priv-app/OBDM_Permissions/OBDM_Permissions.apk
+-priv-app/OemDmTrigger/OemDmTrigger.apk
+-priv-app/VerizonAuthDialog/VerizonAuthDialog.apk;PRESIGNED
+-priv-app/VzwOmaTrigger/VzwOmaTrigger.apk;PRESIGNED
+-priv-app/WfcActivation/WfcActivation.apk;PRESIGNED
+-priv-app/obdm_stub/obdm_stub.apk;PRESIGNED
diff --git a/sailfish/extract-files.sh b/sailfish/extract-files.sh
new file mode 100755
index 000000000..91bb11bc0
--- /dev/null
+++ b/sailfish/extract-files.sh
@@ -0,0 +1,61 @@
+#!/bin/bash
+#
+# Copyright (C) 2019 The LineageOS Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -e
+
+VENDOR=google
+DEVICE=sailfish
+
+# Load extractutils and do some sanity checks
+MY_DIR="${BASH_SOURCE%/*}"
+if [[ ! -d "$MY_DIR" ]]; then MY_DIR="$PWD"; fi
+
+LINEAGE_ROOT="$MY_DIR"/../../..
+
+HELPER="$LINEAGE_ROOT"/vendor/lineage/build/tools/extract_utils.sh
+if [ ! -f "$HELPER" ]; then
+ echo "Unable to find helper script at $HELPER"
+ exit 1
+fi
+. "$HELPER"
+
+if [ $# -eq 0 ]; then
+ SRC=adb
+else
+ if [ $# -eq 1 ]; then
+ SRC=$1
+ else
+ echo "$0: bad number of arguments"
+ echo ""
+ echo "usage: $0 [PATH_TO_EXPANDED_ROM]"
+ echo ""
+ echo "If PATH_TO_EXPANDED_ROM is not specified, blobs will be extracted from"
+ echo "the device using adb pull."
+ exit 1
+ fi
+fi
+
+# Initialize the helper
+setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT"
+
+extract "$MY_DIR"/../marlin/$DEVICE/device-proprietary-files.txt "$SRC"
+extract "$MY_DIR"/../marlin/$DEVICE/device-proprietary-files-vendor.txt "$SRC"
+
+# Don't disable MyVerizonServices app
+sed -i 's|||g'\
+ "$LINEAGE_ROOT"/vendor/"$VENDOR"/"$DEVICE"/proprietary/etc/sysconfig/nexus.xml
+
+"$MY_DIR/../marlin/$DEVICE"/setup-makefiles.sh
diff --git a/sailfish/setup-makefiles.sh b/sailfish/setup-makefiles.sh
new file mode 100755
index 000000000..0d3d70a51
--- /dev/null
+++ b/sailfish/setup-makefiles.sh
@@ -0,0 +1,48 @@
+#!/bin/bash
+#
+# Copyright (C) 2019 The LineageOS Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -e
+
+VENDOR=google
+DEVICE=sailfish
+
+INITIAL_COPYRIGHT_YEAR=2019
+
+# Load extractutils and do some sanity checks
+MY_DIR="${BASH_SOURCE%/*}"
+if [[ ! -d "$MY_DIR" ]]; then MY_DIR="$PWD"; fi
+
+LINEAGE_ROOT="$MY_DIR"/../../../..
+
+HELPER="$LINEAGE_ROOT"/vendor/lineage/build/tools/extract_utils.sh
+if [ ! -f "$HELPER" ]; then
+ echo "Unable to find helper script at $HELPER"
+ exit 1
+fi
+. "$HELPER"
+
+# Initialize the helper
+setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT"
+
+# Copyright headers and guards
+write_headers
+
+# The standard blobs
+write_makefiles "$MY_DIR"/device-proprietary-files.txt
+write_makefiles "$MY_DIR"/device-proprietary-files-vendor.txt true
+
+# Finish
+write_footers