]> git.lyx.org Git - features.git/commitdiff
We don't use boost::filesystem anymore.
authorAbdelrazak Younes <younes@lyx.org>
Fri, 23 May 2008 12:07:29 +0000 (12:07 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Fri, 23 May 2008 12:07:29 +0000 (12:07 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24909 a592a061-630c-0410-9148-cb99ea01b6c8

12 files changed:
boost/Makefile.am
boost/libs/filesystem/filesystem.vcproj [deleted file]
boost/libs/filesystem/src/exception.cpp [deleted file]
boost/libs/filesystem/src/operations.cpp [deleted file]
boost/libs/filesystem/src/path.cpp [deleted file]
boost/libs/filesystem/src/portability.cpp [deleted file]
boost/lyxboost.cpp
boost/pch.h
development/cmake/boost/libs/CMakeLists.txt
development/cmake/boost/libs/filesystem/CMakeLists.txt [deleted file]
development/scons/SConstruct
development/scons/scons_manifest.py

index 84d6e3a682ea83363e203929736fcfc1c88044f8..770c41a9bd2f5b9b7ebef0c61d235e0cb309e3c1 100644 (file)
@@ -25,11 +25,6 @@ liblyxboost_la_SOURCES = \
 else
 
 liblyxboost_la_SOURCES = \
-       \
-       libs/filesystem/src/exception.cpp \
-       libs/filesystem/src/operations.cpp \
-       libs/filesystem/src/path.cpp \
-       libs/filesystem/src/portability.cpp \
        \
        libs/regex/src/c_regex_traits.cpp \
        libs/regex/src/cpp_regex_traits.cpp \
diff --git a/boost/libs/filesystem/filesystem.vcproj b/boost/libs/filesystem/filesystem.vcproj
deleted file mode 100644 (file)
index 5f052e6..0000000
+++ /dev/null
@@ -1,120 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>
-<VisualStudioProject
-       ProjectType="Visual C++"
-       Version="7.10"
-       Name="libboost_filesystem"
-       ProjectGUID="{684579F5-D732-45CE-BBFB-9419BB98DADC}"
-       Keyword="Win32Proj">
-       <Platforms>
-               <Platform
-                       Name="Win32"/>
-       </Platforms>
-       <Configurations>
-               <Configuration
-                       Name="Debug|Win32"
-                       OutputDirectory="Debug"
-                       IntermediateDirectory="Debug"
-                       ConfigurationType="4"
-                       CharacterSet="2">
-                       <Tool
-                               Name="VCCLCompilerTool"
-                               Optimization="0"
-                               AdditionalIncludeDirectories="..\.."
-                               PreprocessorDefinitions="WIN32;_DEBUG;_LIB"
-                               MinimalRebuild="TRUE"
-                               BasicRuntimeChecks="0"
-                               RuntimeLibrary="2"
-                               BufferSecurityCheck="FALSE"
-                               TreatWChar_tAsBuiltInType="TRUE"
-                               ForceConformanceInForLoopScope="TRUE"
-                               RuntimeTypeInfo="TRUE"
-                               UsePrecompiledHeader="0"
-                               WarningLevel="3"
-                               Detect64BitPortabilityProblems="TRUE"
-                               DebugInformationFormat="3"/>
-                       <Tool
-                               Name="VCCustomBuildTool"/>
-                       <Tool
-                               Name="VCLibrarianTool"
-                               OutputFile="$(OutDir)/libboost_filesystem-vc71-mt-gd-1_32.lib"/>
-                       <Tool
-                               Name="VCMIDLTool"/>
-                       <Tool
-                               Name="VCPostBuildEventTool"/>
-                       <Tool
-                               Name="VCPreBuildEventTool"/>
-                       <Tool
-                               Name="VCPreLinkEventTool"/>
-                       <Tool
-                               Name="VCResourceCompilerTool"/>
-                       <Tool
-                               Name="VCWebServiceProxyGeneratorTool"/>
-                       <Tool
-                               Name="VCXMLDataGeneratorTool"/>
-                       <Tool
-                               Name="VCManagedWrapperGeneratorTool"/>
-                       <Tool
-                               Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
-               </Configuration>
-               <Configuration
-                       Name="Release|Win32"
-                       OutputDirectory="Release"
-                       IntermediateDirectory="Release"
-                       ConfigurationType="4"
-                       CharacterSet="2">
-                       <Tool
-                               Name="VCCLCompilerTool"
-                               AdditionalIncludeDirectories="..\.."
-                               PreprocessorDefinitions="WIN32;NDEBUG;_LIB"
-                               RuntimeLibrary="2"
-                               TreatWChar_tAsBuiltInType="TRUE"
-                               ForceConformanceInForLoopScope="TRUE"
-                               RuntimeTypeInfo="TRUE"
-                               UsePrecompiledHeader="0"
-                               WarningLevel="3"
-                               Detect64BitPortabilityProblems="TRUE"
-                               DebugInformationFormat="3"/>
-                       <Tool
-                               Name="VCCustomBuildTool"/>
-                       <Tool
-                               Name="VCLibrarianTool"
-                               OutputFile="$(OutDir)/libboost_filesystem-vc71-mt-1_32.lib"/>
-                       <Tool
-                               Name="VCMIDLTool"/>
-                       <Tool
-                               Name="VCPostBuildEventTool"/>
-                       <Tool
-                               Name="VCPreBuildEventTool"/>
-                       <Tool
-                               Name="VCPreLinkEventTool"/>
-                       <Tool
-                               Name="VCResourceCompilerTool"/>
-                       <Tool
-                               Name="VCWebServiceProxyGeneratorTool"/>
-                       <Tool
-                               Name="VCXMLDataGeneratorTool"/>
-                       <Tool
-                               Name="VCManagedWrapperGeneratorTool"/>
-                       <Tool
-                               Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
-               </Configuration>
-       </Configurations>
-       <References>
-       </References>
-       <Files>
-               <File
-                       RelativePath=".\src\convenience.cpp">
-               </File>
-               <File
-                       RelativePath=".\src\exception.cpp">
-               </File>
-               <File
-                       RelativePath=".\src\operations_posix_windows.cpp">
-               </File>
-               <File
-                       RelativePath=".\src\path_posix_windows.cpp">
-               </File>
-       </Files>
-       <Globals>
-       </Globals>
-</VisualStudioProject>
diff --git a/boost/libs/filesystem/src/exception.cpp b/boost/libs/filesystem/src/exception.cpp
deleted file mode 100644 (file)
index 83f066e..0000000
+++ /dev/null
@@ -1,166 +0,0 @@
-//  Exception implementation file  -------------------------------------------//
-
-//  Copyright 2002 Beman Dawes
-//  Copyright 2001 Dietmar Kuehl 
-//  Use, modification, and distribution is subject to the Boost Software
-//  License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy
-//  at http://www.boost.org/LICENSE_1_0.txt)
-
-//  See library home page at http://www.boost.org/libs/filesystem
-
-//----------------------------------------------------------------------------//
-
-// define BOOST_FILESYSTEM_SOURCE so that <boost/filesystem/config.hpp> knows
-// the library is being built (possibly exporting rather than importing code)
-#define BOOST_FILESYSTEM_SOURCE 
-
-#include <boost/filesystem/config.hpp>
-#include <boost/filesystem/path.hpp>
-#include <boost/filesystem/cerrno.hpp>
-
-namespace fs = boost::filesystem;
-
-#include <cstring> // SGI MIPSpro compilers need this
-
-# ifdef BOOST_NO_STDC_NAMESPACE
-    namespace std { using ::strerror; }
-# endif
-
-
-# if defined( BOOST_WINDOWS_API )
-#   include "windows.h"
-# endif
-
-//----------------------------------------------------------------------------//
-
-namespace
-{
-#ifdef BOOST_WINDOWS_API
-  struct ec_xlate { fs::system_error_type sys_ec; fs::errno_type ec; };
-  const ec_xlate ec_table[] =
-  {
-    // see WinError.h comments for descriptions of errors
-    
-    // most common errors first to speed sequential search
-    { ERROR_FILE_NOT_FOUND, ENOENT },
-    { ERROR_PATH_NOT_FOUND, ENOENT },
-
-    // alphabetical for easy maintenance
-    { 0, 0 }, // no error 
-    { ERROR_ACCESS_DENIED, EACCES },
-    { ERROR_ALREADY_EXISTS, EEXIST },
-    { ERROR_BAD_UNIT, ENODEV },
-    { ERROR_BUFFER_OVERFLOW, ENAMETOOLONG },
-    { ERROR_BUSY, EBUSY },
-    { ERROR_BUSY_DRIVE, EBUSY },
-    { ERROR_CANNOT_MAKE, EACCES },
-    { ERROR_CANTOPEN, EIO },
-    { ERROR_CANTREAD, EIO },
-    { ERROR_CANTWRITE, EIO },
-    { ERROR_CURRENT_DIRECTORY, EACCES },
-    { ERROR_DEV_NOT_EXIST, ENODEV },
-    { ERROR_DEVICE_IN_USE, EBUSY },
-    { ERROR_DIR_NOT_EMPTY, ENOTEMPTY },
-    { ERROR_DIRECTORY, EINVAL }, // WinError.h: "The directory name is invalid"
-    { ERROR_DISK_FULL, ENOSPC },
-    { ERROR_FILE_EXISTS, EEXIST },
-    { ERROR_HANDLE_DISK_FULL, ENOSPC },
-    { ERROR_INVALID_ACCESS, EACCES },
-    { ERROR_INVALID_DRIVE, ENODEV },
-    { ERROR_INVALID_FUNCTION, ENOSYS },
-    { ERROR_INVALID_HANDLE, EBADHANDLE },
-    { ERROR_INVALID_NAME, EINVAL },
-    { ERROR_LOCK_VIOLATION, EACCES },
-    { ERROR_LOCKED, EACCES },
-    { ERROR_NOACCESS, EACCES },
-    { ERROR_NOT_ENOUGH_MEMORY, ENOMEM },
-    { ERROR_NOT_READY, EAGAIN },
-    { ERROR_NOT_SAME_DEVICE, EXDEV },
-    { ERROR_OPEN_FAILED, EIO },
-    { ERROR_OPEN_FILES, EBUSY },
-    { ERROR_OUTOFMEMORY, ENOMEM },
-    { ERROR_READ_FAULT, EIO },
-    { ERROR_SEEK, EIO },
-    { ERROR_SHARING_VIOLATION, EACCES },
-    { ERROR_TOO_MANY_OPEN_FILES, ENFILE },
-    { ERROR_WRITE_FAULT, EIO },
-    { ERROR_WRITE_PROTECT, EROFS },
-    { 0,EOTHER }
-  };
-#endif
-
-} // unnamed namespace
-
-namespace boost
-{
-  namespace filesystem
-  {
-# ifdef BOOST_WINDOWS_API
-
-    BOOST_FILESYSTEM_DECL
-    errno_type lookup_errno( system_error_type sys_err_code )
-    {
-      for ( const ec_xlate * cur = &ec_table[0];
-        cur != ec_table
-          + sizeof(ec_table)/sizeof(ec_xlate); ++cur )
-      {
-        if ( sys_err_code == cur->sys_ec ) return cur->ec;
-      }
-      return EOTHER;
-    }
-
-    BOOST_FILESYSTEM_DECL void
-    system_message( system_error_type sys_err_code, std::string & target )
-    {
-      LPVOID lpMsgBuf;
-      ::FormatMessageA( 
-          FORMAT_MESSAGE_ALLOCATE_BUFFER | 
-          FORMAT_MESSAGE_FROM_SYSTEM | 
-          FORMAT_MESSAGE_IGNORE_INSERTS,
-          NULL,
-          sys_err_code,
-          MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language
-          (LPSTR) &lpMsgBuf,
-          0,
-          NULL 
-      );
-      target += static_cast<LPCSTR>(lpMsgBuf);
-      ::LocalFree( lpMsgBuf ); // free the buffer
-      while ( target.size()
-        && (target[target.size()-1] == '\n' || target[target.size()-1] == '\r') )
-          target.erase( target.size()-1 );
-    }
-
-#  ifndef BOOST_FILESYSTEM_NARROW_ONLY
-    BOOST_FILESYSTEM_DECL void
-    system_message( system_error_type sys_err_code, std::wstring & target )
-    {
-      LPVOID lpMsgBuf;
-      ::FormatMessageW( 
-          FORMAT_MESSAGE_ALLOCATE_BUFFER | 
-          FORMAT_MESSAGE_FROM_SYSTEM | 
-          FORMAT_MESSAGE_IGNORE_INSERTS,
-          NULL,
-          sys_err_code,
-          MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language
-          (LPWSTR) &lpMsgBuf,
-          0,
-          NULL 
-      );
-      target += static_cast<LPCWSTR>(lpMsgBuf);
-      ::LocalFree( lpMsgBuf ); // free the buffer
-      while ( target.size()
-        && (target[target.size()-1] == L'\n' || target[target.size()-1] == L'\r') )
-          target.erase( target.size()-1 );
-    }
-#  endif
-# else
-    void
-    system_message( system_error_type sys_err_code, std::string & target )
-    {
-      target += std::strerror( sys_err_code );
-    }
-# endif
-
-  } // namespace filesystem
-} // namespace boost
diff --git a/boost/libs/filesystem/src/operations.cpp b/boost/libs/filesystem/src/operations.cpp
deleted file mode 100644 (file)
index 95f6069..0000000
+++ /dev/null
@@ -1,1298 +0,0 @@
-//  operations.cpp  ----------------------------------------------------------//
-
-//  Copyright 2002-2005 Beman Dawes
-//  Copyright 2001 Dietmar Kuehl
-
-// Distributed under the Boost Software License, Version 1.0.
-// (See accompanying file LICENSE_1_0.txt or copy at
-// http://www.boost.org/LICENSE_1_0.txt)
-
-//  See library home page at http://www.boost.org/libs/filesystem/
-
-//----------------------------------------------------------------------------// 
-
-// define BOOST_FILESYSTEM_SOURCE so that <boost/filesystem/config.hpp> knows
-// the library is being built (possibly exporting rather than importing code)
-#define BOOST_FILESYSTEM_SOURCE 
-
-#define _POSIX_PTHREAD_SEMANTICS  // Sun readdir_r() needs this
-
-// enable the XPG-compliant version of readdir_r() on AIX
-#if defined(_AIX)
-# define _LINUX_SOURCE_COMPAT
-#endif
-
-#if !(defined(__HP_aCC) && defined(_ILP32) && \
-      !defined(_STATVFS_ACPP_PROBLEMS_FIXED))
-# define _FILE_OFFSET_BITS 64 // at worst, these defines may have no effect,
-#endif
-
-#define __USE_FILE_OFFSET64 // but that is harmless on Windows and on POSIX
-      // 64-bit systems or on 32-bit systems which don't have files larger 
-      // than can be represented by a traditional POSIX/UNIX off_t type. 
-      // OTOH, defining them should kick in 64-bit off_t's (and thus 
-      // st_size) on 32-bit systems that provide the Large File
-      // Support (LFS) interface, such as Linux, Solaris, and IRIX.
-      // The defines are given before any headers are included to
-      // ensure that they are available to all included headers.
-      // That is required at least on Solaris, and possibly on other
-      // systems as well.
-
-// for some compilers (CodeWarrior, for example), windows.h
-// is getting included by some other boost header, so do this early:
-#if !defined(_WIN32_WINNT)
-#define _WIN32_WINNT 0x0500 // Default to Windows 2K or later
-#endif
-
-
-#include <boost/filesystem/operations.hpp>
-#include <boost/scoped_array.hpp>
-#include <boost/throw_exception.hpp>
-#include <boost/detail/workaround.hpp>
-
-namespace fs = boost::filesystem;
-
-# if defined(BOOST_WINDOWS_API)
-#   include "windows.h"
-#   if defined(__BORLANDC__) || defined(__MWERKS__)
-#     if defined(__BORLANDC__)
-        using std::time_t;
-#     endif
-#     include "utime.h"
-#   else
-#     include "sys/utime.h"
-#   endif
-
-# else // BOOST_POSIX_API
-#   include <sys/types.h>
-#   ifndef __APPLE__
-#     include <sys/statvfs.h>
-#     define BOOST_STATVFS statvfs
-#     define BOOST_STATVFS_F_FRSIZE vfs.f_frsize
-#   else
-#     include <sys/mount.h>
-#     define BOOST_STATVFS statfs
-#     define BOOST_STATVFS_F_FRSIZE static_cast<boost::uintmax_t>( vfs.f_bsize )
-#   endif
-#   include "dirent.h"
-#   include "unistd.h"
-#   include "fcntl.h"
-#   include "utime.h"
-#   include "limits.h"
-# endif
-
-//  BOOST_FILESYSTEM_STATUS_CACHE enables file_status cache in
-//  dir_itr_increment. The config tests are placed here because some of the
-//  macros being tested come from dirent.h.
-//
-// TODO: find out what macros indicate dirent::d_type present in more libraries
-# if defined(BOOST_WINDOWS_API) \
-  || defined(_DIRENT_HAVE_D_TYPE) // defined by GNU C library if d_type present
-#   define BOOST_FILESYSTEM_STATUS_CACHE
-# endif
-
-#include <sys/stat.h>  // even on Windows some functions use stat()
-#include <string>
-#include <cstring>
-#include <cstdio>      // for remove, rename
-#include <cerrno>
-#include <cassert>
-// #include <iostream>    // for debugging only; comment out when not in use
-
-#ifdef BOOST_NO_STDC_NAMESPACE
-namespace std { using ::strcmp; using ::remove; using ::rename; }
-#endif
-
-//  helpers  -----------------------------------------------------------------//
-
-namespace
-{
-  static const fs::directory_iterator end_itr;
-  bool is_empty_directory( const std::string & dir_path )
-  {
-    return fs::directory_iterator(fs::path(dir_path)) == end_itr;
-  }
-
-#ifdef BOOST_WINDOWS_API
-  
-// For Windows, the xxxA form of various function names is used to avoid
-// inadvertently getting wide forms of the functions. (The undecorated
-// forms are actually macros, so can misfire if the user has various
-// other macros defined. There was a bug report of this happening.)
-
-  inline DWORD get_file_attributes( const char * ph )
-    { return ::GetFileAttributesA( ph ); }
-
-# ifndef BOOST_FILESYSTEM_NARROW_ONLY
-
-  inline DWORD get_file_attributes( const wchar_t * ph )
-    { return ::GetFileAttributesW( ph ); }
-
-  static const fs::wdirectory_iterator wend_itr;
-  bool is_empty_directory( const std::wstring & dir_path )
-  {
-    return fs::wdirectory_iterator(fs::wpath(dir_path)) == wend_itr;
-  }
-
-  inline BOOL get_file_attributes_ex( const wchar_t * ph,
-    WIN32_FILE_ATTRIBUTE_DATA & fad )
-  { return ::GetFileAttributesExW( ph, ::GetFileExInfoStandard, &fad ); }
-      
-  HANDLE create_file( const wchar_t * ph, DWORD dwDesiredAccess,
-    DWORD dwShareMode, LPSECURITY_ATTRIBUTES lpSecurityAttributes,
-    DWORD dwCreationDisposition, DWORD dwFlagsAndAttributes,
-    HANDLE hTemplateFile )
-  {
-    return ::CreateFileW( ph, dwDesiredAccess, dwShareMode,
-      lpSecurityAttributes, dwCreationDisposition, dwFlagsAndAttributes,
-      hTemplateFile );
-  }
-
-  inline DWORD get_current_directory( DWORD sz, wchar_t * buf )
-    { return ::GetCurrentDirectoryW( sz, buf ); } 
-
-  inline bool get_free_disk_space( const std::wstring & ph,
-    PULARGE_INTEGER avail, PULARGE_INTEGER total, PULARGE_INTEGER free )
-    { return ::GetDiskFreeSpaceExW( ph.c_str(), avail, total, free ) != 0; }
-
-  inline std::size_t get_full_path_name(
-    const std::wstring & ph, std::size_t len, wchar_t * buf, wchar_t ** p )
-  {
-    return static_cast<std::size_t>(
-      ::GetFullPathNameW( ph.c_str(),
-        static_cast<DWORD>(len), buf, p ));
-  } 
-
-  inline bool remove_directory( const std::wstring & ph )
-    { return ::RemoveDirectoryW( ph.c_str() ) != 0; }
-
-  inline bool delete_file( const std::wstring & ph )
-    { return ::DeleteFileW( ph.c_str() ) != 0; }
-
-  inline bool create_directory( const std::wstring & dir )
-    {  return ::CreateDirectoryW( dir.c_str(), 0 ) != 0; }
-
-#if _WIN32_WINNT >= 0x500
-  inline bool create_hard_link( const std::wstring & to_ph,
-    const std::wstring & from_ph )
-    {  return ::CreateHardLinkW( from_ph.c_str(), to_ph.c_str(), 0 ) != 0; }
-#endif
-  
-# endif // ifndef BOOST_FILESYSTEM_NARROW_ONLY
-
-  template< class String >
-  fs::file_status status_template( const String & ph, fs::system_error_type & ec )
-  {
-    DWORD attr( get_file_attributes( ph.c_str() ) );
-    if ( attr == 0xFFFFFFFF )
-    {
-      ec = ::GetLastError();
-      if ((ec == ERROR_FILE_NOT_FOUND)
-        || (ec == ERROR_PATH_NOT_FOUND)
-        || (ec == ERROR_INVALID_NAME) // "tools/jam/src/:sys:stat.h", "//foo"
-        || (ec == ERROR_INVALID_PARAMETER) // ":sys:stat.h"
-        || (ec == ERROR_BAD_NETPATH))
-      {
-        ec = 0; // these are not considered errors
-        return fs::file_status( fs::file_not_found );
-      }
-      return fs::file_status( fs::status_unknown );
-    }
-    ec = 0;
-    return (attr & FILE_ATTRIBUTE_DIRECTORY)
-      ? fs::file_status( fs::directory_file )
-      : fs::file_status( fs::regular_file );
-  }
-
-  BOOL get_file_attributes_ex( const char * ph,
-    WIN32_FILE_ATTRIBUTE_DATA & fad )
-  { return ::GetFileAttributesExA( ph, ::GetFileExInfoStandard, &fad ); }
-
-  template< class String >
-  boost::filesystem::detail::query_pair
-  is_empty_template( const String & ph )
-  {
-    WIN32_FILE_ATTRIBUTE_DATA fad;
-    if ( get_file_attributes_ex( ph.c_str(), fad ) == 0 )
-      return std::make_pair( ::GetLastError(), false );    
-    return std::make_pair( 0,
-      ( fad.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY )
-        ? is_empty_directory( ph )
-        :( !fad.nFileSizeHigh && !fad.nFileSizeLow ) );
-  }
-
-  HANDLE create_file( const char * ph, DWORD dwDesiredAccess,
-    DWORD dwShareMode, LPSECURITY_ATTRIBUTES lpSecurityAttributes,
-    DWORD dwCreationDisposition, DWORD dwFlagsAndAttributes,
-    HANDLE hTemplateFile )
-  {
-    return ::CreateFileA( ph, dwDesiredAccess, dwShareMode,
-      lpSecurityAttributes, dwCreationDisposition, dwFlagsAndAttributes,
-      hTemplateFile );
-  }
-
-  // Thanks to Jeremy Maitin-Shepard for much help and for permission to
-  // base the equivalent() implementation on portions of his 
-  // file-equivalence-win32.cpp experimental code.
-  struct handle_wrapper
-  {
-    HANDLE handle;
-    handle_wrapper( HANDLE h )
-      : handle(h) {}
-    ~handle_wrapper()
-    {
-      if ( handle != INVALID_HANDLE_VALUE )
-        ::CloseHandle(handle);
-    }
-  };
-
-  template< class String >
-  boost::filesystem::detail::query_pair
-  equivalent_template( const String & ph1, const String & ph2 )
-  {
-    // Note well: Physical location on external media is part of the
-    // equivalence criteria. If there are no open handles, physical location
-    // can change due to defragmentation or other relocations. Thus handles
-    // must be held open until location information for both paths has
-    // been retrieved.
-    handle_wrapper p1(
-      create_file(
-          ph1.c_str(),
-          0,
-          FILE_SHARE_DELETE | FILE_SHARE_READ | FILE_SHARE_WRITE,
-          0,
-          OPEN_EXISTING,
-          FILE_FLAG_BACKUP_SEMANTICS,
-          0 ) );
-    int error1(0); // save error code in case we have to throw
-    if ( p1.handle == INVALID_HANDLE_VALUE )
-      error1 = ::GetLastError();
-    handle_wrapper p2(
-      create_file(
-          ph2.c_str(),
-          0,
-          FILE_SHARE_DELETE | FILE_SHARE_READ | FILE_SHARE_WRITE,
-          0,
-          OPEN_EXISTING,
-          FILE_FLAG_BACKUP_SEMANTICS,
-          0 ) );
-    if ( p1.handle == INVALID_HANDLE_VALUE
-      || p2.handle == INVALID_HANDLE_VALUE )
-    {
-      if ( p1.handle != INVALID_HANDLE_VALUE
-        || p2.handle != INVALID_HANDLE_VALUE )
-        { return std::make_pair( 0, false ); }
-      assert( p1.handle == INVALID_HANDLE_VALUE
-        && p2.handle == INVALID_HANDLE_VALUE );
-        { return std::make_pair( error1, false ); }
-    }
-    // at this point, both handles are known to be valid
-    BY_HANDLE_FILE_INFORMATION info1, info2;
-    if ( !::GetFileInformationByHandle( p1.handle, &info1 ) )
-      { return std::make_pair( ::GetLastError(), false ); }
-    if ( !::GetFileInformationByHandle( p2.handle, &info2 ) )
-      { return std::make_pair( ::GetLastError(), false ); }
-    // In theory, volume serial numbers are sufficient to distinguish between
-    // devices, but in practice VSN's are sometimes duplicated, so last write
-    // time and file size are also checked.
-      return std::make_pair( 0,
-        info1.dwVolumeSerialNumber == info2.dwVolumeSerialNumber
-        && info1.nFileIndexHigh == info2.nFileIndexHigh
-        && info1.nFileIndexLow == info2.nFileIndexLow
-        && info1.nFileSizeHigh == info2.nFileSizeHigh
-        && info1.nFileSizeLow == info2.nFileSizeLow
-        && info1.ftLastWriteTime.dwLowDateTime
-          == info2.ftLastWriteTime.dwLowDateTime
-        && info1.ftLastWriteTime.dwHighDateTime
-          == info2.ftLastWriteTime.dwHighDateTime );
-  }
-
-  template< class String >
-  boost::filesystem::detail::uintmax_pair
-  file_size_template( const String & ph )
-  {
-    WIN32_FILE_ATTRIBUTE_DATA fad;
-    // by now, intmax_t is 64-bits on all Windows compilers
-    if ( get_file_attributes_ex( ph.c_str(), fad ) == 0 )
-      return std::make_pair( ::GetLastError(), 0 );    
-    if ( (fad.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) !=0 )
-      return std::make_pair( ERROR_FILE_NOT_FOUND, 0 );
-    return std::make_pair( 0,
-      (static_cast<boost::uintmax_t>(fad.nFileSizeHigh)
-        << (sizeof(fad.nFileSizeLow)*8))
-      + fad.nFileSizeLow );
-  }
-
-  inline bool get_free_disk_space( const std::string & ph,
-    PULARGE_INTEGER avail, PULARGE_INTEGER total, PULARGE_INTEGER free )
-    { return ::GetDiskFreeSpaceExA( ph.c_str(), avail, total, free ) != 0; }
-
-  template< class String >
-  boost::filesystem::detail::space_pair
-  space_template( String & ph )
-  {
-    ULARGE_INTEGER avail, total, free;
-    boost::filesystem::detail::space_pair result;
-    if ( get_free_disk_space( ph, &avail, &total, &free ) )
-    {
-      result.first = 0;
-      result.second.capacity
-        = (static_cast<boost::uintmax_t>(total.HighPart) << 32)
-          + total.LowPart;
-      result.second.free
-        = (static_cast<boost::uintmax_t>(free.HighPart) << 32)
-          + free.LowPart;
-      result.second.available
-        = (static_cast<boost::uintmax_t>(avail.HighPart) << 32)
-          + avail.LowPart;
-    }
-    else
-    {
-      result.first = ::GetLastError();
-      result.second.capacity = result.second.free
-        = result.second.available = 0;
-    }
-    return result;
-  }
-
-  inline DWORD get_current_directory( DWORD sz, char * buf )
-    { return ::GetCurrentDirectoryA( sz, buf ); } 
-
-  template< class String >
-  boost::filesystem::system_error_type
-  get_current_path_template( String & ph )
-  {
-    DWORD sz;
-    if ( (sz = get_current_directory( 0,
-      static_cast<typename String::value_type*>(0) )) == 0 )
-      { sz = 1; }
-    typedef typename String::value_type value_type;
-    boost::scoped_array<value_type> buf( new value_type[sz] );
-    if ( get_current_directory( sz, buf.get() ) == 0 )
-      return ::GetLastError();
-    ph = buf.get();
-    return 0;
-  }
-
-  inline std::size_t get_full_path_name(
-    const std::string & ph, std::size_t len, char * buf, char ** p )
-  {
-    return static_cast<std::size_t>(
-      ::GetFullPathNameA( ph.c_str(),
-        static_cast<DWORD>(len), buf, p ));
-  } 
-
-  const std::size_t buf_size( 128 );
-
-  template<class String>
-  boost::filesystem::system_error_type
-  get_full_path_name_template( const String & ph, String & target )
-  {
-    typename String::value_type buf[buf_size];
-    typename String::value_type * pfn;
-    std::size_t len = get_full_path_name( ph,
-      buf_size , buf, &pfn );
-    if ( len == 0 ) return ::GetLastError();
-    if ( len > buf_size )
-    {
-      typedef typename String::value_type value_type;
-      boost::scoped_array<value_type> big_buf( new value_type[len] );
-      if ( (len=get_full_path_name( ph, len , big_buf.get(), &pfn ))
-        == 0 ) return ::GetLastError();
-      big_buf[len] = '\0';
-      target = big_buf.get();
-      return 0;
-    }
-    buf[len] = '\0';
-    target = buf;
-    return 0;
-  }
-
-  template<class String>
-  boost::filesystem::system_error_type
-  get_file_write_time( const String & ph, FILETIME & last_write_time )
-  {
-    handle_wrapper hw(
-      create_file( ph.c_str(), 0,
-        FILE_SHARE_DELETE | FILE_SHARE_READ | FILE_SHARE_WRITE, 0,
-        OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, 0 ) );
-    if ( hw.handle == INVALID_HANDLE_VALUE )
-      return ::GetLastError();
-    return ::GetFileTime( hw.handle, 0, 0, &last_write_time ) != 0
-      ? 0 : ::GetLastError();
-  }
-
-  template<class String>
-  boost::filesystem::system_error_type
-  set_file_write_time( const String & ph, const FILETIME & last_write_time )
-  {
-    handle_wrapper hw(
-      create_file( ph.c_str(), FILE_WRITE_ATTRIBUTES,
-        FILE_SHARE_DELETE | FILE_SHARE_READ | FILE_SHARE_WRITE, 0,
-        OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, 0 ) );
-    if ( hw.handle == INVALID_HANDLE_VALUE )
-      return ::GetLastError();
-    return ::SetFileTime( hw.handle, 0, 0, &last_write_time ) != 0
-      ? 0 : ::GetLastError();
-  }
-
-  // these constants come from inspecting some Microsoft sample code
-  std::time_t to_time_t( const FILETIME & ft )
-  {
-    __int64 t = (static_cast<__int64>( ft.dwHighDateTime ) << 32)
-      + ft.dwLowDateTime;
-# if !defined( BOOST_MSVC ) || BOOST_MSVC > 1300 // > VC++ 7.0
-    t -= 116444736000000000LL;
-# else
-    t -= 116444736000000000;
-# endif
-    t /= 10000000;
-    return static_cast<std::time_t>( t );
-  }
-
-  void to_FILETIME( std::time_t t, FILETIME & ft )
-  {
-    __int64 temp = t;
-    temp *= 10000000;
-# if !defined( BOOST_MSVC ) || BOOST_MSVC > 1300 // > VC++ 7.0
-    temp += 116444736000000000LL;
-# else
-    temp += 116444736000000000;
-# endif
-    ft.dwLowDateTime = static_cast<DWORD>( temp );
-    ft.dwHighDateTime = static_cast<DWORD>( temp >> 32 );
-  }
-
-  template<class String>
-  boost::filesystem::detail::time_pair
-  last_write_time_template( const String & ph )
-  {
-    FILETIME lwt;
-    boost::filesystem::system_error_type result
-      = get_file_write_time( ph, lwt );
-    return std::make_pair( result, to_time_t( lwt ) );
-  }
-
-  template<class String>
-  boost::filesystem::system_error_type
-  last_write_time_template( const String & ph, const std::time_t new_time )
-  {
-    FILETIME lwt;
-    to_FILETIME( new_time, lwt );
-    return set_file_write_time( ph, lwt );
-  }
-
-  bool remove_directory( const std::string & ph )
-    { return ::RemoveDirectoryA( ph.c_str() ) != 0; }
-  
-  bool delete_file( const std::string & ph )
-    { return ::DeleteFileA( ph.c_str() ) != 0; }
-  
-  template<class String>
-  boost::filesystem::system_error_type
-  remove_template( const String & ph )
-  {
-    fs::system_error_type ec;
-    fs::file_status sf( fs::detail::status_api( ph, ec ) );
-    if ( ec ) return ec;
-    if ( fs::is_directory( sf ) )
-    {
-      if ( !remove_directory( ph ) )
-        return ::GetLastError();
-    }
-    else
-    {
-      if ( !delete_file( ph ) ) return ::GetLastError();
-    }
-    return 0;
-  }
-
-  inline bool create_directory( const std::string & dir )
-    {  return ::CreateDirectoryA( dir.c_str(), 0 ) != 0; }
-         
-  template<class String>
-  boost::filesystem::detail::query_pair
-  create_directory_template( const String & dir_ph )
-  {
-    boost::filesystem::system_error_type error(0), dummy;
-    if ( create_directory( dir_ph ) ) return std::make_pair( error, true );
-    error = ::GetLastError();
-    // an error here may simply mean the postcondition is already met
-    if ( error == ERROR_ALREADY_EXISTS
-      && fs::is_directory( fs::detail::status_api( dir_ph, dummy ) ) )
-      return std::make_pair( 0, false );
-    return std::make_pair( error, false );
-  }
-
-#if _WIN32_WINNT >= 0x500
-  inline bool create_hard_link( const std::string & to_ph,
-    const std::string & from_ph )
-    {  return ::CreateHardLinkA( from_ph.c_str(), to_ph.c_str(), 0 ) != 0; }
-#endif
-  
-#if _WIN32_WINNT >= 0x500
-  template<class String>
-  boost::filesystem::system_error_type
-  create_hard_link_template( const String & to_ph,
-    const String & from_ph )
-  {
-    return fs::system_error_type( create_hard_link( to_ph.c_str(), from_ph.c_str() )
-      ? 0 : ::GetLastError() );
-  }
-#endif
-
-#endif
-} // unnamed namespace
-
-namespace boost
-{
-  namespace filesystem
-  {
-    namespace detail
-    {
-
-#if   defined(BOOST_WINDOWS_API)
-        BOOST_FILESYSTEM_DECL system_error_type not_found_error = ERROR_PATH_NOT_FOUND;
-#else
-        BOOST_FILESYSTEM_DECL system_error_type not_found_error = ENOENT;
-#endif
-
-//  free functions  ----------------------------------------------------------//
-
-      BOOST_FILESYSTEM_DECL bool possible_large_file_size_support()
-      {
-#   ifdef BOOST_POSIX_API
-        struct stat lcl_stat;
-        return sizeof( lcl_stat.st_size ) > 4;
-#   else
-        return true;
-#   endif
-      }
-
-#   ifdef BOOST_WINDOWS_API
-
-      BOOST_FILESYSTEM_DECL fs::file_status
-        status_api( const std::string & ph, fs::system_error_type & ec )
-        { return status_template( ph, ec ); }
-
-#     ifndef BOOST_FILESYSTEM_NARROW_ONLY
-
-      BOOST_FILESYSTEM_DECL fs::file_status
-      status_api( const std::wstring & ph, fs::system_error_type & ec )
-        { return status_template( ph, ec ); }
-
-      BOOST_FILESYSTEM_DECL bool symbolic_link_exists_api( const std::wstring & )
-        { return false; }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::query_pair is_empty_api( const std::wstring & ph )
-        { return is_empty_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::query_pair
-      equivalent_api( const std::wstring & ph1, const std::wstring & ph2 )
-        { return equivalent_template( ph1, ph2 ); }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::uintmax_pair file_size_api( const std::wstring & ph )
-        { return file_size_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::space_pair space_api( const std::wstring & ph )
-        { return space_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL
-      boost::filesystem::system_error_type 
-      get_current_path_api( std::wstring & ph )
-        { return get_current_path_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-        get_full_path_name_api( const std::wstring & ph, std::wstring & target )
-         { return get_full_path_name_template( ph, target ); }
-
-      BOOST_FILESYSTEM_DECL time_pair
-        last_write_time_api( const std::wstring & ph )
-          { return last_write_time_template( ph ); }
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-        last_write_time_api( const std::wstring & ph, std::time_t new_value )
-          { return last_write_time_template( ph, new_value ); }
-
-      BOOST_FILESYSTEM_DECL fs::detail::query_pair
-      create_directory_api( const std::wstring & ph )
-        { return create_directory_template( ph ); }
-
-#if _WIN32_WINNT >= 0x500
-      BOOST_FILESYSTEM_DECL fs::system_error_type
-      create_hard_link_api( const std::wstring & to_ph,
-        const std::wstring & from_ph )
-        { return create_hard_link_template( to_ph, from_ph ); }
-#endif
-      
-      BOOST_FILESYSTEM_DECL fs::system_error_type
-      create_symlink_api( const std::wstring & to_ph,
-        const std::wstring & from_ph )
-        { return ERROR_NOT_SUPPORTED; }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      remove_api( const std::wstring & ph ) { return remove_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      rename_api( const std::wstring & from, const std::wstring & to )
-      {
-        return ::MoveFileW( from.c_str(), to.c_str() )
-          ? 0 : ::GetLastError();
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      copy_file_api( const std::wstring & from, const std::wstring & to )
-      {
-        return ::CopyFileW( from.c_str(), to.c_str(), /*fail_if_exists=*/true )
-          ? 0 : ::GetLastError();
-      }
-
-      BOOST_FILESYSTEM_DECL bool create_file_api( const std::wstring & ph,
-        std::ios_base::openmode mode ) // true if succeeds
-      {
-        DWORD access(
-          ((mode & std::ios_base::in) == 0 ? 0 : GENERIC_READ)
-          | ((mode & std::ios_base::out) == 0 ? 0 : GENERIC_WRITE) );
-
-        DWORD disposition(0); // see 27.8.1.3 Table 92
-        if ( (mode&~std::ios_base::binary)
-          == (std::ios_base::out|std::ios_base::app) )
-          disposition = OPEN_ALWAYS;
-        else if ( (mode&~(std::ios_base::binary|std::ios_base::out))
-          == std::ios_base::in ) disposition = OPEN_EXISTING;
-        else if ( ((mode&~(std::ios_base::binary|std::ios_base::trunc))
-          == std::ios_base::out )
-          || ((mode&~std::ios_base::binary)
-          == (std::ios_base::in|std::ios_base::out|std::ios_base::trunc)) )
-          disposition = CREATE_ALWAYS;
-        else assert( 0 && "invalid mode argument" );
-
-        HANDLE handle ( ::CreateFileW( ph.c_str(), access,
-          FILE_SHARE_DELETE | FILE_SHARE_READ | FILE_SHARE_WRITE, 0,
-          disposition, (mode &std::ios_base::out) != 0
-          ? FILE_ATTRIBUTE_ARCHIVE : FILE_ATTRIBUTE_NORMAL, 0 ) );
-        if ( handle == INVALID_HANDLE_VALUE ) return false;
-        ::CloseHandle( handle );
-        return true;
-      }
-
-      BOOST_FILESYSTEM_DECL std::string narrow_path_api(
-        const std::wstring & ph ) // return is empty if fails
-      {
-        std::string narrow_short_form;
-        std::wstring short_form;
-        for ( DWORD buf_sz( static_cast<DWORD>( ph.size()+1 ));; )
-        {
-          boost::scoped_array<wchar_t> buf( new wchar_t[buf_sz] );
-          DWORD sz( ::GetShortPathNameW( ph.c_str(), buf.get(), buf_sz ) );
-          if ( sz == 0 ) return narrow_short_form;
-          if ( sz <= buf_sz )
-          {
-            short_form += buf.get();
-            break;
-          }
-          buf_sz = sz + 1;
-        }
-        // contributed by Takeshi Mouri:
-        int narrow_sz( ::WideCharToMultiByte( CP_ACP, 0,
-          short_form.c_str(), static_cast<int>(short_form.size()), 0, 0, 0, 0 ) );
-        boost::scoped_array<char> narrow_buf( new char[narrow_sz] );
-        ::WideCharToMultiByte( CP_ACP, 0,
-          short_form.c_str(), static_cast<int>(short_form.size()),
-          narrow_buf.get(), narrow_sz, 0, 0 );
-        narrow_short_form.assign(narrow_buf.get(), narrow_sz);
-
-        return narrow_short_form;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_first( void *& handle, const std::wstring & dir,
-        std::wstring & target, file_status & sf, file_status & symlink_sf )
-      {
-        // use a form of search Sebastian Martel reports will work with Win98
-        std::wstring dirpath( dir );
-        dirpath += (dirpath.empty()
-          || dirpath[dirpath.size()-1] != L'\\') ? L"\\*" : L"*";
-
-        WIN32_FIND_DATAW data;
-        if ( (handle = ::FindFirstFileW( dirpath.c_str(), &data ))
-          == INVALID_HANDLE_VALUE )
-        { 
-          handle = 0;
-          return ::GetLastError() == ERROR_FILE_NOT_FOUND
-            ? 0 : ::GetLastError();
-        }
-        target = data.cFileName;
-        if ( data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY )
-          { sf.type( directory_file ); symlink_sf.type( directory_file ); }
-        else { sf.type( regular_file ); symlink_sf.type( regular_file ); }
-        return 0;
-      }  
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_increment( void *& handle, std::wstring & target,
-        file_status & sf, file_status & symlink_sf )
-      {
-        WIN32_FIND_DATAW data;
-        if ( ::FindNextFileW( handle, &data ) == 0 ) // fails
-        {
-          int error = ::GetLastError();
-          dir_itr_close( handle );
-          return error == ERROR_NO_MORE_FILES ? 0 : error;
-        }
-        target = data.cFileName;
-        if ( data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY )
-          { sf.type( directory_file ); symlink_sf.type( directory_file ); }
-        else { sf.type( regular_file ); symlink_sf.type( regular_file ); }
-        return 0;
-      }
-
-#     endif // ifndef BOOST_FILESYSTEM_NARROW_ONLY
-
-      // suggested by Walter Landry
-      BOOST_FILESYSTEM_DECL bool symbolic_link_exists_api( const std::string & )
-        { return false; }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::query_pair is_empty_api( const std::string & ph )
-        { return is_empty_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::query_pair
-      equivalent_api( const std::string & ph1, const std::string & ph2 )
-        { return equivalent_template( ph1, ph2 ); }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::uintmax_pair file_size_api( const std::string & ph )
-        { return file_size_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL
-      fs::detail::space_pair space_api( const std::string & ph )
-        { return space_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL
-      boost::filesystem::system_error_type 
-      get_current_path_api( std::string & ph )
-        { return get_current_path_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-        get_full_path_name_api( const std::string & ph, std::string & target )
-         { return get_full_path_name_template( ph, target ); }
-
-      BOOST_FILESYSTEM_DECL time_pair
-        last_write_time_api( const std::string & ph )
-          { return last_write_time_template( ph ); }
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-        last_write_time_api( const std::string & ph, std::time_t new_value )
-          { return last_write_time_template( ph, new_value ); }
-
-      BOOST_FILESYSTEM_DECL fs::detail::query_pair
-      create_directory_api( const std::string & ph )
-        { return create_directory_template( ph ); }
-
-#if _WIN32_WINNT >= 0x500
-      BOOST_FILESYSTEM_DECL fs::system_error_type
-      create_hard_link_api( const std::string & to_ph,
-        const std::string & from_ph )
-        { return system_error_type( create_hard_link_template( to_ph, from_ph ) ); }
-#endif
-
-      BOOST_FILESYSTEM_DECL fs::system_error_type
-      create_symlink_api( const std::string & to_ph,
-        const std::string & from_ph )
-        { return ERROR_NOT_SUPPORTED; }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      remove_api( const std::string & ph ) { return remove_template( ph ); }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      rename_api( const std::string & from, const std::string & to )
-      {
-        return ::MoveFileA( from.c_str(), to.c_str() )
-          ? 0 : ::GetLastError();
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      copy_file_api( const std::string & from, const std::string & to )
-      {
-        return ::CopyFileA( from.c_str(), to.c_str(), /*fail_if_exists=*/true )
-          ? 0 : ::GetLastError();
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_first( void *& handle, const std::string & dir,
-        std::string & target, file_status & sf, file_status & symlink_sf )
-      // Note: an empty root directory has no "." or ".." entries, so this
-      // causes a ERROR_FILE_NOT_FOUND error which we do not considered an
-      // error. It is treated as eof instead.
-      {
-        // use a form of search Sebastian Martel reports will work with Win98
-        std::string dirpath( dir );
-        dirpath += (dirpath.empty()
-          || (dirpath[dirpath.size()-1] != '\\'
-            && dirpath[dirpath.size()-1] != ':')) ? "\\*" : "*";
-
-        WIN32_FIND_DATAA data;
-        if ( (handle = ::FindFirstFileA( dirpath.c_str(), &data ))
-          == INVALID_HANDLE_VALUE )
-        { 
-          handle = 0;
-          return ::GetLastError() == ERROR_FILE_NOT_FOUND
-            ? 0 : ::GetLastError();
-        }
-        target = data.cFileName;
-        if ( data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY )
-          { sf.type( directory_file ); symlink_sf.type( directory_file ); }
-        else { sf.type( regular_file ); symlink_sf.type( regular_file ); }
-        return 0;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_close( void *& handle )
-      {
-        if ( handle != 0 )
-        {
-          bool ok = ::FindClose( handle ) != 0;
-          handle = 0;
-          return ok ? 0 : ::GetLastError();
-        }
-        return 0;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_increment( void *& handle, std::string & target,
-        file_status & sf, file_status & symlink_sf )
-      {
-        WIN32_FIND_DATAA data;
-        if ( ::FindNextFileA( handle, &data ) == 0 ) // fails
-        {
-          int error = ::GetLastError();
-          dir_itr_close( handle );
-          return error == ERROR_NO_MORE_FILES ? 0 : error;
-        }
-        target = data.cFileName;
-        if ( data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY )
-          { sf.type( directory_file ); symlink_sf.type( directory_file ); }
-        else { sf.type( regular_file ); symlink_sf.type( regular_file ); }
-        return 0;
-      }
-
-#   else // BOOST_POSIX_API
-
-      BOOST_FILESYSTEM_DECL fs::file_status
-      status_api( const std::string & ph, system_error_type & ec )
-      {
-        struct stat path_stat;
-        if ( ::stat( ph.c_str(), &path_stat ) != 0 )
-        {
-          if ( errno == ENOENT || errno == ENOTDIR )
-          {
-            ec = 0;
-            return fs::file_status( fs::file_not_found );
-          }
-          ec = errno;
-          return fs::file_status( fs::status_unknown );
-        }
-        ec = 0;
-        if ( S_ISDIR( path_stat.st_mode ) )
-          return fs::file_status( fs::directory_file );
-        if ( S_ISREG( path_stat.st_mode ) )
-          return fs::file_status( fs::regular_file );
-        if ( S_ISBLK( path_stat.st_mode ) )
-          return fs::file_status( fs::block_file );
-        if ( S_ISCHR( path_stat.st_mode ) )
-          return fs::file_status( fs::character_file );
-        if ( S_ISFIFO( path_stat.st_mode ) )
-          return fs::file_status( fs::fifo_file );
-        if ( S_ISSOCK( path_stat.st_mode ) )
-          return fs::file_status( fs::socket_file );
-        return fs::file_status( fs::type_unknown );
-      }
-
-      BOOST_FILESYSTEM_DECL fs::file_status
-      symlink_status_api( const std::string & ph, system_error_type & ec )
-      {
-        struct stat path_stat;
-        if ( ::lstat( ph.c_str(), &path_stat ) != 0 )
-        {
-          if ( errno == ENOENT || errno == ENOTDIR )
-          {
-            ec = 0;
-            return fs::file_status( fs::file_not_found );
-          }
-          ec = errno;
-          return fs::file_status( fs::status_unknown );
-        }
-        ec = 0;
-        if ( S_ISREG( path_stat.st_mode ) )
-          return fs::file_status( fs::regular_file );
-        if ( S_ISDIR( path_stat.st_mode ) )
-          return fs::file_status( fs::directory_file );
-        if ( S_ISLNK( path_stat.st_mode ) )
-          return fs::file_status( fs::symlink_file );
-        if ( S_ISBLK( path_stat.st_mode ) )
-          return fs::file_status( fs::block_file );
-        if ( S_ISCHR( path_stat.st_mode ) )
-          return fs::file_status( fs::character_file );
-        if ( S_ISFIFO( path_stat.st_mode ) )
-          return fs::file_status( fs::fifo_file );
-        if ( S_ISSOCK( path_stat.st_mode ) )
-          return fs::file_status( fs::socket_file );
-        return fs::file_status( fs::type_unknown );
-      }
-
-      // suggested by Walter Landry
-      BOOST_FILESYSTEM_DECL bool
-      symbolic_link_exists_api( const std::string & ph )
-      {
-        struct stat path_stat;
-        return ::lstat( ph.c_str(), &path_stat ) == 0
-          && S_ISLNK( path_stat.st_mode );
-      }
-
-      BOOST_FILESYSTEM_DECL query_pair
-      is_empty_api( const std::string & ph )
-      {
-        struct stat path_stat;
-        if ( (::stat( ph.c_str(), &path_stat )) != 0 )
-          return std::make_pair( errno, false );        
-        return std::make_pair( 0, S_ISDIR( path_stat.st_mode )
-          ? is_empty_directory( ph )
-          : path_stat.st_size == 0 );
-      }
-
-      BOOST_FILESYSTEM_DECL query_pair
-      equivalent_api( const std::string & ph1, const std::string & ph2 )
-      {
-        struct stat s2;
-        int e2( ::stat( ph2.c_str(), &s2 ) );
-        struct stat s1;
-        int e1( ::stat( ph1.c_str(), &s1 ) );
-        if ( e1 != 0 || e2 != 0 )
-          return std::make_pair( e1 != 0 && e2 != 0 ? errno : 0, false );
-        // at this point, both stats are known to be valid
-        return std::make_pair( 0,
-            s1.st_dev == s2.st_dev
-            && s1.st_ino == s2.st_ino
-            // According to the POSIX stat specs, "The st_ino and st_dev fields
-            // taken together uniquely identify the file within the system."
-            // Just to be sure, size and mod time are also checked.
-            && s1.st_size == s2.st_size
-            && s1.st_mtime == s2.st_mtime );
-      }
-      BOOST_FILESYSTEM_DECL uintmax_pair
-      file_size_api( const std::string & ph )
-      {
-        struct stat path_stat;
-        if ( ::stat( ph.c_str(), &path_stat ) != 0 )
-          return std::make_pair( errno, 0 );
-        if ( !S_ISREG( path_stat.st_mode ) )
-          return std::make_pair( EPERM, 0 ); 
-        return std::make_pair( 0,
-          static_cast<boost::uintmax_t>(path_stat.st_size) );
-      }
-
-      BOOST_FILESYSTEM_DECL space_pair
-      space_api( const std::string & ph )
-      {
-        struct BOOST_STATVFS vfs;
-        space_pair result;
-        if ( ::BOOST_STATVFS( ph.c_str(), &vfs ) != 0 )
-        {
-          result.first = errno;
-          result.second.capacity = result.second.free
-            = result.second.available = 0;
-        }
-        else
-        {
-          result.first = 0;
-          result.second.capacity 
-            = static_cast<boost::uintmax_t>(vfs.f_blocks) * BOOST_STATVFS_F_FRSIZE;
-          result.second.free 
-            = static_cast<boost::uintmax_t>(vfs.f_bfree) * BOOST_STATVFS_F_FRSIZE;
-          result.second.available
-            = static_cast<boost::uintmax_t>(vfs.f_bavail) * BOOST_STATVFS_F_FRSIZE;
-        }
-        return result;
-      }
-
-      BOOST_FILESYSTEM_DECL time_pair 
-      last_write_time_api( const std::string & ph )
-      {
-        struct stat path_stat;
-        if ( ::stat( ph.c_str(), &path_stat ) != 0 )
-          return std::make_pair( errno, 0 );
-        return std::make_pair( 0, path_stat.st_mtime );
-      }
-
-      BOOST_FILESYSTEM_DECL fs::system_error_type
-      last_write_time_api( const std::string & ph, std::time_t new_value )
-      {
-        struct stat path_stat;
-        if ( ::stat( ph.c_str(), &path_stat ) != 0 ) return errno;
-        ::utimbuf buf;
-        buf.actime = path_stat.st_atime; // utime() updates access time too:-(
-        buf.modtime = new_value;
-        return ::utime( ph.c_str(), &buf ) != 0 ? errno : 0;
-      }
-
-      BOOST_FILESYSTEM_DECL fs::system_error_type 
-      get_current_path_api( std::string & ph )
-      {
-        for ( long path_max = 32;; path_max *=2 ) // loop 'til buffer large enough
-        {
-          boost::scoped_array<char>
-            buf( new char[static_cast<std::size_t>(path_max)] );
-          if ( ::getcwd( buf.get(), static_cast<std::size_t>(path_max) ) == 0 )
-          {
-            if ( errno != ERANGE
-          // bug in some versions of the Metrowerks C lib on the Mac: wrong errno set 
-#         if defined(__MSL__) && (defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__))
-              && errno != 0
-#         endif
-              ) return errno;
-          }
-          else
-          {
-            ph = buf.get();
-            break;
-          }
-        }
-        return 0;
-      }
-
-      BOOST_FILESYSTEM_DECL fs::detail::query_pair
-      create_directory_api( const std::string & ph )
-      {
-        if ( ::mkdir( ph.c_str(), S_IRWXU|S_IRWXG|S_IRWXO ) == 0 )
-          { return std::make_pair( 0, true ); }
-        system_error_type ec=errno, dummy;
-        if ( ec != EEXIST 
-          || !fs::is_directory( status_api( ph, dummy ) ) )
-          { return std::make_pair( ec, false ); }
-        return std::make_pair( 0, false );
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      create_hard_link_api( const std::string & to_ph,
-          const std::string & from_ph )
-      {
-        return ::link( to_ph.c_str(), from_ph.c_str() ) == 0
-          ? 0 : errno;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      create_symlink_api( const std::string & to_ph,
-          const std::string & from_ph )
-      {
-        return ::symlink( to_ph.c_str(), from_ph.c_str() ) == 0
-          ? 0 : errno;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      remove_api( const std::string & ph )
-      {
-#     if defined(__QNXNTO__) || (defined(__MSL__) && (defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)))
-        // Some Metrowerks C library versions fail on directories because of a
-        // known Metrowerks coding error in ::remove. Workaround is to call
-        // rmdir() or unlink() as indicated.
-        // Same bug also reported for QNX, with the same fix.
-        if ( (is_directory( ph )
-          ? ::rmdir( ph.c_str() )
-          : ::unlink( ph.c_str() )) != 0 )
-#     else
-        // note that the POSIX behavior for symbolic links is what we want;
-        // the link rather than what it points to is deleted
-        if ( std::remove( ph.c_str() ) != 0 )
-#     endif
-        {
-          int error = errno;
-          // POSIX says "If the directory is not an empty directory, rmdir()
-          // shall fail and set errno to EEXIST or ENOTEMPTY."
-          // Linux uses ENOTEMPTY, Solaris uses EEXIST.
-          if ( error == EEXIST ) error = ENOTEMPTY;
-          return error;
-        }
-        return 0;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      rename_api( const std::string & from, const std::string & to )
-      {
-        // POSIX is too permissive so must check
-        fs::system_error_type dummy;
-        if ( fs::exists( status_api( to, dummy ) ) ) 
-          return EEXIST;
-        return std::rename( from.c_str(), to.c_str() ) != 0 
-          ? errno : 0;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      copy_file_api( const std::string & from_file_ph,
-        const std::string & to_file_ph )
-      {
-        const std::size_t buf_sz = 32768;
-        boost::scoped_array<char> buf( new char [buf_sz] );
-        int infile=0, outfile=0;  // init quiets compiler warning
-        struct stat from_stat;
-
-        if ( ::stat( from_file_ph.c_str(), &from_stat ) != 0
-          || (infile = ::open( from_file_ph.c_str(),
-                              O_RDONLY )) < 0
-          || (outfile = ::open( to_file_ph.c_str(),
-                                O_WRONLY | O_CREAT | O_EXCL,
-                                from_stat.st_mode )) < 0 )
-        {
-          if ( infile >= 0 ) ::close( infile );
-          return errno;
-        }
-
-        ssize_t sz, sz_read=1, sz_write;
-        while ( sz_read > 0
-          && (sz_read = ::read( infile, buf.get(), buf_sz )) > 0 )
-        {
-          // Allow for partial writes - see Advanced Unix Programming (2nd Ed.),
-          // Marc Rochkind, Addison-Wesley, 2004, page 94
-          sz_write = 0;
-          do
-          {
-            if ( (sz = ::write( outfile, buf.get() + sz_write,
-              sz_read - sz_write )) < 0 )
-            { 
-              sz_read = sz; // cause read loop termination
-              break;        //  and error to be thrown after closes
-            }
-            sz_write += sz;
-          } while ( sz_write < sz_read );
-        }
-
-        if ( ::close( infile) < 0 ) sz_read = -1;
-        if ( ::close( outfile) < 0 ) sz_read = -1;
-
-        return sz_read < 0 ? errno : 0;
-      }
-  
-      // this code is based on Stevens and Rago, Advanced Programming in the
-      // UNIX envirnment, 2nd Ed., ISBN 0-201-43307-9, page 49
-      fs::system_error_type
-      path_max( std::size_t & result )
-      {
-#     ifdef PATH_MAX
-        static std::size_t max = PATH_MAX;
-#     else
-        static std::size_t max = 0;
-#     endif
-        if ( max == 0 )
-        {
-          errno = 0;
-          long tmp = ::pathconf( "/", _PC_NAME_MAX );
-          if ( tmp < 0 )
-          {
-            if ( errno == 0 ) // indeterminate
-              max = 4096; // guess
-            else return errno;
-          }
-          else max = static_cast<std::size_t>( tmp + 1 ); // relative root
-        }
-        result = max;
-        return 0;
-      }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_first( void *& handle, void *& buffer,
-        const std::string & dir, std::string & target,
-        file_status &, file_status & )
-      {
-        static const std::string dummy_first_name( "." );
-        if ( (handle = ::opendir( dir.c_str() )) == 0 ) return errno;
-        target = dummy_first_name;
-        std::size_t path_size;
-        fs::system_error_type ec = path_max( path_size );
-        if ( ec ) return ec;
-        dirent de;
-        buffer = std::malloc( (sizeof(dirent) - sizeof(de.d_name))
-          +  path_size + 1 ); // + 1 for "/0"
-        return buffer == 0 ? ENOMEM : 0;
-      }  
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_close( void *& handle, void*& buffer )
-      {
-        std::free( buffer );
-        buffer = 0;
-        if ( handle == 0 ) return 0;
-        DIR * h( static_cast<DIR*>(handle) );
-        handle = 0;
-        return ::closedir( h ) == 0 ? 0 : errno;
-      }
-
-      // warning: the only dirent member updated is d_name
-      inline int readdir_r_simulator( DIR * dirp, struct dirent * entry,
-        struct dirent ** result ) // *result set to 0 on end of directory
-        {
-          errno = 0;
-
-    #     if !defined(__CYGWIN__) \
-          && defined(_POSIX_THREAD_SAFE_FUNCTIONS) \
-          && defined(_SC_THREAD_SAFE_FUNCTIONS) \
-          && (_POSIX_THREAD_SAFE_FUNCTIONS+0 >= 0) \
-          && (!defined(__HP_aCC) || (defined(__HP_aCC) && defined(_REENTRANT)))
-          if ( ::sysconf( _SC_THREAD_SAFE_FUNCTIONS ) >= 0 )
-            { return ::readdir_r( dirp, entry, result ); }
-    #     endif
-
-          struct dirent * p;
-          *result = 0;
-          if ( (p = ::readdir( dirp )) == 0 )
-            return errno;
-          std::strcpy( entry->d_name, p->d_name );
-          *result = entry;
-          return 0;
-        }
-
-      BOOST_FILESYSTEM_DECL boost::filesystem::system_error_type
-      dir_itr_increment( void *& handle, void *& buffer,
-        std::string & target, file_status & sf, file_status & symlink_sf )
-      {
-        BOOST_ASSERT( buffer != 0 );
-        dirent * entry( static_cast<dirent *>(buffer) );
-        dirent * result;
-        int return_code;
-        if ( (return_code = readdir_r_simulator( static_cast<DIR*>(handle),
-          entry, &result )) != 0 ) return errno;
-        if ( result == 0 ) return dir_itr_close( handle, buffer );
-        target = entry->d_name;
-#     ifdef BOOST_FILESYSTEM_STATUS_CACHE
-            if ( entry->d_type == DT_UNKNOWN )  // filesystem does not supply d_type value
-        {
-          sf = symlink_sf = fs::file_status(fs::status_unknown);
-        }
-          else  // filesystem supplies d_type value
-            {
-          if ( entry->d_type == DT_DIR )
-            sf = symlink_sf = fs::file_status( fs::directory_file );
-          else if ( entry->d_type == DT_REG )
-            sf = symlink_sf = fs::file_status( fs::regular_file );
-          else if ( entry->d_type == DT_LNK )
-          {
-            sf = fs::file_status( fs::status_unknown );
-            symlink_sf = fs::file_status( fs::symlink_file );
-          }
-          else sf = symlink_sf = fs::file_status( fs::status_unknown );
-            }
-#     else
-        sf = symlink_sf = fs::file_status( fs::status_unknown );
-#     endif
-        return 0;
-      }
-
-#   endif
-    } // namespace detail
-  } // namespace filesystem
-} // namespace boost
diff --git a/boost/libs/filesystem/src/path.cpp b/boost/libs/filesystem/src/path.cpp
deleted file mode 100644 (file)
index ac85ee9..0000000
+++ /dev/null
@@ -1,121 +0,0 @@
-//  path.cpp  ----------------------------------------------------------------//
-
-//  Copyright 2005 Beman Dawes
-//  Use, modification, and distribution is subject to the Boost Software
-//  License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy
-//  at http://www.boost.org/LICENSE_1_0.txt)
-
-//  See library home page at http://www.boost.org/libs/filesystem
-
-//----------------------------------------------------------------------------// 
-
-// define BOOST_FILESYSTEM_SOURCE so that <boost/filesystem/config.hpp> knows
-// the library is being built (possibly exporting rather than importing code)
-#define BOOST_FILESYSTEM_SOURCE 
-
-#include <boost/filesystem/config.hpp>
-
-#ifndef BOOST_FILESYSTEM_NARROW_ONLY
-
-#include <boost/filesystem/path.hpp>
-#include <boost/scoped_array.hpp>
-
-#include <locale>
-#include <cerrno>
-
-namespace
-{
-  // std::locale construction can throw (if LC_MESSAGES is wrong, for example),
-  // so a static at function scope is used to ensure that exceptions can be
-  // caught. (A previous version was at namespace scope, so initialization
-  // occurred before main(), preventing exceptions from being caught.)
-
-  std::locale & loc()
-  {
-    // ISO C calls this "the locale-specific native environment":
-    static std::locale lc("");
-    return lc;
-  }
-
-  const std::codecvt<wchar_t, char, std::mbstate_t> *&
-  converter()
-  {
-   static const std::codecvt<wchar_t, char, std::mbstate_t> *
-     cvtr(
-       &std::use_facet<std::codecvt<wchar_t, char, std::mbstate_t> >
-        ( loc() ) );
-   return cvtr;
-  }
-
-  bool locked(false);
-} // unnamed namespace
-
-namespace boost
-{
-  namespace filesystem
-  {
-    bool wpath_traits::imbue( const std::locale & new_loc, const std::nothrow_t & )
-    {
-      if ( locked ) return false;
-      locked = true;
-      loc() = new_loc;
-      converter() = &std::use_facet
-        <std::codecvt<wchar_t, char, std::mbstate_t> >( loc() );
-      return true;
-    }
-
-    void wpath_traits::imbue( const std::locale & new_loc )
-    {
-      if ( locked ) boost::throw_exception( filesystem_wpath_error(
-        "boost::filesystem::wpath_traits::imbue() after lockdown", 0 ) );
-      imbue( new_loc, std::nothrow );
-    }
-    
-# ifdef BOOST_POSIX_API
-
-//  Because this is POSIX only code, we don't have to worry about ABI issues
-//  described in http://www.boost.org/more/separate_compilation.html
-
-    wpath_traits::external_string_type
-    wpath_traits::to_external( const wpath & ph, 
-      const internal_string_type & src )
-    {
-      locked = true;
-      std::size_t work_size( converter()->max_length() * (src.size()+1) );
-      boost::scoped_array<char> work( new char[ work_size ] );
-      std::mbstate_t state;
-      const internal_string_type::value_type * from_next;
-      external_string_type::value_type * to_next;
-      if ( converter()->out( 
-        state, src.c_str(), src.c_str()+src.size(), from_next, work.get(),
-        work.get()+work_size, to_next ) != std::codecvt_base::ok )
-        boost::throw_exception( boost::filesystem::filesystem_wpath_error(
-          "boost::filesystem::wpath::to_external conversion error",
-          ph, EINVAL ) );
-      *to_next = '\0';
-      return external_string_type( work.get() );
-    }
-
-    wpath_traits::internal_string_type
-    wpath_traits::to_internal( const external_string_type & src )
-    {
-      locked = true;
-      std::size_t work_size( src.size()+1 );
-      boost::scoped_array<wchar_t> work( new wchar_t[ work_size ] );
-      std::mbstate_t state;
-      const external_string_type::value_type * from_next;
-      internal_string_type::value_type * to_next;
-      if ( converter()->in( 
-        state, src.c_str(), src.c_str()+src.size(), from_next, work.get(),
-        work.get()+work_size, to_next ) != std::codecvt_base::ok )
-        boost::throw_exception( boost::filesystem::filesystem_wpath_error(
-          "boost::filesystem::wpath::to_internal conversion error", EINVAL ) );
-      *to_next = L'\0';
-      return internal_string_type( work.get() );
-    }
-# endif // BOOST_POSIX_API
-
-  } // namespace filesystem
-} // namespace boost
-
-#endif // ifndef BOOST_FILESYSTEM_NARROW_ONLY
diff --git a/boost/libs/filesystem/src/portability.cpp b/boost/libs/filesystem/src/portability.cpp
deleted file mode 100644 (file)
index 78dd810..0000000
+++ /dev/null
@@ -1,112 +0,0 @@
-//  portability.cpp  ---------------------------------------------------------//
-
-//  Copyright © 2002-2005 Beman Dawes
-//  Use, modification, and distribution is subject to the Boost Software
-//  License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy
-//  at http://www.boost.org/LICENSE_1_0.txt)
-
-//  See library home page at http://www.boost.org/libs/filesystem
-
-//----------------------------------------------------------------------------// 
-
-// define BOOST_FILESYSTEM_SOURCE so that <boost/filesystem/config.hpp> knows
-// the library is being built (possibly exporting rather than importing code)
-#define BOOST_FILESYSTEM_SOURCE 
-
-#include <boost/filesystem/config.hpp>
-#include <boost/filesystem/path.hpp>
-
-namespace fs = boost::filesystem;
-
-#include <cstring> // SGI MIPSpro compilers need this
-
-# ifdef BOOST_NO_STDC_NAMESPACE
-    namespace std { using ::strerror; }
-# endif
-
-//----------------------------------------------------------------------------//
-
-namespace
-{
-  const char invalid_chars[] =
-    "\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0A\x0B\x0C\x0D\x0E\x0F"
-    "\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\x1B\x1C\x1D\x1E\x1F"
-    "<>:\"/\\|";
-  // note that the terminating '\0' is part of the string - thus the size below
-  // is sizeof(invalid_chars) rather than sizeof(invalid_chars)-1.  I 
-  const std::string windows_invalid_chars( invalid_chars, sizeof(invalid_chars) );
-
-  const std::string valid_posix(
-    "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789._-" );
-
-} // unnamed namespace
-
-namespace boost
-{
-  namespace filesystem
-  {
-
-    //  name_check functions  ----------------------------------------------//
-
-#   ifdef BOOST_WINDOWS
-    BOOST_FILESYSTEM_DECL bool native( const std::string & name )
-    {
-      return windows_name( name );
-    }
-#   else
-    BOOST_FILESYSTEM_DECL bool native( const std::string & name )
-    {
-      return name.find('/') == std::string::npos;
-    }
-#   endif
-
-    BOOST_FILESYSTEM_DECL bool portable_posix_name( const std::string & name )
-    {
-      return name.size() != 0
-        && name.find_first_not_of( valid_posix ) == std::string::npos;     
-    }
-
-    BOOST_FILESYSTEM_DECL bool windows_name( const std::string & name )
-    {
-      return name.size() != 0
-        && name.find_first_of( windows_invalid_chars ) == std::string::npos
-        && *(name.end()-1) != ' '
-        && (*(name.end()-1) != '.'
-          || name.length() == 1 || name == "..");
-    }
-
-    BOOST_FILESYSTEM_DECL bool portable_name( const std::string & name )
-    {
-      return
-        name.size() == 0
-        || name == "."
-        || name == ".."
-        || (windows_name( name )
-        && portable_posix_name( name )
-        && name[0] != '.' && name[0] != '-');
-    }
-
-    BOOST_FILESYSTEM_DECL bool portable_directory_name( const std::string & name )
-    {
-      return
-        name == "."
-        || name == ".."
-        || (portable_name( name )
-          && name.find('.') == std::string::npos);
-    }
-
-    BOOST_FILESYSTEM_DECL bool portable_file_name( const std::string & name )
-    {
-      std::string::size_type pos;
-      return
-         name == "."
-        || name == ".."
-        || (portable_name( name )
-          && ( (pos = name.find( '.' )) == std::string::npos
-            || (name.find( '.', pos+1 )== std::string::npos
-              && (pos + 5) > name.length() )))
-        ;
-    }
-
-  } // namespace filesystem
-} // namespace boost
index 5501c290a97b293280bda355e0648dae336e90c8..9d46ac2b47fbf1855111c9082abf72816de04d47 100644 (file)
@@ -1,8 +1,3 @@
-#include "libs/filesystem/src/exception.cpp"
-#include "libs/filesystem/src/operations.cpp"
-#include "libs/filesystem/src/path.cpp"
-#include "libs/filesystem/src/portability.cpp"
-
 //#include "libs/regex/src/cpp_regex_traits.cpp"
 //#include "libs/regex/src/c_regex_traits.cpp"
 #include "libs/regex/src/cregex.cpp"
index 38644dd56573855e9bcbe13922ae1adc686a132b..98436acce59e68ce06403ee911c1b0a9dabdbd61 100644 (file)
@@ -1,10 +1,5 @@
 #include <boost/config.hpp>
 #include <boost/detail/workaround.hpp>
-#include <boost/filesystem/config.hpp>
-#include <boost/filesystem/convenience.hpp>
-#include <boost/filesystem/exception.hpp>
-#include <boost/filesystem/operations.hpp>
-#include <boost/filesystem/path.hpp>
 #include <boost/scoped_array.hpp>
 #include <boost/signals/connection.hpp>
 #include <boost/signals/detail/signal_base.hpp>
index d55d66b5c5b7fa29aefcd37410939db12606abe5..508947a6159cce8d19ef5904c84299260b41744b 100644 (file)
@@ -6,8 +6,6 @@
 
 project(boost)
 
-#add_subdirectory(filesystem) 
-#add_subdirectory(iostreams) 
 add_subdirectory(regex) 
 add_subdirectory(signals) 
 
diff --git a/development/cmake/boost/libs/filesystem/CMakeLists.txt b/development/cmake/boost/libs/filesystem/CMakeLists.txt
deleted file mode 100644 (file)
index 8a559f3..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-# This file is part of LyX, the document processor.
-# Licence details can be found in the file COPYING.
-#
-# Copyright (c) 2006, Peter Kümmel, <syntheticpp@gmx.net>
-#
-
-project(boost_filesystem)
-
-set(boost_filesystem_sources
-       exception.cpp
-       operations.cpp
-       path.cpp
-       portability.cpp)
-
-lyx_add_path(boost_filesystem_sources ${TOP_SRC_DIR}/boost/libs/filesystem/src)
-
-if(NOT MERGE_FILES)
-       add_library(boost_filesystem STATIC ${boost_filesystem_sources})
-else()
-       add_definitions(-D_WIN32_WINNT=0x500)
-       lyx_const_touched_files(_allinone  boost_filesystem_sources)
-       add_library(boost_filesystem STATIC ${_allinone_files})
-endif()
-
index f7c75750dcf48ee026ee60ec58dd7295f9a089ca..832842b79d3d34a3aef201c2ad250d27c2f5797b 100644 (file)
@@ -615,7 +615,7 @@ if conf.CheckLib('nsl'):
 
 # check available boost libs (since lyx1.4 does not use iostream)
 boost_libs = []
-for lib in ['signals', 'regex', 'filesystem']:
+for lib in ['signals', 'regex']:
     if os.path.isdir(os.path.join(top_src_dir, 'boost', 'libs', lib)):
         boost_libs.append(lib)
 
index ef9361aa4ae408cb23f5d42bf0099e99c76794be..8ac54674f40ce23faff6c006f9842b078dd9af71 100644 (file)
@@ -2779,25 +2779,6 @@ boost_libs_regex_src_extra_files = Split('''
 ''')
 
 
-boost_libs_filesystem_extra_files = Split('''
-    Makefile.am
-    filesystem.vcproj
-''')
-
-
-boost_libs_filesystem_src_files = Split('''
-    exception.cpp
-    operations.cpp
-    path.cpp
-    portability.cpp
-''')
-
-
-boost_libs_filesystem_src_extra_files = Split('''
-    Makefile.am
-    pch.h
-''')
-
 
 development_Win32_packaging_installer = Split('''
     license.rtf