6

I'm following this tutorial on the Ubuntu on how to fix a bug, but am encountering a problem when I try to build the source package. In the section entitled 'Testing the fix', the reader is told to execute two command to complete the build:

$ bzr builddeb -- -S -us -uc
$ pbuilder-dist <release> build ../<package>_<version>.dsc

The first one works fine, and I get a nice collection of packages, including the .dsc file needed to build. However when I fill in the palceholders in the second one and execute it, so it looks like this:

pbuilder-dist precise build ../gedit_3.1.1-0ubuntu4.dsc

I get the following output:

W: /home/notgary/.pbuilderrc does not exist
E: File /home/notgary/pbuilder/precise-base.tgz does not exist

I've followed the PbuilderHowTo on the wiki and have created (I think) a Precise tarball using

sudo pbuilder create --distribution precise

but the only contents of my ~/pbuilder directory is precise_result

What have I done wrong when setting up my build environment, and what do I need to do to fix it so I can build Precise packages using pbuilder?

1 Answers1

9

You first need to create a pbuilder instance locally. To do that, run the command:

pbuilder-dist precise create

This will create the .pbuilderrc and the ~/pbuilder/precise-base.tgz that you are missing.

After that, you can build your .dsc as normal:

pbuilder-dist precise build ../gedit_3.1.1-0ubuntu4.dsc
jokerdino
  • 41,000
  • 24
  • 132
  • 201
  • 1
    This is correct. One thing to add is that the way you created the pbuilder tarball put it in `/var/cache/pbuilder/` If you don't want to go through building it all over again (as it takes some time), you can manually copy it to `~/pbuilder` making sure it is named `precise-base.tgz` pbuilder-dist should then be able to find it correctly. – andrewsomething Apr 13 '12 at 15:09
  • `~/.pbuilderrc` is not created even after `pbuilder-dist trusty create`. should I've to do anything else to stop `w: ~/.pbuilderrc does not exist`? – Necktwi Sep 10 '14 at 19:19
  • @neckTwi, without any kind of context, I am unable to help. Can you create a new question with everything you have tried, the steps you followed, etc? – jokerdino Sep 11 '14 at 13:10