| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Fix a crash which occurs when SystemTools::GetPath attempts to process
an empty environment variable.
Author: Vladimir Panteleev <vladimir@thecybershadow.net>
|
|
|
|
|
| |
Author: Hans Johnson <hans-johnson@uiowa.edu>
Change-Id: I31a29a8b53e5262b76530b8ea80a1a66cff7b3f7
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CommandLineArguments.cxx:
remark #181: argument is incompatible with corresponding format
string conversion
SystemInformation.cxx:
remark #193: zero used for undefined preprocessing identifier "_WIN32"
warning #177: variable "Regebx" was declared but never referenced
SystemTools.cxx(375):
remark #444: destructor for base class "std::vector<char*>" is not virtual
class kwsysDeletingCharVector : private kwsys_stl::vector<char*>
Author: Hans Johnson <hans-johnson@uiowa.edu>
Change-Id: Ibc899c3ba14990158ef7bbabace4b435b22495c3
|
|
|
|
|
|
|
| |
In SystemTools::ClassInitialize, remove call to AddTranslationPath
that was originally put in place to "work around an SGI problem."
This code precluded using CMake effectively in valid directories
under "/tmp_mnt/"
|
|
|
|
|
| |
Convert struct timeval members to double explicitly to avoid a GCC
warning with -Wconversion.
|
|
|
|
|
|
| |
We already use GetSystemTimeAsFileTime() and gettimeofday()
unconditionally on supported Windows and non-Windows platforms,
respectively. Remove outdated portability complexity.
|
|
|
|
|
|
| |
The previous commit did not compile with mingw gcc.
Use the Windows type FARPROC instead of void* for
the local variable.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CMake fails to find any registry paths on Windows 2000: according to regmon
it fails with an access denied error. I double checked all the access rights
and they are fine. After checking the access modes on MSDN I found that it
says KEY_WOW64_32KEY / KEY_WOW64_64KEY are not supported on Windows 2000.
CMake does not check if the current system supports Wow64 before applying
these flags.
This commit adds a check for IsWow64Process in kernel32.dll before adding
these flags.
Author: Axel Gembe <ago@bastart.eu.org>
Signed-off-by: Axel Gembe <ago@bastart.eu.org>
|
|
|
|
|
|
| |
Pass the lpClass argument of RegCreateKeyEx as a real char[] instead of
a string literal. At least one platform declares the argument as char*
instead of "const char*".
|
|
|
|
|
|
|
|
|
|
|
|
| |
This method replaces '//' with '/' to make the paths look nicer.
Originally it correctly skipped a leading '//' in a UNC path as the
comment says. However, commit "Removed extra variable initializations"
(2005-04-15) accidentally removed the "pos=1" initializer. It was then
incorrectly restored by commit "Added missing variable initialization"
(2005-04-15) as just "pos=0". Restore the proper initializer.
The test for this added by commit "better coverage" (2006-07-31)
included incorrect output for a sample UNC-like path. Fix it.
|
|
|
|
|
|
|
|
|
|
| |
Commit "merge in changes for beos support" (2006-12-04) added a realpath
call for every directory parsed out of a PATH-style environment
variable. No reason was given in the commit message or comments.
The call incorrectly resolves symlinks in referenced paths. Remove it.
If BeOS support really needs it then it can be restored for that
platform with a full explanation.
|
|
|
|
|
| |
Avoid using the old SplitString method in favor of the more robust
SplitPath method.
|
| |
|
|
|
|
|
|
| |
See issue #11023.
Author: Clinton Stimpson <clinton@elemtech.com>
|
|
|
|
|
| |
Windows paths may begin with a single backslash when the drive letter is
omitted. Recognize this as a root path component.
|
|
|
|
|
|
|
|
| |
The CopyFileIfDifferent, CopyFileAlways, CopyAFile and CopyADirectory
methods should always copy permissions. The special cases in which a
caller would pass copyPermissions=false should be handled at the call
site. The parameter needlessly complicates the interface and semantics
of these methods.
|
|
|
|
|
|
|
| |
On Windows 7 the file size reported by 'stat' on a new file sometimes
reports zero even though the real size is correct. This causes our
CopyFileAlways method to falsely detect copy failure. Work around the
problem by trusting the state of ofstream after writing the file.
|
| |
|
|
|
|
| |
of a file name on 'Windows' without converting to short name and back again. Avoids bad behavior reported in http://bugs.winehq.org/show_bug.cgi?id=22286 when using cmake under a wine/msys/mingw installation on a Linux box. Thanks to Clinton Stimpson for preparing the patch.
|
|
|
|
| |
falling back to using time() which only provides second resolution. Fixed to allow usec res.
|
|
|
|
| |
That GetLineFromStream method while loop sure is fussy.
|
|
|
|
| |
from it. Return false and an empty line instead...
|
|
|
|
|
|
|
| |
This converts the KWSys license to a pure 3-clause OSI-approved BSD
License. We drop the previous license clause requiring modified
versions to be plainly marked. We also update the KWSys copyright to
cover the full development time range.
|
|
|
|
|
|
|
|
|
|
|
| |
The commit "Fix KWSys SystemTools build on cygwin with -mwin32" tried to
restore the state of the _WIN32 definition that was broken by the commit
"Optimize KWSys SystemTools::FileExists on Windows". It did so for the
case of building with -mwin32 on cygwin, but since including <windows.h>
defines _WIN32, it failed for the case of not using -mwin32.
This commit restores the state of _WIN32 in all cases by undefining it
after including <windows.h> if it was not defined beforehand.
|
|
|
|
|
|
|
| |
Commit "Optimize KWSys SystemTools::FileExists on Windows" accidentally
added "#undef _WIN32" when including <windows.h> on cygwin, which breaks
builds using the -mwin32 flag. This commit removes that line and fixes
the real error it was intended to avoid.
|
|
|
|
| |
memory on exit, as it can cause gcov to crash the programs.
|
|
|
|
|
|
|
|
|
|
| |
We optimize this method by using the GetFileAttributesExA native Windows
API to check for file existence when possible. For real Windows builds
we always use it. For Cygwin we use cygwin_conv_to_win32_path to get a
native Windows path if possible and otherwise fall back to 'access'.
Cygwin-to-Windows path conversion and cache by Wojciech Migda.
See issue #8826.
|
| |
|
|
|
|
| |
complaing that JoinPath is leaking.
|
|
|
|
|
| |
This removes an assignment whose result is never used, thus quieting a
warning from Borland.
|
| |
|
|
|
|
|
|
| |
This teaches ConvertToUnixSlashes to convert VMS paths into posix-style
paths. We also set the DECC$FILENAME_UNIX_ONLY feature so the process
always sees posix-style paths on disk.
|
| |
|
| |
|
|
|
|
|
| |
Read-only directories must be given write permission before we can
remove files and subdirectories from them.
|
|
|
|
| |
bootstrap script will not work on VMS
|
|
|
|
|
| |
This removes SystemTools::FileExistsInParentDirectories from KWSys since
it is a special-purpose method that is not generally useful.
|
|
|
|
|
|
|
|
| |
When SystemTools::GetParentDirectory was fixed to never remove the root
path component from a full path we violated an assumption made by
IsSubDirectory that eventually GetParentDirectory returns an empty
string. This led to an infinite loop if the potential parent directory
is empty, so we explicitly avoid that case.
|
|
|
|
|
|
|
| |
The previous change to this method broke cases where the input path does
not exist. The SystemTools::GetParentDirectory method is redundant with
the more robust SystemTools::GetFilenamePath. This replaces its
implementation to just call GetFilenamePath.
|
|
|
|
| |
argement. Valid check is added to make sure the input argment exists, and if "/" is passed in, empty string will be returned.
|
| |
|
|
|
|
|
|
|
| |
On Windows the GetLongPathName API function does not work on some
filesystems even if the file exists. In this case we should just use
the original long path name and not the GetShortPathName result.
See issue #8480.
|
|
|
|
|
|
| |
This patch from Philip Lowman teaches SystemTools::GetRealPath to deal
with paths that do not exist by dealing with the case that realpath
returns NULL. See issue #8423.
|
|
|
|
| |
rule. If the source file was read-only, this prevents the subsequent set of the destination file's modification time, making the copied file always different in time-stamp than the original and always installing a new file with a new time stamp (but the same content) causing unnecessary downstream incremental rebuilds. As part of this fix, add an optional copyPermissions parameter to the SystemTools routines CopyFileIfDifferent, CopyFileAlways, CopyAFile and CopyADirectory. The copyPermissions parameter defaults to true to preserve the behavior of these routines for existing callers.
|
| |
|
| |
|
| |
|
|
|
|
| |
See issue #7797.
|
| |
|