diff options
author | Michal Marek <mmarek@suse.cz> | 2014-06-16 16:11:29 +0200 |
---|---|---|
committer | Michal Marek <mmarek@suse.cz> | 2014-06-18 16:01:58 +0200 |
commit | a765a7ce293aa0a072728790ce11088b2f7030e2 (patch) | |
tree | 67f41a4bc769138d667c69537877da91c93d9213 /scripts/package | |
parent | 7171511eaec5bf23fb06078f59784a3a0626b38f (diff) | |
download | blackbird-op-linux-a765a7ce293aa0a072728790ce11088b2f7030e2.tar.gz blackbird-op-linux-a765a7ce293aa0a072728790ce11088b2f7030e2.zip |
deb-pkg: Fix for relative paths
When $srctree or $objtree are relative paths, we cannot change directory
and refer to them in the same subshell. Do the redirection outside of
the subshell to fix this.
Reported-and-tested-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Michal Marek <mmarek@suse.cz>
Diffstat (limited to 'scripts/package')
-rw-r--r-- | scripts/package/builddeb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/scripts/package/builddeb b/scripts/package/builddeb index b5f08f727868..9a38e85c800e 100644 --- a/scripts/package/builddeb +++ b/scripts/package/builddeb @@ -290,13 +290,13 @@ EOF fi # Build header package -(cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl > "$objtree/debian/hdrsrcfiles") -(cd $srctree; find arch/$SRCARCH/include include scripts -type f >> "$objtree/debian/hdrsrcfiles") -(cd $objtree; find arch/$SRCARCH/include Module.symvers include scripts -type f >> "$objtree/debian/hdrobjfiles") +(cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl) > "$objtree/debian/hdrsrcfiles" +(cd $srctree; find arch/$SRCARCH/include include scripts -type f) >> "$objtree/debian/hdrsrcfiles" +(cd $objtree; find arch/$SRCARCH/include Module.symvers include scripts -type f) >> "$objtree/debian/hdrobjfiles" destdir=$kernel_headers_dir/usr/src/linux-headers-$version mkdir -p "$destdir" -(cd $srctree; tar -c -f - -T "$objtree/debian/hdrsrcfiles") | (cd $destdir; tar -xf -) -(cd $objtree; tar -c -f - -T "$objtree/debian/hdrobjfiles") | (cd $destdir; tar -xf -) +(cd $srctree; tar -c -f - -T -) < "$objtree/debian/hdrsrcfiles" | (cd $destdir; tar -xf -) +(cd $objtree; tar -c -f - -T -) < "$objtree/debian/hdrobjfiles" | (cd $destdir; tar -xf -) (cd $objtree; cp $KCONFIG_CONFIG $destdir/.config) # copy .config manually to be where it's expected to be ln -sf "/usr/src/linux-headers-$version" "$kernel_headers_dir/lib/modules/$version/build" rm -f "$objtree/debian/hdrsrcfiles" "$objtree/debian/hdrobjfiles" |