Browse Source

linux-header: improved to remove unneeded hidden files

Note:

By default the 'headers_install' make target installs hidden files within
the destination directories called '..install.cmd' and '.install' and the
'headers_check' make target is doing it similar, by installing files like
'..check.cmd' and '.check'.
Those files seem to be only interesting for kernel developers and are not
needed within the package, thus we are going to remove the files.
user/chris/test/arm
Christian Wiese 13 years ago
parent
commit
07941d6d93
  1. 17
      base/linux-header/linux-header.conf

17
base/linux-header/linux-header.conf

@ -2,7 +2,7 @@
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../linux-header/linux-header.conf
# Copyright (C) 2006 - 2008 The OpenSDE Project
# Copyright (C) 2006 - 2012 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
@ -42,3 +42,18 @@ var_append makeinstopt ' ' "INSTALL_HDR_PATH=$root/$prefix"
var_append makeinstopt ' ' "oldheaders= unwanted="
var_append makeinstopt ' ' "headers_check"
var_append makeinstopt ' ' "headers_install"
# remove unneeded hidden files
remove_unneeded_files() {
local pattern='.*\(\.cmd\|\/\.install\|\/\.check\)$'
local flist="$builddir/flist.txt"
# remove files from build sandbox
grep $pattern $flist | \
cut -d ' ' -f2 | \
while read f; do
rm -f $root/$f
done
# remove file entries from flist
sed -i -e '/$pattern/d' $flist
}
hook_add postflist 9 'remove_unneeded_files'

Loading…
Cancel
Save