ANDROID: kbuild: use modules.order in adjust_autoksyms.sh
This is essentially a partial backport of b7dca6dd1e ("kbuild: create
*.mod with full directory path and remove MODVERDIR") as a full backport
would pull in too many dependencies.
It is necessary to simplify the backport of the TRIM_NONLISTED_KMI
feature.
Bug: 148277666
Change-Id: Ibf85bf864b3961d5bec4965742f08a80e9f234af
Signed-off-by: Quentin Perret <qperret@google.com>
This commit is contained in:
parent
390b115181
commit
9d9f11f7d8
1 changed files with 5 additions and 9 deletions
|
|
@ -10,8 +10,7 @@
|
|||
# published by the Free Software Foundation.
|
||||
|
||||
# Create/update the include/generated/autoksyms.h file from the list
|
||||
# of all module's needed symbols as recorded on the third line of
|
||||
# .tmp_versions/*.mod files.
|
||||
# of all module's needed symbols as recorded on the third line of *.mod files.
|
||||
#
|
||||
# For each symbol being added or removed, the corresponding dependency
|
||||
# file's timestamp is updated to force a rebuild of the affected source
|
||||
|
|
@ -49,13 +48,10 @@ cat > "$new_ksyms_file" << EOT
|
|||
*/
|
||||
|
||||
EOT
|
||||
[ "$(ls -A "$MODVERDIR")" ] &&
|
||||
for mod in "$MODVERDIR"/*.mod; do
|
||||
sed -n -e '3{s/ /\n/g;/^$/!p;}' "$mod"
|
||||
done | sort -u |
|
||||
while read sym; do
|
||||
echo "#define __KSYM_${sym} 1"
|
||||
done >> "$new_ksyms_file"
|
||||
sed 's/ko$/mod/' modules.order |
|
||||
xargs -n1 sed -n -e '3{s/ /\n/g;/^$/!p;}' -- |
|
||||
sort -u |
|
||||
sed -e 's/\(.*\)/#define __KSYM_\1 1/' >> "$new_ksyms_file"
|
||||
|
||||
# Special case for modversions (see modpost.c)
|
||||
if [ -n "$CONFIG_MODVERSIONS" ]; then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue