On Tue, Feb 08, 2011 at 02:56:44PM -0800, Zach Carter wrote:
> On Tuesday, February 08, 2011 02:49:01 pm Roger Leigh wrote:
> > > sbuild-chroot-config.cc: In member function 'void 
> > > sbuild::chroot_config::add_config_directory(const string&, const
> > > string&)': sbuild-chroot-config.cc:170:49: error: no matching function
> > > for call to
> > > 'std::basic_string<char>::basic_string(boost::filesystem3::path)'
> > 
> > OK, they must have removed the explicit cast to string.  A little
> > annoying, since a filename is just a string.
> > 
> > I'll add a configure check.
> > 
> > Would you be OK to test a prerelease tarball once I've done that, since
> > I can't test it myself yet?  It'll probably be the weekend at the
> > earliest, given that I'm supported to be writing my PhD thesis, and
> > not coding ;-)
> 
> Sure, just let me know where to get it when it's ready.  I'm in no hurry, as 
> we already have a good Fedora build with my current patch.

OK, it proved not to require a configure check, just a conditional to
check the provided filesystem version.  Could you try the attached
patch and see if it builds correctly for you?


Thanks,
Roger

-- 
  .''`.  Roger Leigh
 : :' :  Debian GNU/Linux             http://people.debian.org/~rleigh/
 `. `'   Printing on GNU/Linux?       http://gutenprint.sourceforge.net/
   `-    GPG Public Key: 0x25BFB848   Please GPG sign your mail.
diff --git a/sbuild/sbuild-chroot-config.cc b/sbuild/sbuild-chroot-config.cc
index ed33e76..fe549f8 100644
--- a/sbuild/sbuild-chroot-config.cc
+++ b/sbuild/sbuild-chroot-config.cc
@@ -174,7 +174,11 @@ chroot_config::add_config_directory (std::string const& chroot_namespace,
        dirent != end_iter;
        ++dirent)
     {
+#if !defined(BOOST_FILESYSTEM_VERSION) || BOOST_FILESYSTEM_VERSION == 2
       std::string name(dirent->leaf());
+#else
+      std::string name(dirent->path().filename().string());
+#endif
 
       // Skip common directories.
       if (name == "." || name == "..")
diff --git a/sbuild/sbuild-run-parts.cc b/sbuild/sbuild-run-parts.cc
index e9fb10d..d23a76d 100644
--- a/sbuild/sbuild-run-parts.cc
+++ b/sbuild/sbuild-run-parts.cc
@@ -81,7 +81,11 @@ run_parts::run_parts (std::string const& directory,
        dirent != end_iter;
        ++dirent)
     {
+#if !defined(BOOST_FILESYSTEM_VERSION) || BOOST_FILESYSTEM_VERSION == 2
       std::string name(dirent->leaf());
+#else
+      std::string name(dirent->path().filename().string());
+#endif
 
       // Skip common directories.
       if (name == "." || name == "..")

Attachment: signature.asc
Description: Digital signature

Reply via email to