aboutsummaryrefslogtreecommitdiff
path: root/setup-makefiles.sh
diff options
context:
space:
mode:
authordavide <davidevinavil@gmail.com>2017-08-24 00:30:40 +0200
committerdd3boh <dade.garberi@gmail.com>2017-08-24 14:08:01 +0200
commit4ee103eb15702082968a5816b20740390860d5df (patch)
tree555d16a61016edeb0eba06f07d3e75da01a962ef /setup-makefiles.sh
parent0a80db61e213a72910094e39069094207e8610bb (diff)
setup-makefiles.sh: Add statement to fix build error when more vendor are present
Diffstat (limited to 'setup-makefiles.sh')
-rwxr-xr-xsetup-makefiles.sh31
1 files changed, 9 insertions, 22 deletions
diff --git a/setup-makefiles.sh b/setup-makefiles.sh
index 58d4ced..fd153d8 100755
--- a/setup-makefiles.sh
+++ b/setup-makefiles.sh
@@ -3,7 +3,7 @@ VENDOR=zuk
DEVICE=z2_plus
OUTDIR=vendor/$VENDOR/$DEVICE
-MAKEFILE=../../../$OUTDIR/$DEVICE-vendor-blobs.mk
+MAKEFILE=../../../$OUTDIR/$DEVICE-vendor.mk
(cat << EOF) > $MAKEFILE
# Copyright (C) 2016 The CyanogenMod Project
@@ -20,6 +20,8 @@ MAKEFILE=../../../$OUTDIR/$DEVICE-vendor-blobs.mk
# See the License for the specific language governing permissions and
# limitations under the License.
+ifeq (\$(TARGET_DEVICE),$DEVICE)
+
PRODUCT_COPY_FILES += \\
EOF
@@ -44,28 +46,8 @@ for FILE in `egrep -v '(^#|^$)' proprietary-files.txt`; do
fi
done
-(cat << EOF) > ../../../$OUTDIR/$DEVICE-vendor.mk
-# Copyright (C) 2016 The CyanogenMod 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.
-
-# Pick up overlay for features that depend on non-open-source files
-
-\$(call inherit-product, vendor/$VENDOR/$DEVICE/$DEVICE-vendor-blobs.mk)
-EOF
-
OUTDIR=vendor/$VENDOR/$DEVICE
-MAKEFILE=../../../$OUTDIR/$DEVICE-vendor-blobs.mk
+MAKEFILE=../../../$OUTDIR/$DEVICE-vendor.mk
(cat << EOF) >> $MAKEFILE
@@ -84,6 +66,7 @@ MAKEFILE=../../../$OUTDIR/$DEVICE-vendor-blobs.mk
# limitations under the License.
# Pick up overlay for features that depend on non-open-source files
+
PRODUCT_PACKAGES += \\
libloc_api_v02 \\
libtime_genoff \\
@@ -100,6 +83,7 @@ PRODUCT_PACKAGES += \\
libqti_performance \\
QPerformance
+endif
EOF
(cat << EOF) > ../../../$OUTDIR/BoardConfigVendor.mk
@@ -135,6 +119,8 @@ EOF
LOCAL_PATH := \$(call my-dir)
+ifeq (\$(TARGET_DEVICE),$DEVICE)
+
include \$(CLEAR_VARS)
LOCAL_MODULE := libloc_api_v02
LOCAL_MODULE_OWNER := zuk
@@ -297,4 +283,5 @@ include \$(BUILD_PREBUILT)
\$(shell mkdir -p \$(PRODUCT_OUT)/proprietary/lib/egl && pushd \$(PRODUCT_OUT)/proprietary/lib > /dev/null && ln -s egl/libEGL_adreno.so libEGL_adreno.so && popd > /dev/null)
\$(shell mkdir -p \$(PRODUCT_OUT)/proprietary/lib64/egl && pushd \$(PRODUCT_OUT)/proprietary/lib64 > /dev/null && ln -s egl/libEGL_adreno.so libEGL_adreno.so && popd > /dev/null)
+endif
EOF