]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/5l: fix build (define stub machoreloc1)
authorRuss Cox <rsc@golang.org>
Mon, 11 Mar 2013 05:27:03 +0000 (01:27 -0400)
committerRuss Cox <rsc@golang.org>
Mon, 11 Mar 2013 05:27:03 +0000 (01:27 -0400)
R=ken2
CC=golang-dev
https://golang.org/cl/7694043

src/cmd/5l/asm.c

index 9ff25f1e127a8f229ba39175b33b5827dc9d21d5..f81ec2ff991c4f311d0521cdcf87591523556272 100644 (file)
@@ -295,6 +295,16 @@ elfsetupplt(void)
        }
 }
 
+int
+machoreloc1(Reloc *r, vlong sectoff)
+{
+       USED(r);
+       USED(sectoff);
+
+       return -1;
+}
+
+
 int
 archreloc(Reloc *r, Sym *s, vlong *val)
 {
@@ -325,15 +335,16 @@ archreloc(Reloc *r, Sym *s, vlong *val)
                *val = braddoff((0xff000000U & (uint32)r->add), 
                                (0xffffff & (uint32)
                                   ((symaddr(r->sym) + ((uint32)r->add) * 4 - (s->value + r->off)) / 4)));
-       return 0;
-}
-return -1;
+               return 0;
+       }
+       return -1;
 }
 
 static Reloc *
 addpltreloc(Sym *plt, Sym *got, Sym *sym, int typ)
 {
-Reloc *r;
+       Reloc *r;
+
        r = addrel(plt);
        r->sym = got;
        r->off = plt->size;