diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2016-08-02 16:48:52 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-08-02 16:48:52 -0400 |
| commit | 44cee85a8824464e7e951e590243c2a85d79c494 (patch) | |
| tree | 0ee07cb0a45f7fd9658b0460c288e52ffaf5c4b3 /scripts/package | |
| parent | f716a85cd6045c994011268223706642cff7e485 (diff) | |
| parent | 4c586062b275dcddc18f521ac092cf0f600a36de (diff) | |
Merge branch 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
Pull misc kbuild updates from Michal Marek:
- coccicheck script improvements by Luis Rodriguez and Deepa Dinamani
- new coccinelle patches by Yann Droneaud and Vaishali Thakkar
- debian packaging fixes by Wilfried Klaebe, Henning Schild and Marcin
Mielniczuk
* 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
Fix the Debian packaging script on systems with no codename
builddeb: fix file permissions before packaging
scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci
coccicheck: refer to Documentation/coccinelle.txt and wiki
coccicheck: add support for requring a coccinelle version
scripts: add Linux .cocciconfig for coccinelle
coccicheck: replace --very-quiet with --quiet when debugging
coccicheck: add support for DEBUG_FILE
coccicheck: enable parmap support
coccicheck: make SPFLAGS more useful
coccicheck: move spatch binary check up
builddeb: really include objtool binary in headers package
coccinelle: catch krealloc() on devm_*() allocated memory
coccinelle: recognize more devm_* memory allocation functions
coccinelle: also catch kzfree() issues
coccicheck: Allow for overriding spatch flags
Coccinelle: noderef: Add new rules and correct the old rule
Diffstat (limited to 'scripts/package')
| -rwxr-xr-x | scripts/package/builddeb | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/scripts/package/builddeb b/scripts/package/builddeb index 4d4418a8d54d..e1c09e2f9be7 100755 --- a/scripts/package/builddeb +++ b/scripts/package/builddeb | |||
| @@ -26,6 +26,8 @@ create_package() { | |||
| 26 | # Fix ownership and permissions | 26 | # Fix ownership and permissions |
| 27 | chown -R root:root "$pdir" | 27 | chown -R root:root "$pdir" |
| 28 | chmod -R go-w "$pdir" | 28 | chmod -R go-w "$pdir" |
| 29 | # in case we are in a restrictive umask environment like 0077 | ||
| 30 | chmod -R a+rX "$pdir" | ||
| 29 | 31 | ||
| 30 | # Create the package | 32 | # Create the package |
| 31 | dpkg-gencontrol $forcearch -Vkernel:debarch="${debarch}" -p$pname -P"$pdir" | 33 | dpkg-gencontrol $forcearch -Vkernel:debarch="${debarch}" -p$pname -P"$pdir" |
| @@ -238,7 +240,8 @@ maintainer="$name <$email>" | |||
| 238 | # Try to determine distribution | 240 | # Try to determine distribution |
| 239 | if [ -n "$KDEB_CHANGELOG_DIST" ]; then | 241 | if [ -n "$KDEB_CHANGELOG_DIST" ]; then |
| 240 | distribution=$KDEB_CHANGELOG_DIST | 242 | distribution=$KDEB_CHANGELOG_DIST |
| 241 | elif distribution=$(lsb_release -cs 2>/dev/null) && [ -n "$distribution" ]; then | 243 | # In some cases lsb_release returns the codename as n/a, which breaks dpkg-parsechangelog |
| 244 | elif distribution=$(lsb_release -cs 2>/dev/null) && [ -n "$distribution" ] && [ "$distribution" != "n/a" ]; then | ||
| 242 | : # nothing to do in this case | 245 | : # nothing to do in this case |
| 243 | else | 246 | else |
| 244 | distribution="unstable" | 247 | distribution="unstable" |
| @@ -322,12 +325,12 @@ fi | |||
| 322 | 325 | ||
| 323 | # Build kernel header package | 326 | # Build kernel header package |
| 324 | (cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl) > "$objtree/debian/hdrsrcfiles" | 327 | (cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl) > "$objtree/debian/hdrsrcfiles" |
| 325 | if grep -q '^CONFIG_STACK_VALIDATION=y' $KCONFIG_CONFIG ; then | ||
| 326 | (cd $srctree; find tools/objtool -type f -executable) >> "$objtree/debian/hdrsrcfiles" | ||
| 327 | fi | ||
| 328 | (cd $srctree; find arch/*/include include scripts -type f) >> "$objtree/debian/hdrsrcfiles" | 328 | (cd $srctree; find arch/*/include include scripts -type f) >> "$objtree/debian/hdrsrcfiles" |
| 329 | (cd $srctree; find arch/$SRCARCH -name module.lds -o -name Kbuild.platforms -o -name Platform) >> "$objtree/debian/hdrsrcfiles" | 329 | (cd $srctree; find arch/$SRCARCH -name module.lds -o -name Kbuild.platforms -o -name Platform) >> "$objtree/debian/hdrsrcfiles" |
| 330 | (cd $srctree; find $(find arch/$SRCARCH -name include -o -name scripts -type d) -type f) >> "$objtree/debian/hdrsrcfiles" | 330 | (cd $srctree; find $(find arch/$SRCARCH -name include -o -name scripts -type d) -type f) >> "$objtree/debian/hdrsrcfiles" |
| 331 | if grep -q '^CONFIG_STACK_VALIDATION=y' $KCONFIG_CONFIG ; then | ||
| 332 | (cd $objtree; find tools/objtool -type f -executable) >> "$objtree/debian/hdrobjfiles" | ||
| 333 | fi | ||
| 331 | (cd $objtree; find arch/$SRCARCH/include Module.symvers include scripts -type f) >> "$objtree/debian/hdrobjfiles" | 334 | (cd $objtree; find arch/$SRCARCH/include Module.symvers include scripts -type f) >> "$objtree/debian/hdrobjfiles" |
| 332 | (cd $objtree; find scripts/gcc-plugins -name \*.so -o -name gcc-common.h) >> "$objtree/debian/hdrobjfiles" | 335 | (cd $objtree; find scripts/gcc-plugins -name \*.so -o -name gcc-common.h) >> "$objtree/debian/hdrobjfiles" |
| 333 | destdir=$kernel_headers_dir/usr/src/linux-headers-$version | 336 | destdir=$kernel_headers_dir/usr/src/linux-headers-$version |
