leaving the chroot in place if pdebuild fails?

172 Views Asked by At

I am doing automated builds with pdebuild. Sometimes these builds fail. In these cases I would like to keep the chroot to be able to investigate the cause of failure. I was trying to run pdebuild with --debug, which is -according to pbuilder manpage - is expected to do just that, but it had no effect. How can I tell pdebuild to leave the build environment in place?

1

There are 1 best solutions below

2
On

According to this -mentors mailing list post, you can use the supplied C10shell hook:

cp /usr/share/doc/pbuilder/examples/C10shell path/to/hook/dir

(I use cp instead of ln -s only because I often edit the hooks myself.)

This will start an interactive shell upon failure.