Skip to content

Commit

Permalink
Fixed broken build on newer gold linker with NaCl support
Browse files Browse the repository at this point in the history
On platforms with NaCl support, ld.gold -V will return a "elf_i386_nacl" in
addition to "elf_i386", which will make the build fail.
  • Loading branch information
Icenowy authored and kaashoek committed Sep 26, 2016
1 parent 907f23a commit 91fd347
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ CFLAGS = -fno-pic -static -fno-builtin -fno-strict-aliasing -O2 -Wall -MD -ggdb
CFLAGS += $(shell $(CC) -fno-stack-protector -E -x c /dev/null >/dev/null 2>&1 && echo -fno-stack-protector)
ASFLAGS = -m32 -gdwarf-2 -Wa,-divide
# FreeBSD ld wants ``elf_i386_fbsd''
LDFLAGS += -m $(shell $(LD) -V | grep elf_i386 2>/dev/null)
LDFLAGS += -m $(shell $(LD) -V | grep elf_i386 2>/dev/null | head -n 1)

xv6.img: bootblock kernel fs.img
dd if=/dev/zero of=xv6.img count=10000
Expand Down

0 comments on commit 91fd347

Please sign in to comment.