summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron Knight <starlightknight@slkdev.net>2016-07-21 23:28:32 -0400
committerGerrit Code Review <gerrit@cyanogenmod.org>2016-07-27 04:50:15 -0700
commit9b1cd8bcee19ab9fc1a0fe2e7b7c5ba88e3a698f (patch)
tree5abb54cf1a92fc25938fade7c54145ac0105e9b0
parentbbc335717844eb5532c5123fcc7cd468883fcc7c (diff)
downloaddevice_samsung_t0lte-9b1cd8bcee19ab9fc1a0fe2e7b7c5ba88e3a698f.tar.gz
device_samsung_t0lte-9b1cd8bcee19ab9fc1a0fe2e7b7c5ba88e3a698f.tar.bz2
device_samsung_t0lte-9b1cd8bcee19ab9fc1a0fe2e7b7c5ba88e3a698f.zip
t0lte: Fixes to Extract Files Script
Two sets of build files live in this repo - t0lte.mk and common.mk. Some devices, like the l900 include common.mk instead of using t0lte.mk common.mk tries to include t0lte-common-vendor.mk, whereas t0lte.mk includes t0lte-vendor.mk. The extract-files.sh is included in devices like the l900 which use common.mk, but the script only creates t0lte-vendor.mk, leaving no way for t0lte-common-vendor.mk to be created. It seemed to me that the least impactful way to fix this is to introduce an arg to extract-files.sh to indicate whether to write t0lte-common-vendor.mk or t0lte-vendor.mk - this allows a device like the l900 to pass the common flag in its extract-files.sh, making it possible to make both sets of makefiles happy. I don't know the history of why there is a split in these build files, nor do I have all the devices in question, so I'm trying to keep the impact minimal since I only have an l900 to test with This, along with the l900 patch I also submitted allows you to get a working l900 build using the extract-files.sh as directed on the wiki. Previously, you ended up with no radio due to missing blobs. Change-Id: I2ad5ac86b767325ee26b79e4706741c43489e478
-rwxr-xr-xextract-files.sh18
1 files changed, 13 insertions, 5 deletions
diff --git a/extract-files.sh b/extract-files.sh
index 015cff5..4441ab0 100755
--- a/extract-files.sh
+++ b/extract-files.sh
@@ -18,6 +18,14 @@
VENDOR=samsung
DEVICE=t0lte
+COMMON=common
+
+if [ $COMMON = $1 ]
+then
+ COMMON="-common"
+else
+ COMMON=""
+fi
mkdir -p ../../../vendor/$VENDOR/$DEVICE/proprietary
@@ -34,7 +42,7 @@ for FILE in `cat ../$DEVICE/proprietary-files.txt | grep -v ^# | grep -v ^$`; do
done
-(cat << EOF) | sed s/__DEVICE__/$DEVICE/g | sed s/__VENDOR__/$VENDOR/g > ../../../vendor/$VENDOR/$DEVICE/$DEVICE-vendor-blobs.mk
+(cat << EOF) | sed s/__DEVICE__/$DEVICE/g | sed s/__VENDOR__/$VENDOR/g > ../../../vendor/$VENDOR/$DEVICE/$DEVICE$COMMON-vendor-blobs.mk
# Copyright (C) 2013 The CyanogenMod Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -61,10 +69,10 @@ for FILE in `cat proprietary-files.txt | grep -v ^# | grep -v ^$`; do
if [ $COUNT = "0" ]; then
LINEEND=""
fi
- echo " \$(LOCAL_PATH)/proprietary/$FILE:$FILE$LINEEND" >> ../../../vendor/$VENDOR/$DEVICE/$DEVICE-vendor-blobs.mk
+ echo " \$(LOCAL_PATH)/proprietary/$FILE:$FILE$LINEEND" >> ../../../vendor/$VENDOR/$DEVICE/$DEVICE$COMMON-vendor-blobs.mk
done
-(cat << EOF) | sed s/__DEVICE__/$DEVICE/g | sed s/__VENDOR__/$VENDOR/g > ../../../vendor/$VENDOR/$DEVICE/$DEVICE-vendor.mk
+(cat << EOF) | sed s/__DEVICE__/$DEVICE/g | sed s/__VENDOR__/$VENDOR/g > ../../../vendor/$VENDOR/$DEVICE/$DEVICE$COMMON-vendor.mk
# Copyright (C) 2013 The CyanogenMod Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -82,7 +90,7 @@ done
# Pick up overlay for features that depend on non-open-source files
DEVICE_PACKAGE_OVERLAYS += vendor/__VENDOR__/__DEVICE__/overlay
-\$(call inherit-product, vendor/__VENDOR__/__DEVICE__/__DEVICE__-vendor-blobs.mk)
+\$(call inherit-product, vendor/__VENDOR__/__DEVICE__/__DEVICE__$COMMON-vendor-blobs.mk)
EOF
(cat << EOF) | sed s/__DEVICE__/$DEVICE/g | sed s/__VENDOR__/$VENDOR/g > ../../../vendor/$VENDOR/$DEVICE/BoardConfigVendor.mk
@@ -102,4 +110,4 @@ EOF
EOF
-./../../../device/samsung/smdk4412-common/extract-files.sh
+cd ./../../../device/samsung/smdk4412-common/ && ./extract-files.sh