OSDN Git Service

am 71b1f9be: Explicitly exclude NFC stuff.
[android-x86/device-common.git] / generate-blob-scripts.sh
index c80d3ee..d81621f 100755 (executable)
@@ -16,7 +16,7 @@
 
 # This script auto-generates the scripts that manage the handling of the
 # proprietary blobs necessary to build the Android Open-Source Project code
-# for dream, passion and sapphire targets
+# for passion and crespo targets
 
 # It needs to be run from the root of a source tree that can repo sync,
 # runs builds with and without the vendor tree, and uses the difference
@@ -43,7 +43,7 @@ then
 fi
 shift
 
-DEVICES="passion crespo"
+DEVICES="passion crespo crespo4g stingray"
 
 ARCHIVEDIR=archive-$(date +%s)
 mkdir $ARCHIVEDIR
@@ -56,20 +56,20 @@ for DEVICENAME in $DEVICES
 do
   rm -rf out
   lunch full_$DEVICENAME-user
-  make -j8
+  make -j32
   cat out/target/product/$DEVICENAME/installed-files.txt |
     cut -b 15- |
-    sort > $ARCHIVEDIR/$DEVICENAME-with.txt
+    sort -f > $ARCHIVEDIR/$DEVICENAME-with.txt
 done
 rm -rf vendor
 for DEVICENAME in $DEVICES
 do
   rm -rf out
   lunch full_$DEVICENAME-user
-  make -j8
+  make -j32
   cat out/target/product/$DEVICENAME/installed-files.txt |
     cut -b 15- |
-    sort > $ARCHIVEDIR/$DEVICENAME-without.txt
+    sort -f > $ARCHIVEDIR/$DEVICENAME-without.txt
 done
 
 for DEVICENAME in $DEVICES
@@ -102,6 +102,10 @@ do
     echo 'mkdir -p ../../../vendor/$MANUFACTURER/$DEVICE/proprietary'
 
     diff $ARCHIVEDIR/$DEVICENAME-without.txt $ARCHIVEDIR/$DEVICENAME-with.txt |
+      grep -v Nfc\.apk\$ |
+      grep -v Tag\.apk\$ |
+      grep -v libnfc\.so\$ |
+      grep -v libnfc_jni\.so\$ |
       grep '>' |
       cut -b 3- |
       while read FULLPATH
@@ -112,7 +116,7 @@ do
         else
           echo unzip -j -o ../../../\${DEVICE}_update.zip $(echo $FULLPATH | cut -b 2-) -d ../../../vendor/\$MANUFACTURER/\$DEVICE/proprietary
         fi
-        if test $(basename $FULLPATH) = akmd -o $(basename $FULLPATH) = mm-venc-omx-test -o $(basename $FULLPATH) = parse_radio_log
+        if test $(basename $FULLPATH) = akmd -o $(basename $FULLPATH) = mm-venc-omx-test -o $(basename $FULLPATH) = parse_radio_log -o $(basename $FULLPATH) = akmd8973 -o $(basename $FULLPATH) = gpsd -o $(basename $FULLPATH) = pvrsrvinit
         then
           echo chmod 755 ../../../vendor/\$MANUFACTURER/\$DEVICE/proprietary/$(basename $FULLPATH)
         fi
@@ -120,7 +124,7 @@ do
     echo
 
     echo -n '(cat << EOF) | sed s/__DEVICE__/$DEVICE/g | sed s/__MANUFACTURER__/$MANUFACTURER/g > ../../../vendor/$MANUFACTURER/$DEVICE/'
-    echo '$DEVICE-vendor-blobs.mk'
+    echo 'device-vendor-blobs.mk'
 
     echo '# Copyright (C) 2010 The Android Open Source Project'
     echo '#'
@@ -142,11 +146,15 @@ do
 
     FOUND=false
     diff $ARCHIVEDIR/$DEVICENAME-without.txt $ARCHIVEDIR/$DEVICENAME-with.txt |
+      grep -v Nfc\.apk\$ |
+      grep -v Tag\.apk\$ |
+      grep -v libnfc\.so\$ |
+      grep -v libnfc_jni\.so\$ |
       grep '>' |
       cut -b 3- |
       while read FULLPATH
       do
-        if test $(basename $FULLPATH) = libgps.so -o $(basename $FULLPATH) = libcamera.so
+        if test $(basename $FULLPATH) = libgps.so -o $(basename $FULLPATH) = libcamera.so -o $(basename $FULLPATH) = libsecril-client.so
         then
           if test $FOUND = false
           then
@@ -164,6 +172,10 @@ do
 
     FOUND=false
     diff $ARCHIVEDIR/$DEVICENAME-without.txt $ARCHIVEDIR/$DEVICENAME-with.txt |
+      grep -v Nfc\.apk\$ |
+      grep -v Tag\.apk\$ |
+      grep -v libnfc\.so\$ |
+      grep -v libnfc_jni\.so\$ |
       grep '>' |
       cut -b 3- |
       while read FULLPATH