mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
Fix 'clean' command on Windows MinGW
'c3c clean' command try to use 'rm' on Windows MinGW compiled executable, since it does not define "_MSC_VER", but define "_WIN32" There are other uses of "_MSC_VER" in the same file, they probably can be changed to "_WIN32" too
This commit is contained in:
committed by
Christoffer Lerno
parent
b6e166f44d
commit
fe7d4230d8
@@ -550,7 +550,7 @@ bool file_delete_file(const char *path)
|
||||
void file_delete_all_files_in_dir_with_suffix(const char *path, const char *suffix)
|
||||
{
|
||||
ASSERT0(path);
|
||||
#if (_MSC_VER)
|
||||
#if (_WIN32)
|
||||
const char *cmd = "del /q \"%s\\*%s\" >nul 2>&1";
|
||||
#else
|
||||
const char *cmd = "rm -f %s/*%s";
|
||||
@@ -785,4 +785,4 @@ char *realpath(const char *path, char *const resolved_path)
|
||||
return result;
|
||||
}
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user