Here's another patch to ensure symlinks are not installed when creating file 
type chroots with sbuild-createchroot. Again, this should be applied after all 
other patches are applied.

I can also supply all patches again in the order they should be applied if 
it's desired.

-- 
Regards,
Andres
From 604f901bf63fd5c7ec941b6d1e1ba93902e78825 Mon Sep 17 00:00:00 2001
From: Andres Mejia <and...@andres-desktop.hsd1.va.comcast.net>
Date: Thu, 17 Sep 2009 21:32:47 -0400
Subject: [PATCH] Don't create a symlink in /etc/sbuild/chroot when creating file type chroots.

---
 bin/sbuild-createchroot |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/bin/sbuild-createchroot b/bin/sbuild-createchroot
index c428828..f53e055 100755
--- a/bin/sbuild-createchroot
+++ b/bin/sbuild-createchroot
@@ -342,14 +342,15 @@ if (-l $chrootlink) {
     print STDERR "E: Can't remove $chrootlink: not a symbolic link\n";
 }
 
-if (! -f $chrootlink) {
+if ((! -f $chrootlink) && (! $conf->get('MAKE_TARBALL'))) {
     if (symlink($target, $chrootlink)) {
 	print "I: sudo chroot configuration linked as $Sbuild::Sysconfig::paths{'SBUILD_SYSCONF_DIR'}/chroot/$chrootname.\n";
     } else {
 	print STDERR "E: Failed to symlink $target to $chrootlink: $!\n";
     }
 } else {
-    print "W: Failed to symlink $target to $chrootlink: \n"
+    print "W: Failed to symlink $target to $chrootlink: \n" unless
+	defined $conf->get('MAKE_TARBALL');
 }
 
 if ($conf->get('ARCH') eq $conf->get('HOST_ARCH')) {
-- 
1.6.4.3

Reply via email to