Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F137711247
D50466.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D50466.diff
View Options
diff --git a/share/mk/bsd.README b/share/mk/bsd.README
--- a/share/mk/bsd.README
+++ b/share/mk/bsd.README
@@ -197,6 +197,9 @@
LIBADD.${.TARGET:T}
Libraries dependent on output file name.
+SHARED_CFLAGS Additional compiler flags used when creating shared or
+ position independent object files.
+
COMPILER_FEATURES
A list of features that the compiler supports. Zero or
more of:
diff --git a/share/mk/bsd.suffixes-extra.mk b/share/mk/bsd.suffixes-extra.mk
--- a/share/mk/bsd.suffixes-extra.mk
+++ b/share/mk/bsd.suffixes-extra.mk
@@ -60,12 +60,13 @@
.asm.pico:
${CC:N${CCACHE_BIN}} -x assembler-with-cpp ${PICFLAG} -DPIC \
- ${CFLAGS} ${ACFLAGS} \
+ ${SHARED_CFLAGS} ${CFLAGS} ${ACFLAGS} \
-c ${.IMPSRC} -o ${.TARGET}
${CTFCONVERT_CMD}
.asm.nossppico:
${CC:N${CCACHE_BIN}} -x assembler-with-cpp ${PICFLAG} -DPIC \
+ ${SHARED_CFLAGS:C/^-fstack-protector.*$//:C/^-fstack-clash-protection.*$//} \
${CFLAGS:C/^-fstack-protector.*$//:C/^-fstack-clash-protection.*$//} \
${ACFLAGS} \
-c ${.IMPSRC} -o ${.TARGET}
@@ -73,18 +74,19 @@
.asm.pieo:
${CC:N${CCACHE_BIN}} -x assembler-with-cpp ${PIEFLAG} -DPIC \
- ${CFLAGS} ${ACFLAGS} \
+ ${SHARED_CFLAGS} ${CFLAGS} ${ACFLAGS} \
-c ${.IMPSRC} -o ${.TARGET}
${CTFCONVERT_CMD}
.S.pico:
${CC:N${CCACHE_BIN}} ${PICFLAG} -DPIC \
- ${CFLAGS} ${ACFLAGS} \
+ ${SHARED_CFLAGS} ${CFLAGS} ${ACFLAGS} \
-c ${.IMPSRC} -o ${.TARGET}
${CTFCONVERT_CMD}
.S.nossppico:
${CC:N${CCACHE_BIN}} ${PICFLAG} -DPIC \
+ ${SHARED_CFLAGS:C/^-fstack-protector.*$//:C/^-fstack-clash-protection.*$//} \
${CFLAGS:C/^-fstack-protector.*$//:C/^-fstack-clash-protection.*$//} \
${ACFLAGS} \
-c ${.IMPSRC} -o ${.TARGET}
@@ -92,7 +94,7 @@
.S.pieo:
${CC:N${CCACHE_BIN}} ${PIEFLAG} -DPIC \
- ${CFLAGS} ${ACFLAGS} \
+ ${SHARED_CFLAGS} ${CFLAGS} ${ACFLAGS} \
-c ${.IMPSRC} -o ${.TARGET}
${CTFCONVERT_CMD}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Nov 26, 2:53 AM (11 h, 29 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26195934
Default Alt Text
D50466.diff (1 KB)
Attached To
Mode
D50466: share/mk: pass SHARED_CFLAGS to PIC and PIE from assembly
Attached
Detach File
Event Timeline
Log In to Comment