2016-08-10 17:02:31 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
if [ ! -d hardware/interfaces ] ; then
|
|
|
|
echo "Where is hardware/interfaces?";
|
|
|
|
exit 1;
|
|
|
|
fi
|
|
|
|
|
|
|
|
packages=$(pushd hardware/interfaces > /dev/null; \
|
2016-08-31 18:10:55 +02:00
|
|
|
find . -type f -name Android.mk -exec dirname {} \; | \
|
2016-08-10 17:02:31 +02:00
|
|
|
cut -c3- | \
|
|
|
|
awk -F'/' \
|
|
|
|
'{printf("android.hardware"); for(i=1;i<NF;i++){printf(".%s", $i);}; printf("@%s\n", $NF);}'; \
|
|
|
|
popd > /dev/null)
|
|
|
|
|
|
|
|
for p in $packages; do
|
|
|
|
echo "Updating $p";
|
|
|
|
hidl-gen -Lmakefile -r android.hardware:hardware/interfaces $p;
|
|
|
|
done
|