[Cmake-commits] [cmake-commits] hoffman committed SystemTools.cxx 1.222.2.5 1.222.2.6 SystemTools.hxx.in 1.72.2.2 1.72.2.3 testProcess.c 1.34.44.1 1.34.44.2

cmake-commits at cmake.org cmake-commits at cmake.org
Tue Jan 13 13:03:56 EST 2009


Update of /cvsroot/CMake/CMake/Source/kwsys
In directory public:/mounts/ram/cvs-serv9962/Source/kwsys

Modified Files:
      Tag: CMake-2-6
	SystemTools.cxx SystemTools.hxx.in testProcess.c 
Log Message:
ENH: merge in changes from CVS to branch for 2.6.3 RC 8


Index: testProcess.c
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/kwsys/testProcess.c,v
retrieving revision 1.34.44.1
retrieving revision 1.34.44.2
diff -C 2 -d -r1.34.44.1 -r1.34.44.2
*** testProcess.c	24 Oct 2008 15:18:55 -0000	1.34.44.1
--- testProcess.c	13 Jan 2009 18:03:54 -0000	1.34.44.2
***************
*** 458,462 ****
      int outputs[8] = {1, 1, 1, 1, 1, 0, 1, 1};
      int delays[8] = {0, 0, 0, 0, 0, 1, 0, 0};
!     double timeouts[8] = {10, 10, 10, 10, 30, 10, -1, 10};
      int polls[8] = {0, 0, 0, 0, 0, 0, 1, 0};
      int repeat[8] = {2, 1, 1, 1, 1, 1, 1, 1};
--- 458,462 ----
      int outputs[8] = {1, 1, 1, 1, 1, 0, 1, 1};
      int delays[8] = {0, 0, 0, 0, 0, 1, 0, 0};
!     double timeouts[8] = {10, 10, 10, 30, 30, 10, -1, 10};
      int polls[8] = {0, 0, 0, 0, 0, 0, 1, 0};
      int repeat[8] = {2, 1, 1, 1, 1, 1, 1, 1};

