1 #!/bin/bash 2 3 # Change into the libandroid_support directory. 4 DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 5 cd $DIR 6 7 # Pull the notices from the files in libandroid_support itself (via `.`), 8 # plus all the bionic files we pull in. 9 sed '/$(BIONIC_PATH).*\.c/ { s| *$(BIONIC_PATH)|../../../../bionic/| ; s| *\\$|| ; p } ; d' Android.mk | \ 10 xargs ../../../../bionic/libc/tools/generate-NOTICE.py . > NOTICE 11 12 # Show the caller what we've done. 13 git diff --exit-code HEAD ./NOTICE 14 exit $? 15