mirror of
https://git.rtems.org/rtems-source-builder
synced 2024-10-09 07:15:10 +08:00
Windows native build fixes.
The testing of building on Windows is done using MSYS2.
This commit is contained in:
@@ -127,7 +127,14 @@ def mkdir(path):
|
||||
def removeall(path):
|
||||
|
||||
def _onerror(function, path, excinfo):
|
||||
print 'removeall error: (%s) %s' % (excinfo, path)
|
||||
import stat
|
||||
if not os.access(path, os.W_OK):
|
||||
# Is the error an access error ?
|
||||
os.chmod(path, stat.S_IWUSR)
|
||||
function(path)
|
||||
else:
|
||||
print 'removeall error: %s' % (path)
|
||||
raise
|
||||
|
||||
path = host(path)
|
||||
shutil.rmtree(path, onerror = _onerror)
|
||||
|
Reference in New Issue
Block a user