From: Ian Lance Taylor Date: Tue, 21 Jan 2014 17:29:19 +0000 (-0800) Subject: cmd/ld: support archives larger than 2G X-Git-Tag: go1.3beta1~919 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=cdc556556c1d0213b3205dcd5b08655795fc215d;p=gostls13.git cmd/ld: support archives larger than 2G R=golang-codereviews, gobot, rsc CC=golang-codereviews https://golang.org/cl/53950043 --- diff --git a/src/cmd/ld/lib.c b/src/cmd/ld/lib.c index 18c27876ee..98fa7aa482 100644 --- a/src/cmd/ld/lib.c +++ b/src/cmd/ld/lib.c @@ -269,8 +269,8 @@ loadlib(void) * look for the next file in an archive. * adapted from libmach. */ -int -nextar(Biobuf *bp, int off, struct ar_hdr *a) +static vlong +nextar(Biobuf *bp, vlong off, struct ar_hdr *a) { int r; int32 arsize; @@ -300,7 +300,7 @@ nextar(Biobuf *bp, int off, struct ar_hdr *a) void objfile(char *file, char *pkg) { - int32 off, l; + vlong off, l; Biobuf *f; char magbuf[SARMAG]; char pname[150]; diff --git a/src/cmd/ld/lib.h b/src/cmd/ld/lib.h index 761678ec02..99023f0ae2 100644 --- a/src/cmd/ld/lib.h +++ b/src/cmd/ld/lib.h @@ -241,7 +241,6 @@ void* mal(uint32 n); void mark(LSym *s); void mywhatsys(void); struct ar_hdr; -int nextar(Biobuf *bp, int off, struct ar_hdr *a); void objfile(char *file, char *pkg); void patch(void); int pathchar(void);