|
@@ -12,6 +12,10 @@ LDSCRIPT = arch/x86/scripts/pcbios.lds
|
12
|
12
|
#
|
13
|
13
|
LDFLAGS += -N --no-check-sections
|
14
|
14
|
|
|
15
|
+# Prefix always starts at address zero
|
|
16
|
+#
|
|
17
|
+LDFLAGS += --section-start=.prefix=0
|
|
18
|
+
|
15
|
19
|
# Media types.
|
16
|
20
|
#
|
17
|
21
|
MEDIA += rom
|
|
@@ -103,13 +107,13 @@ NON_AUTO_MEDIA += fd0
|
103
|
107
|
|
104
|
108
|
# Special target for building Master Boot Record binary
|
105
|
109
|
$(BIN)/mbr.bin : $(BIN)/mbr.o
|
106
|
|
- $(QM)$(ECHO) " [OBJCOPY] $@"
|
107
|
|
- $(Q)$(OBJCOPY) -O binary $< $@
|
|
110
|
+ $(QM)$(ECHO) " [LD] $@"
|
|
111
|
+ $(Q)$(LD) $(LDFLAGS) -o $@ --oformat binary -e 0 $<
|
108
|
112
|
|
109
|
113
|
# rule to make a USB disk image
|
110
|
114
|
$(BIN)/usbdisk.bin : $(BIN)/usbdisk.o
|
111
|
|
- $(QM)$(ECHO) " [OBJCOPY] $@"
|
112
|
|
- $(Q)$(OBJCOPY) -O binary $< $@
|
|
115
|
+ $(QM)$(ECHO) " [LD] $@"
|
|
116
|
+ $(Q)$(LD) $(LDFLAGS) -o $@ --oformat binary -e 0 $<
|
113
|
117
|
|
114
|
118
|
NON_AUTO_MEDIA += usb
|
115
|
119
|
%usb: $(BIN)/usbdisk.bin %hd
|