[tbb-dev] Trouble building Tor Browser on Debian stretch

David Fifield david at bamsoftware.com
Wed Apr 27 00:08:23 UTC 2016


On Sun, Apr 10, 2016 at 11:59:09PM -0700, David Fifield wrote:
> I'm trying to build Tor Browser (tbb-6.0a4-build1) on Debian stretch,
> and running into problems. I tried some workarounds but it seems like I
> must be trying to do something unsupported. I'm not trying to reproduce
> a package; just test a patch. Can anyone shed some light?
> 
> One of the problems seems actionable so I made a ticket:
> https://bugs.torproject.org/18786.
> 
> I had to install the vmbuilder script manually, so I did what
> check-prerequisites.sh told me to do:
> 	torsocks wget -U "" https://bugs.launchpad.net/ubuntu/+archive/primary/+files/vm-builder_0.12.4+bzr494.orig.tar.gz
> 	echo "76cbf8c52c391160b2641e7120dbade5afded713afaa6032f733a261f13e6a8e  vm-builder_0.12.4+bzr494.orig.tar.gz" | sha256sum -c
> 	tar -zxvf vm-builder_0.12.4+bzr494.orig.tar.gz
> 	cd vm-builder-0.12.4+bzr494
> 	sudo python setup.py install
> 
> I ran into two problems that I tried to fix by patching vmbuilder. The
> first is that the call to "update-grub -y" would fail. I traced the
> problem to a lack of /dev inside the chroot; update-grub runs
> 	grub-probe --device-map=/boot/grub/device.map -t device /
> which fails with
> 	grub-probe: error: cannot find a device for / (is /dev mounted?).
> For this, I copy-pasted some code to bind-mount /dev before the call and
> unmount it after.
> 
> Then I had a problem during the dist-upgrade for the ubuntu precise VMs.
> The "initscripts" package was failing to upgrade from 2.88dsf-13.10ubuntu11
> to 2.88dsf-13.10ubuntu11.1:
> 	Setting up initscripts (2.88dsf-13.10ubuntu11.1) ...
> 	Processing triggers for libc-bin ...
> 	ldconfig deferred processing now taking place
> 	Extracting templates from packages: 100%
> 
> 	Current default time zone: 'Etc/UTC'
> 	Local time is now:      Mon Apr 11 01:35:59 UTC 2016.
> 	Universal Time is now:  Mon Apr 11 01:35:59 UTC 2016.
> 	Run 'dpkg-reconfigure tzdata' if you wish to change it.
> 
> 	invoke-rc.d: policy-rc.d denied execution of stop.
> 	mkdir: cannot create directory `/run/shm': File exists
> The specific error is that mkdir is trying to create a directory over an
> existing symlink. It's related to some confusion between /dev/shm and
> /run/shm: https://bugs.launchpad.net/bugs/974584. Here I spliced in a
> hack to remove the symlink and create the directory before upgrading
> initscripts.

I never fully solved these problems. Even with the vmbuilder patches,
the Ubuntu VMs would spin with 100% CPU at the BIOS screen, not even
allowing SSH. But the preparation of the VMs was the only problem. I
installed a fresh Ubuntu 14.04 on another computer, used it to build the
VM images, copied the images to the build host that was giving me
trouble before, and then I was able to complete a build.


More information about the tbb-dev mailing list