1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-01 12:19:28 +00:00

Use -Wl,-N instead of the undocumented -N option for GCC.

GCC forwards the -N flag directly to ld. This flag is not documented and
not supported by (for example) Clang. Just use -Wl,-N.

Submitted by:	Pawel Worach
This commit is contained in:
Ed Schouten 2010-06-03 17:42:32 +00:00
parent 3da35a0a52
commit d05becf2b6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=208789
12 changed files with 12 additions and 12 deletions

View File

@ -74,6 +74,6 @@ CFLAGS+=-DFLAGS=${BOOT_BOOT0_FLAGS} \
-DTICKS=${BOOT_BOOT0_TICKS} \
-DCOMSPEED=${BOOT_BOOT0_COMCONSOLE_SPEED}
LDFLAGS=-N -e start -Ttext ${BOOT_BOOT0_ORG} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${BOOT_BOOT0_ORG} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -24,6 +24,6 @@ CFLAGS+=-DBTX_SERIAL -DSIOPRT=${BOOT_COMCONSOLE_PORT} \
ORG= 0x9000
LDFLAGS=-N -e start -Ttext ${ORG} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${ORG} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -11,6 +11,6 @@ CFLAGS+=-DLOADER_ADDRESS=${LOADER_ADDRESS}
CFLAGS+=-DBTXLDR_VERBOSE
.endif
LDFLAGS=-N -e start -Ttext ${LOADER_ADDRESS} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${LOADER_ADDRESS} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -8,6 +8,6 @@ SRCS= ${PROG}.s
ORG= 0x7c00
LDFLAGS=-N -e start -Ttext ${ORG} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${ORG} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -12,6 +12,6 @@ BOOT_MBR_FLAGS?= 0x80
ORG= 0x600
AFLAGS+=--defsym FLAGS=${BOOT_MBR_FLAGS}
LDFLAGS=-N -e start -Ttext ${ORG} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${ORG} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -9,6 +9,6 @@ SRCS= ${PROG}.s
ORG= 0x600
AFLAGS+=--defsym FLAGS=${BOOT_MBR_FLAGS}
LDFLAGS=-N -e start -Ttext ${ORG} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${ORG} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -14,7 +14,7 @@ BOOT= boot0.5
# unless you are glutton for punishment.
BOOT_BOOT0_ORG?= 0x0000
LDFLAGS=-N -e start -Ttext ${BOOT_BOOT0_ORG} -Wl,-T,${.CURDIR}/ldscript
LDFLAGS=-e start -Ttext ${BOOT_BOOT0_ORG} -Wl,-N,-T,${.CURDIR}/ldscript
# The size of boot0.5 must be 7168 bytes
${BOOT}: ${BOOT}.bin

View File

@ -13,7 +13,7 @@ BOOT= boot0
# unless you are glutton for punishment.
BOOT_BOOT0_ORG?= 0x0000
LDFLAGS=-N -e start -Ttext ${BOOT_BOOT0_ORG}
LDFLAGS=-e start -Ttext ${BOOT_BOOT0_ORG} -Wl,-N
${BOOT}: ${BOOT}.out
objcopy -S -O binary ${BOOT}.out ${.TARGET}

View File

@ -24,6 +24,6 @@ CFLAGS+=-DBTX_SERIAL -DSIOPRT=${BOOT_COMCONSOLE_PORT} \
ORG= 0x9000
LDFLAGS=-N -e start -Ttext ${ORG} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${ORG} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -11,6 +11,6 @@ CFLAGS+=-DLOADER_ADDRESS=${LOADER_ADDRESS}
CFLAGS+=-DBTXLDR_VERBOSE
.endif
LDFLAGS=-N -e start -Ttext ${LOADER_ADDRESS} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${LOADER_ADDRESS} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -8,6 +8,6 @@ SRCS= ${PROG}.s
ORG= 0x0000
LDFLAGS=-N -e start -Ttext ${ORG} -Wl,-S,--oformat,binary
LDFLAGS=-e start -Ttext ${ORG} -Wl,-N,-S,--oformat,binary
.include <bsd.prog.mk>

View File

@ -9,7 +9,7 @@ SRCS= _start.s boot1.c
BOOTBLOCKBASE= 0x4000
CFLAGS= -mcmodel=medlow -Os -I${.CURDIR}/../../common
LDFLAGS=-N -Ttext ${BOOTBLOCKBASE}
LDFLAGS=-Ttext ${BOOTBLOCKBASE} -Wl,-N
# Construct boot1. sunlabel expects it to contain zeroed-out space for the
# label, and to be of the correct size.