• Ian Lance Taylor's avatar
    lib9, cmd/ld: fixes for cross-linking on a Windows host · 5a40b568
    Ian Lance Taylor authored
    This fixes a couple of problems that occur when the linker
    removes its temporary directory on Windows.  The linker only
    creates and removes a temporary directory when doing external
    linking.  Windows does not yet support external linking.
    Therefore, these problems are only seen when using a
    cross-compiler hosted on Windows.
    
    In lib9, FindFirstFileW returns just the file name, not the
    full path name.  Don't assume that we will find a slash.
    Changed the code to work either way just in case.
    
    In ld, Windows requires that files be closed before they are
    removed, so close the output file before we might try to
    remove it.
    
    Fixes #8723.
    
    LGTM=alex.brainman
    R=golang-codereviews, alex.brainman
    CC=golang-codereviews
    https://golang.org/cl/141690043
    5a40b568
Name
Last commit
Last update
..
fmt Loading commit data...
utf Loading commit data...
Makefile Loading commit data...
_exits.c Loading commit data...
_p9dir.c Loading commit data...
atoi.c Loading commit data...
await.c Loading commit data...
cleanname.c Loading commit data...
create.c Loading commit data...
ctime.c Loading commit data...
dirfstat.c Loading commit data...
dirfwstat.c Loading commit data...
dirstat.c Loading commit data...
dirwstat.c Loading commit data...
dup.c Loading commit data...
errstr.c Loading commit data...
exec.c Loading commit data...
execl.c Loading commit data...
exitcode.c Loading commit data...
exits.c Loading commit data...
flag.c Loading commit data...
fmtlock2.c Loading commit data...
getenv.c Loading commit data...
getfields.c Loading commit data...
getwd.c Loading commit data...
goos.c Loading commit data...
jmp.c Loading commit data...
main.c Loading commit data...
nan.c Loading commit data...
notify.c Loading commit data...
nulldir.c Loading commit data...
open.c Loading commit data...
readn.c Loading commit data...
rfork.c Loading commit data...
run_plan9.c Loading commit data...
run_unix.c Loading commit data...
run_windows.c Loading commit data...
seek.c Loading commit data...
strecpy.c Loading commit data...
sysfatal.c Loading commit data...
tempdir_plan9.c Loading commit data...
tempdir_unix.c Loading commit data...
tempdir_windows.c Loading commit data...
time.c Loading commit data...
tokenize.c Loading commit data...
win.h Loading commit data...
windows.c Loading commit data...