Index: SystemTools.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/kwsys/SystemTools.cxx,v
retrieving revision 1.222.2.5
retrieving revision 1.222.2.6
diff -C 2 -d -r1.222.2.5 -r1.222.2.6
*** SystemTools.cxx	24 Oct 2008 15:18:55 -0000	1.222.2.5
--- SystemTools.cxx	13 Jan 2009 18:03:54 -0000	1.222.2.6
***************
*** 1612,1616 ****
  
  bool SystemTools::CopyFileIfDifferent(const char* source,
!                                       const char* destination)
  {
    // special check for a destination that is a directory
--- 1612,1617 ----
  
  bool SystemTools::CopyFileIfDifferent(const char* source,
!                                       const char* destination,
!                                       bool copyPermissions)
  {
    // special check for a destination that is a directory
***************
*** 1625,1629 ****
      if(SystemTools::FilesDiffer(source, new_destination.c_str()))
        {
!       return SystemTools::CopyFileAlways(source, destination);
        }
      else
--- 1626,1631 ----
      if(SystemTools::FilesDiffer(source, new_destination.c_str()))
        {
!       return SystemTools::CopyFileAlways(source, destination,
!                                          copyPermissions);
        }
      else
***************
*** 1638,1642 ****
    if(SystemTools::FilesDiffer(source, destination))
      {
!     return SystemTools::CopyFileAlways(source, destination);
      }
    // at this point the files must be the same so return true
--- 1640,1644 ----
    if(SystemTools::FilesDiffer(source, destination))
      {
!     return SystemTools::CopyFileAlways(source, destination, copyPermissions);
      }
    // at this point the files must be the same so return true
***************
*** 1719,1726 ****
  
  
  /**
   * Copy a file named by "source" to the file named by "destination".
   */
! bool SystemTools::CopyFileAlways(const char* source, const char* destination)
  {
    // If files are the same do not copy
--- 1721,1730 ----
  
  
+ //----------------------------------------------------------------------------
  /**
   * Copy a file named by "source" to the file named by "destination".
   */
! bool SystemTools::CopyFileAlways(const char* source, const char* destination,
!                                  bool copyPermissions)
  {
    // If files are the same do not copy
***************
*** 1825,1829 ****
     return false;
      }
!   if ( perms )
      {
      if ( !SystemTools::SetPermissions(destination, perm) )
--- 1829,1833 ----
     return false;
      }
!   if ( copyPermissions && perms )
      {
      if ( !SystemTools::SetPermissions(destination, perm) )
***************
*** 1837,1849 ****
  //----------------------------------------------------------------------------
  bool SystemTools::CopyAFile(const char* source, const char* destination,
!                             bool always)
  {
    if(always)
      {
!     return SystemTools::CopyFileAlways(source, destination);
      }
    else
      {
!     return SystemTools::CopyFileIfDifferent(source, destination);
      }
  }
--- 1841,1853 ----
  //----------------------------------------------------------------------------
  bool SystemTools::CopyAFile(const char* source, const char* destination,
!                             bool always, bool copyPermissions)
  {
    if(always)
      {
!     return SystemTools::CopyFileAlways(source, destination, copyPermissions);
      }
    else
      {
!     return SystemTools::CopyFileIfDifferent(source, destination, copyPermissions);
      }
  }
***************
*** 1854,1858 ****
   */
  bool SystemTools::CopyADirectory(const char* source, const char* destination,
!                                  bool always)
  {
    Directory dir;
--- 1858,1862 ----
   */
  bool SystemTools::CopyADirectory(const char* source, const char* destination,
!                                  bool always, bool copyPermissions)
  {
    Directory dir;
***************
*** 1878,1882 ****
          if (!SystemTools::CopyADirectory(fullPath.c_str(),
                                           fullDestPath.c_str(),
!                                          always))
            {
            return false;
--- 1882,1887 ----
          if (!SystemTools::CopyADirectory(fullPath.c_str(),
                                           fullDestPath.c_str(),
!                                          always,
!                                          copyPermissions))
            {
            return false;
***************
*** 1885,1889 ****
        else
          {
!         if(!SystemTools::CopyAFile(fullPath.c_str(), destination, always))
            {
            return false;
--- 1890,1895 ----
        else
          {
!         if(!SystemTools::CopyAFile(fullPath.c_str(), destination, always,
!                                    copyPermissions))
            {
            return false;

Index: SystemTools.hxx.in
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/kwsys/SystemTools.hxx.in,v
retrieving revision 1.72.2.2
retrieving revision 1.72.2.3
diff -C 2 -d -r1.72.2.2 -r1.72.2.3
*** SystemTools.hxx.in	29 May 2008 13:15:33 -0000	1.72.2.2
--- SystemTools.hxx.in	13 Jan 2009 18:03:54 -0000	1.72.2.3
***************
*** 491,504 ****
    /**
     * Copy the source file to the destination file only
!    * if the two files differ.  
     */
    static bool CopyFileIfDifferent(const char* source,
!                                   const char* destination);
!   
    /**
     * Compare the contents of two files.  Return true if different
     */
    static bool FilesDiffer(const char* source, const char* destination);
!   
    /**
     * Return true if the two files are the same file
--- 491,508 ----
    /**
     * Copy the source file to the destination file only
!    * if the two files differ. If the "copyPermissions"
!    * argument is true, the permissions of the copy are
!    * set to be the same as the permissions of the
!    * original.
     */
    static bool CopyFileIfDifferent(const char* source,
!                                   const char* destination,
!                                   bool copyPermissions = true);
! 
    /**
     * Compare the contents of two files.  Return true if different
     */
    static bool FilesDiffer(const char* source, const char* destination);
! 
    /**
     * Return true if the two files are the same file
***************
*** 507,521 ****
  
    /**
!    * Copy a file
     */
!   static bool CopyFileAlways(const char* source, const char* destination);
  
    /**
     * Copy a file.  If the "always" argument is true the file is always
     * copied.  If it is false, the file is copied only if it is new or
!    * has changed.
     */
    static bool CopyAFile(const char* source, const char* destination,
!                         bool always = true);
  
    /**
--- 511,530 ----
  
    /**
!    * Copy a file. If the "copyPermissions" argument is true, the
!    * permissions of the copy are set to be the same as the permissions
!    * of the original.
     */
!   static bool CopyFileAlways(const char* source, const char* destination,
!                              bool copyPermissions = true);
  
    /**
     * Copy a file.  If the "always" argument is true the file is always
     * copied.  If it is false, the file is copied only if it is new or
!    * has changed. If the "copyPermissions" argument is true, the
!    * permissions of the copy are set to be the same as the permissions
!    * of the original.
     */
    static bool CopyAFile(const char* source, const char* destination,
!                         bool always = true, bool copyPermissions = true);
  
    /**
***************
*** 526,530 ****
     */
    static bool CopyADirectory(const char* source, const char* destination,
!                              bool always = true);
    
    /**
--- 535,539 ----
     */
    static bool CopyADirectory(const char* source, const char* destination,
!                              bool always = true, bool copyPermissions = true);
    
    /**



More information about the Cmake-commits mailing list