* [PATCH] deb-pkg: Don't run find across mountpoints
@ 2013-06-09 16:14 Gabriel de Perthuis
2013-06-10 13:07 ` Michal Marek
0 siblings, 1 reply; 6+ messages in thread
From: Gabriel de Perthuis @ 2013-06-09 16:14 UTC (permalink / raw)
To: Michal Marek; +Cc: linux-kbuild
Signed-off-by: Gabriel de Perthuis <g2p.code@gmail.com>
---
scripts/package/builddeb | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/package/builddeb b/scripts/package/builddeb
index acb8650..1435f5a 100644
--- a/scripts/package/builddeb
+++ b/scripts/package/builddeb
@@ -16,11 +16,11 @@ create_package() {
local pname="$1" pdir="$2"
cp debian/copyright "$pdir/usr/share/doc/$pname/"
cp debian/changelog "$pdir/usr/share/doc/$pname/changelog.Debian"
gzip -9 "$pdir/usr/share/doc/$pname/changelog.Debian"
- sh -c "cd '$pdir'; find . -type f ! -path './DEBIAN/*' -printf '%P\0' \
+ sh -c "cd '$pdir'; find . -xdev -type f ! -path './DEBIAN/*' -printf '%P\0' \
| xargs -r0 md5sum > DEBIAN/md5sums"
# Fix ownership and permissions
chown -R root:root "$pdir"
chmod -R go-w "$pdir"
@@ -241,11 +241,11 @@ Description: Linux kernel, version $version
EOF
fi
# Build header package
-(cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl > "$objtree/debian/hdrsrcfiles")
+(cd $srctree; find . -xdev -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 .config 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 -)
--
1.8.3.222.g430da9e
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] deb-pkg: Don't run find across mountpoints
2013-06-09 16:14 [PATCH] deb-pkg: Don't run find across mountpoints Gabriel de Perthuis
@ 2013-06-10 13:07 ` Michal Marek
2013-06-10 13:15 ` Gabriel de Perthuis
0 siblings, 1 reply; 6+ messages in thread
From: Michal Marek @ 2013-06-10 13:07 UTC (permalink / raw)
To: Gabriel de Perthuis; +Cc: linux-kbuild
On 9.6.2013 18:14, Gabriel de Perthuis wrote:
> Signed-off-by: Gabriel de Perthuis <g2p.code@gmail.com>
> ---
> scripts/package/builddeb | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/scripts/package/builddeb b/scripts/package/builddeb
> index acb8650..1435f5a 100644
> --- a/scripts/package/builddeb
> +++ b/scripts/package/builddeb
> @@ -16,11 +16,11 @@ create_package() {
> local pname="$1" pdir="$2"
>
> cp debian/copyright "$pdir/usr/share/doc/$pname/"
> cp debian/changelog "$pdir/usr/share/doc/$pname/changelog.Debian"
> gzip -9 "$pdir/usr/share/doc/$pname/changelog.Debian"
> - sh -c "cd '$pdir'; find . -type f ! -path './DEBIAN/*' -printf '%P\0' \
> + sh -c "cd '$pdir'; find . -xdev -type f ! -path './DEBIAN/*' -printf '%P\0' \
What kind of mountpoint zoo do you maintain in your build tree? :) We
run a find in make clean, make mrproper and other targets. So you might
need to fix more places. But please explain your use case.
Michal
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] deb-pkg: Don't run find across mountpoints
2013-06-10 13:07 ` Michal Marek
@ 2013-06-10 13:15 ` Gabriel de Perthuis
2013-06-10 13:20 ` Gabriel de Perthuis
0 siblings, 1 reply; 6+ messages in thread
From: Gabriel de Perthuis @ 2013-06-10 13:15 UTC (permalink / raw)
To: Michal Marek; +Cc: linux-kbuild
Le lun. 10 juin 2013 15:07:56 CEST, Michal Marek a écrit :
> What kind of mountpoint zoo do you maintain in your build tree? :) We
> run a find in make clean, make mrproper and other targets. So you might
> need to fix more places. But please explain your use case.
>
> Michal
I happened to be running a fuse thing (git fs, mounted under .git/fs);
recursing that can take a *long* time.
`find .` is the only one that actually runs into trouble, although it
might be good if -xdev could be the default (through a shell
function maybe?).
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] deb-pkg: Don't run find across mountpoints
2013-06-10 13:15 ` Gabriel de Perthuis
@ 2013-06-10 13:20 ` Gabriel de Perthuis
2013-06-10 13:23 ` Michal Marek
0 siblings, 1 reply; 6+ messages in thread
From: Gabriel de Perthuis @ 2013-06-10 13:20 UTC (permalink / raw)
To: Michal Marek; +Cc: linux-kbuild
Le 10/06/2013 15:15, Gabriel de Perthuis a écrit :
> Le lun. 10 juin 2013 15:07:56 CEST, Michal Marek a écrit :
>> What kind of mountpoint zoo do you maintain in your build tree? :) We
>> run a find in make clean, make mrproper and other targets. So you might
>> need to fix more places. But please explain your use case.
>
> I happened to be running a fuse thing (git fs, mounted under .git/fs);
> recursing that can take a *long* time.
>
> `find .` is the only one that actually runs into trouble, although it
> might be good if -xdev could be the default (through a shell
> function maybe?).
Or it would be even better if the scripts used `git ls-files`, if
it seems a reasonable requirement to have the kernel build from git.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] deb-pkg: Don't run find across mountpoints
2013-06-10 13:20 ` Gabriel de Perthuis
@ 2013-06-10 13:23 ` Michal Marek
2013-06-10 14:19 ` Gabriel de Perthuis
0 siblings, 1 reply; 6+ messages in thread
From: Michal Marek @ 2013-06-10 13:23 UTC (permalink / raw)
To: Gabriel de Perthuis; +Cc: linux-kbuild
On 10.6.2013 15:20, Gabriel de Perthuis wrote:
> Le 10/06/2013 15:15, Gabriel de Perthuis a écrit :
>> Le lun. 10 juin 2013 15:07:56 CEST, Michal Marek a écrit :
>>> What kind of mountpoint zoo do you maintain in your build tree? :) We
>>> run a find in make clean, make mrproper and other targets. So you might
>>> need to fix more places. But please explain your use case.
>>
>> I happened to be running a fuse thing (git fs, mounted under .git/fs);
>> recursing that can take a *long* time.
>>
>> `find .` is the only one that actually runs into trouble, although it
>> might be good if -xdev could be the default (through a shell
>> function maybe?).
So make deb-pkg saves the md5sums of all files under .git?? Then the
right fix would be to export RCS_FIND_IGNORE and use it in the builddeb
script.
> Or it would be even better if the scripts used `git ls-files`, if
> it seems a reasonable requirement to have the kernel build from git.
No, the build has to work without any git repository.
Michal
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] deb-pkg: Don't run find across mountpoints
2013-06-10 13:23 ` Michal Marek
@ 2013-06-10 14:19 ` Gabriel de Perthuis
0 siblings, 0 replies; 6+ messages in thread
From: Gabriel de Perthuis @ 2013-06-10 14:19 UTC (permalink / raw)
To: Michal Marek; +Cc: linux-kbuild
Le 10/06/2013 15:23, Michal Marek a écrit :
> On 10.6.2013 15:20, Gabriel de Perthuis wrote:
>> Le 10/06/2013 15:15, Gabriel de Perthuis a écrit :
>>> Le lun. 10 juin 2013 15:07:56 CEST, Michal Marek a écrit :
>>>> What kind of mountpoint zoo do you maintain in your build tree? :) We
>>>> run a find in make clean, make mrproper and other targets. So you might
>>>> need to fix more places. But please explain your use case.
>>>
>>> I happened to be running a fuse thing (git fs, mounted under .git/fs);
>>> recursing that can take a *long* time.
>>>
>>> `find .` is the only one that actually runs into trouble, although it
>>> might be good if -xdev could be the default (through a shell
>>> function maybe?).
>
> So make deb-pkg saves the md5sums of all files under .git?? Then the
> right fix would be to export RCS_FIND_IGNORE and use it in the builddeb
> script.
Sounds like a good idea. It doesn't work as is because the backslashes
in \( seem to be delayed by make and can't be used as is, removing the
backslashes doesn't work either, and it takes a long time to test.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2013-06-10 14:19 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-09 16:14 [PATCH] deb-pkg: Don't run find across mountpoints Gabriel de Perthuis
2013-06-10 13:07 ` Michal Marek
2013-06-10 13:15 ` Gabriel de Perthuis
2013-06-10 13:20 ` Gabriel de Perthuis
2013-06-10 13:23 ` Michal Marek
2013-06-10 14:19 ` Gabriel de Perthuis
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox